I've created the page Customer List (No, Descr, Address).
I want to hide/show the "Address" column dynamically.
I've created global variable bVisible (type=bool, IncludeInDataset=Yes)
and set the value of property "Visible" to bVisible (this is property of element Address).
When page is opening - everything is correct (If I put "bVisible:=true;" in the trigger OnOpenPage() then column is visible, if I put nothing there, "Address" is invisible).
But if I change value of bVisible (with actions or just click checkbox) notihng happens.
When I tried to use CurrPage.Address.Visible(bVisible), I got error: The VISIBLE() method is obsolete.
Have I missed something or it is impossible?
Hope someone can prove me wrong.
I'm blogging here:http://mibuso.com/blogs/clausl and used to blog here: http://blogs.msdn.com/nav
I'm also offering RDLC Report Training, ping me if you are interested. Thanks to the 700 NAV developers that have now already been at my training. You know you can always call if you have any RDLC report issues :-)
Page 9231 Items by Location Matrix
Why function SetVisible() is triggered for every record (onAfterGetRecord) if the visiblity property for controls is supported only for OnInit and for OnOpenPage triggers?
IMHO SetVisible should be in the OnOpenPage trigger.
This way we can avoid superfluous calls. And this one call will be effective.
The same is true for the form 9231. It works correct, but I'm not sure that function SetVisible should be called for every record. The number of columns is same for all records, so it is possible to set the visiblity property once - at the onOpenForm trigger.