Flowfield show 0 on form
depro
Member Posts: 46
Hi,
I`ve created table with some flowfields which has CalcFormula like:
Count("MyTable" WHERE (Field1=FILTER(No),Field2=FILTER(No),Field3=FILTER(Yes))).
I`ve set up LookUpFormId and DrillDownFormID with properly values.
When i`ve checked flowfields value in table its ok.
Then i`ve created Card type form to show this value with property AutoCalcField = YES.
What i see on form is values 0, but when i click to drill down flowfield i can see properly number of records.
I`ve creeated form using standard form wizard in NAV 5.0 sp1 client.
regards,
depro
I`ve created table with some flowfields which has CalcFormula like:
Count("MyTable" WHERE (Field1=FILTER(No),Field2=FILTER(No),Field3=FILTER(Yes))).
I`ve set up LookUpFormId and DrillDownFormID with properly values.
When i`ve checked flowfields value in table its ok.
Then i`ve created Card type form to show this value with property AutoCalcField = YES.
What i see on form is values 0, but when i click to drill down flowfield i can see properly number of records.
I`ve creeated form using standard form wizard in NAV 5.0 sp1 client.
regards,
depro
0
Answers
-
depro wrote:Hi,
I`ve created table with some flowfields which has CalcFormula like:
Count("MyTable" WHERE (Field1=FILTER(No),Field2=FILTER(No),Field3=FILTER(Yes))).
I`ve set up LookUpFormId and DrillDownFormID with properly values.
When i`ve checked flowfields value in table its ok.
Then i`ve created Card type form to show this value with property AutoCalcField = YES.
What i see on form is values 0, but when i click to drill down flowfield i can see properly number of records.
I`ve creeated form using standard form wizard in NAV 5.0 sp1 client.
regards,
depro
Hi depro,
The filters you have given in the calcformula might not gives any countable data in the table you have specified. So, it would have shown 0. Change the method to "sum" instead of using "count". Sorry if i misunderstood. =;With warm regards,
Thankesh
***Learn to lead***0 -
hi depro,
see if what i understood is right, you want the count of the field's value in your table.smile always
shona
That which you seek inside is that which you find outside0 -
@ Shonatina
Yes I wont to count record i table.
@ thankesh
My filters work good becouse I can drill down 0 value from my form and I see accurate numbers of records.
And when i run my table flowfield shows correct values.
It looks like something is wrong with my form.
First i`ve createt form from Wizard, but when i`ve checke properties and it`s looks ok. Then i`ve made this form in object designer but it still doesn`t work.
It is first time when i have problems with flowfield values on form.
So I really don`t know why it work (doesn`t work) in taht way.
regards,
depro0 -
Is there any record in your new table where you created your FlowFields? FlowFields are calculated after a record is get. If there isn't any record calculation will never be performed."Money is likewise the greatest chance and the greatest scourge of mankind."0
-
@ einsTeIn.NET
Yes, There is 1 record in my table which contain flowfiels.
It is my setup table and it was designed like Table 311 Sales & Receivables Setup.
The most confusing thig is that this flowfields has correct values int table.
I still working on this issue, i add some custom code on form in OnAfterGetRecord and OnOpenForm likeCALCFIELDS(Flowfield1, Flowfield2,....); CurrForm.Update(TRUE);
But my form still don`t show my flowfielda values.
regards,
depro0 -
What is the source expression of the textbox that shows this flowfield?0
-
@ kapamarou
I`ve checked SourceExpression few times.
For exmple:
On form:
SourceExpression: "No. of New Resource"
Table:
Enabled Field No. Field Name Caption Data Type
Yes 70 No. of New Resource <No. of New Resource> Integer
Properies field 'No. of New Resource"
FieldClass: FlowField
CalcFormula: Count("Resource Import" WHERE (Used=FILTER(No),Rejected=FILTER(No),New=FILTER(Yes)))
So kapamarou thanks for your advice but i guess the point is somewhere else.
I`ve made this form few times with different propoerties but it still doesn`t work ](*,)0 -
So, you said when you're looking into the table via Object Designer then the FlowFields are showing the correct values, is that correct?
Could you please post some parameters of your system, e.g. SQL or native, Client Verson (Build No.), ... anything else that could be worth mentioning."Money is likewise the greatest chance and the greatest scourge of mankind."0 -
Maybe you can attach related objects to let us see what happens there.Ufuk Asci
Pargesoft0 -
I am using SQL database, version 5.0 sp1.
Here is definition of my obejcts:OBJECT Table 50016 Import Setup { OBJECT-PROPERTIES { Date=10-08-06; Time=14:57:29; Modified=Yes; Version List=CRM.INT; } PROPERTIES { } FIELDS { { 10 ; ;Key ;Integer } { 60 ; ;No. of Modif. Resource;Integer ;FieldClass=FlowField; CalcFormula=Count("Resource Import" WHERE (Used=FILTER(No), Rejected=FILTER(No), New=FILTER(No))); Editable=No } { 70 ; ;No. of New Resource ;Integer ;FieldClass=FlowField; CalcFormula=Count("Resource Import" WHERE (Used=FILTER(No), Rejected=FILTER(No), New=FILTER(Yes))); Editable=No } } KEYS { { ;Key ;Clustered=Yes } } CODE { BEGIN END. } } OBJECT Table 50017 Resource Import { OBJECT-PROPERTIES { Date=10-08-06; Time=10:10:44; Modified=Yes; Version List=CRM.INT; } PROPERTIES { LookupFormID=Form50044; DrillDownFormID=Form50044; } FIELDS { { 1 ; ;Key ;Integer ;AutoIncrement=Yes } { 10 ; ;No. ;Code20 ;CaptionML=[ENU=No.; PLK=Nr] } { 20 ; ;Name ;Text50 ;CaptionML=[ENU=Name; PLK=Nazwa] } { 30 ; ;Gen. Prod. Posting Group;Code10 ;TableRelation="Gen. Product Posting Group"; CaptionML=[ENU=Gen. Prod. Posting Group; PLK=G. tow. grupa ksi©gowa] } { 40 ; ;VAT Prod. Posting Group;Code10 ;TableRelation="VAT Product Posting Group"; CaptionML=[ENU=VAT Prod. Posting Group; PLK=Tow. grupa ksi©gowa VAT] } { 100 ; ;English Name ;Text150 } { 110 ; ;French Name ;Text150 } { 120 ; ;IsCost ;Boolean } { 130 ; ;Full Name ;Text150 } { 140 ; ;PKWiU ;Text15 } { 500 ; ;Used ;Boolean } { 510 ; ;Use Time ;DateTime } { 520 ; ;New ;Boolean } { 550 ; ;Rejected ;Boolean } { 560 ; ;Rejected Reason ;Text150 } } KEYS { { ;Key ;Clustered=Yes } { ;No. } } CODE { BEGIN END. } } OBJECT Form 50035 Import Setup { OBJECT-PROPERTIES { Date=10-08-06; Time=13:45:29; Modified=Yes; Version List=CRM.INT; } PROPERTIES { Width=9790; Height=6490; SourceTable=Table50016; SourceTableView=SORTING(Key); OnOpenForm=BEGIN CALCFIELDS("No. of Invoice to Import", "No. of Note de Frais to Import", "No. of Modif. Cust.", "No. of New Cust.", "No. of Modif. Resource", "No. of New Resource"); CurrForm.UPDATE(TRUE); END; OnAfterGetRecord=BEGIN CALCFIELDS("No. of Invoice to Import", "No. of Note de Frais to Import", "No. of Modif. Cust.", "No. of New Cust.", "No. of Modif. Resource", "No. of New Resource"); CurrForm.UPDATE(TRUE); END; } CONTROLS { { 1000000000;TabControl;220;220 ;9350 ;5280 ;HorzGlue=Both; VertGlue=Both; PageNamesML=PLK=Og˘lne,Harmonogram } { 1000000001;TextBox;3850 ;990 ;1700 ;440 ;ParentControl=1000000000; InPage=0; SourceExpr="No. of Invoice to Import" } { 1000000002;Label ;440 ;990 ;3300 ;440 ;ParentControl=1000000001 } { 1000000003;TextBox;3850 ;1540 ;1700 ;440 ;ParentControl=1000000000; InPage=0; SourceExpr="No. of Note de Frais to Import" } { 1000000004;Label ;440 ;1540 ;3300 ;440 ;ParentControl=1000000003 } { 1000000005;TextBox;3850 ;2090 ;1700 ;440 ;ParentControl=1000000000; InPage=0; SourceExpr="No. of Modif. Cust." } { 1000000006;Label ;440 ;2090 ;3300 ;440 ;ParentControl=1000000005 } { 1000000007;TextBox;3850 ;2640 ;1700 ;440 ;ParentControl=1000000000; InPage=0; SourceExpr="No. of New Cust." } { 1000000008;Label ;440 ;2640 ;3300 ;440 ;ParentControl=1000000007 } { 1000000009;TextBox;3850 ;3190 ;1700 ;440 ;ParentControl=1000000000; InPage=0; SourceExpr="No. of Modif. Resource" } { 1000000010;Label ;440 ;3190 ;3300 ;440 ;ParentControl=1000000009 } { 1000000011;TextBox;3850 ;3740 ;1700 ;440 ;ParentControl=1000000000; InPage=0; SourceExpr="No. of New Resource" } { 1000000012;Label ;440 ;3740 ;3300 ;440 ;ParentControl=1000000011 } { 1000000013;TextBox;3850 ;4290 ;2750 ;440 ;ParentControl=1000000000; InPage=0; SourceExpr="NdF Jnl Temlate Name" } { 1000000014;Label ;440 ;4290 ;3300 ;440 ;ParentControl=1000000013 } { 1000000015;TextBox;3850 ;4840 ;2750 ;440 ;ParentControl=1000000000; InPage=0; SourceExpr="NdF Jnl Batch Name" } { 1000000016;Label ;440 ;4840 ;3300 ;440 ;ParentControl=1000000015 } { 1000000017;TextBox;3850 ;990 ;1700 ;440 ;ParentControl=1000000000; InPage=1; SourceExpr="Standart Procedure Start" } { 1000000018;Label ;440 ;990 ;3300 ;440 ;ParentControl=1000000017 } { 1000000019;TextBox;3850 ;1540 ;1700 ;440 ;ParentControl=1000000000; InPage=1; SourceExpr="Standart Procedure Stop" } { 1000000020;Label ;440 ;1540 ;3300 ;440 ;ParentControl=1000000019 } { 1000000021;TextBox;3850 ;2090 ;1700 ;440 ;ParentControl=1000000000; InPage=1; SourceExpr="Special Procedure Start" } { 1000000022;Label ;440 ;2090 ;3300 ;440 ;ParentControl=1000000021 } { 1000000023;TextBox;3850 ;2640 ;1700 ;440 ;ParentControl=1000000000; InPage=1; SourceExpr="Special Procedure Stop" } { 1000000024;Label ;440 ;2640 ;3300 ;440 ;ParentControl=1000000023 } { 1000000025;CommandButton;7370;5720;2200;550; HorzGlue=Right; VertGlue=Bottom; PushAction=FormHelp } } CODE { BEGIN END. } } OBJECT Form 50044 Zasoby Importowane { OBJECT-PROPERTIES { Date=10-08-06; Time=10:09:59; Modified=Yes; Version List=CRM.INT; } PROPERTIES { Width=16500; Height=6710; TableBoxID=1000000000; SourceTable=Table50017; } CONTROLS { { 1000000000;TableBox;220 ;220 ;16060;5500 ;HorzGlue=Both; VertGlue=Both } { 1000000001;TextBox;0 ;0 ;1700 ;0 ;ParentControl=1000000000; InColumn=Yes; SourceExpr="No." } { 1000000002;Label ;0 ;0 ;0 ;0 ;ParentControl=1000000001; InColumnHeading=Yes } { 1000000003;TextBox;0 ;0 ;4400 ;0 ;HorzGlue=Both; ParentControl=1000000000; InColumn=Yes; SourceExpr=Name } { 1000000004;Label ;0 ;0 ;0 ;0 ;ParentControl=1000000003; InColumnHeading=Yes } { 1000000005;TextBox;0 ;0 ;1700 ;0 ;ParentControl=1000000000; InColumn=Yes; SourceExpr="Gen. Prod. Posting Group" } { 1000000006;Label ;0 ;0 ;0 ;0 ;ParentControl=1000000005; InColumnHeading=Yes } { 1000000007;TextBox;0 ;0 ;1700 ;0 ;ParentControl=1000000000; InColumn=Yes; SourceExpr="VAT Prod. Posting Group" } { 1000000008;Label ;0 ;0 ;0 ;0 ;ParentControl=1000000007; InColumnHeading=Yes } { 1000000009;TextBox;0 ;0 ;4400 ;0 ;ParentControl=1000000000; InColumn=Yes; SourceExpr="English Name" } { 1000000010;Label ;0 ;0 ;0 ;0 ;ParentControl=1000000009; InColumnHeading=Yes } { 1000000011;TextBox;0 ;0 ;4400 ;0 ;ParentControl=1000000000; InColumn=Yes; SourceExpr="French Name" } { 1000000012;Label ;0 ;0 ;0 ;0 ;ParentControl=1000000011; InColumnHeading=Yes } { 1000000013;CheckBox;0 ;0 ;1700 ;0 ;ParentControl=1000000000; InColumn=Yes; ShowCaption=No; SourceExpr=IsCost } { 1000000014;Label ;0 ;0 ;0 ;0 ;ParentControl=1000000013; InColumnHeading=Yes } { 1000000015;TextBox;0 ;0 ;4400 ;0 ;ParentControl=1000000000; InColumn=Yes; SourceExpr="Full Name" } { 1000000016;Label ;0 ;0 ;0 ;0 ;ParentControl=1000000015; InColumnHeading=Yes } { 1000000017;TextBox;0 ;0 ;2200 ;0 ;ParentControl=1000000000; InColumn=Yes; SourceExpr=PKWiU } { 1000000018;Label ;0 ;0 ;0 ;0 ;ParentControl=1000000017; InColumnHeading=Yes } { 1000000019;CommandButton;9240;5940;2200;550; HorzGlue=Right; VertGlue=Bottom; Default=Yes; PushAction=LookupOK; InvalidActionAppearance=Hide } { 1000000020;CommandButton;11660;5940;2200;550; HorzGlue=Right; VertGlue=Bottom; Cancel=Yes; PushAction=LookupCancel; InvalidActionAppearance=Hide } { 1000000021;CommandButton;14080;5940;2200;550; HorzGlue=Right; VertGlue=Bottom; PushAction=FormHelp } } CODE { BEGIN END. } }
Copy this code to txt file and import it.
Regards,0 -
Well, I've tried and it works fine for me...
Sorry for asking again, but did you insert a new record in table Import Setup? Just to make sure that when you open a form it is not on an [untitled - Import Setup] "New" record.
If there is no record the flowfields seem to work through the table but not through the form...0 -
Works for me too (except some fields removed from table, I had to delete them from form). Do you really have records having values you cited in calcformula?Ufuk Asci
Pargesoft0 -
Thank You Guys for helping me!
The problem was my record in table.
I didn`t put anythig in Primary Key field, just in other field in table.
So now my form work`s fine.
But i can`t understand why my FlowField calculation is not performed?
I thought that if only i`ve put some data in table record (exluding Primary Key) I`ve go record.
Is it necessary to put some value in primary key to make record?
Regards,0
Categories
- All Categories
- 75 General
- 75 Announcements
- 66.7K Microsoft Dynamics NAV
- 18.8K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 610 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 253 Dynamics CRM
- 103 Dynamics GP
- 6 Dynamics SL
- 1.5K Other
- 991 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 28 Design Patterns (General & Best Practices)
- Architectural Patterns
- 9 Design Patterns
- 4 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1K General Chat
- 1.6K Website
- 77 Testing
- 1.2K Download section
- 23 How Tos section
- 249 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions
