Home » Developer & Programmer » Forms » How to Get the Count ?
How to Get the Count ? [message #119379] Thu, 12 May 2005 05:18 Go to next message
venkatesham
Messages: 45
Registered: April 2005
Location: Hyd
Member

hi,
I have Designed the Form with two tab canvases(Dept_Det,Emp_Det) with two blocks(Dept,Emp)..and Whenever i select a deptno from Block Dept and go to Next tab page to Emp Block its Showing the corresponding Employees...Now i want to get the No. of Employees in that(Emp) Block in a Display Item(D_Emp_No) ..What Code & Trigger should i use to get the Same..

Thanks in Advance
Ramesh..
icon14.gif  Re: How to Get the Count ? [message #119395 is a reply to message #119379] Thu, 12 May 2005 07:01 Go to previous messageGo to next message
RAY_HT
Messages: 155
Registered: May 2005
Location: Giza
Senior Member
hi venkatesham

no problem and no need to code a trigger

just reside the display item into non_database block and set it as computed item with calculation mode summrizes and summrized function "count"
summrized block "emp"
it will display the count of employee for the selected dept.

[Updated on: Thu, 12 May 2005 07:02]

Report message to a moderator

Re: How to Get the Count ? [message #119406 is a reply to message #119395] Thu, 12 May 2005 08:45 Go to previous messageGo to next message
venkatesham
Messages: 45
Registered: April 2005
Location: Hyd
Member

Hi,
Thanks for ur Help....but When i am doing that,its Giving the Following error ..In This,CNT is my Contol Block & D_EMP_NO is Display Item

FRM-30047: Cannot resolve item reference EMP1..
Item: D_EMP_NO
Block: CNT
FRM-30085: Unable to adjust form for output.


Plz Help...

Thanks
Ramesh..
Re: How to Get the Count ? [message #119410 is a reply to message #119379] Thu, 12 May 2005 08:58 Go to previous messageGo to next message
RAY_HT
Messages: 155
Registered: May 2005
Location: Giza
Senior Member
hi

just set calculation mode property to "summary"
set summrized function to "count"
set summrized block to "cnt"
set summrized item to "D_EMP_NO"
let formula property empty or null

also EMP block must be "query all record set to yes"
and CNT block must be "single record set to yes"


hany
Re: How to Get the Count ? [message #119426 is a reply to message #119410] Thu, 12 May 2005 09:34 Go to previous messageGo to next message
venkatesham
Messages: 45
Registered: April 2005
Location: Hyd
Member


Its Now Displaying the Following Error......

FRM-30378: Summarized item must not be summary item and must not reside in single-record block.

Ramesh..
Re: How to Get the Count ? [message #119443 is a reply to message #119379] Thu, 12 May 2005 10:05 Go to previous messageGo to next message
RAY_HT
Messages: 155
Registered: May 2005
Location: Giza
Senior Member
hi
try this sample form attached hope to be usefull
tell me if it work
  • Attachment: TEST.fmb
    (Size: 92.00KB, Downloaded 1538 times)

[Updated on: Thu, 12 May 2005 10:07]

Report message to a moderator

Re: How to Get the Count ? [message #119451 is a reply to message #119410] Thu, 12 May 2005 10:51 Go to previous messageGo to next message
Neecharl
Messages: 15
Registered: May 2005
Location: Chennai/Mauritius
Junior Member

The item D_Emp_No must reside in the block EMP (which contains the numerous employee records)

In property of D_Emp_No:
set calculation mode to "summary"
set summarized function to "count"
set summrized block to "EMP"
set summrized item to "D_Emp_No"

also EMP block must be "query all record set to yes"
Re: How to Get the Count ? [message #119457 is a reply to message #119443] Thu, 12 May 2005 11:44 Go to previous messageGo to next message
venkatesham
Messages: 45
Registered: April 2005
Location: Hyd
Member
Thanks a lot ...

Ramesh..
Re: How to Get the Count ? [message #119644 is a reply to message #119457] Fri, 13 May 2005 10:59 Go to previous messageGo to next message
Neecharl
Messages: 15
Registered: May 2005
Location: Chennai/Mauritius
Junior Member

Did it work?
Re: How to Get the Count ? [message #119648 is a reply to message #119644] Fri, 13 May 2005 11:04 Go to previous message
venkatesham
Messages: 45
Registered: April 2005
Location: Hyd
Member
yes it Worked...Thank u
Previous Topic: REPORTS GURU: (Running reports on web through MENU )
Next Topic: insert or update
Goto Forum:
  


Current Time: Thu Sep 19 16:25:06 CDT 2024