Hi,
We are using Nav 2009 SP 1 and we have two companies in our database. Company A & Company B, I have created a new field under Sales Header Table and Sales Order Form, I have inserted that new field but this new field also shown in the sales order form when I open Company A, I dont want this new field to be shown in Company A, how do I write a peice of code to hide it from Company A, Pls give me some steps as under code of sales header table or sales order form, which is the place or section that I need write a small line code to hide it from Company A.
Regards
KH
0
Comments
-Mohana
http://mohana-dynamicsnav.blogspot.in/
https://www.facebook.com/MohanaDynamicsNav
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.
When I use your code on the sales order form under the option specified by you, I put the code and then when try to save it gives error as i have defined an unknown variable, so how do i get it correct.
Regards
KH
-Mohana
http://mohana-dynamicsnav.blogspot.in/
https://www.facebook.com/MohanaDynamicsNav
see the code how i have written
I go to Object Designer/Form/42, Design, Press F9, and look at the trigger mentioned by you
Form - OnOpenForm()
CurrForm."Change Requested Del Date".VISIBLE := COMPANYNAME = 'Interior Affairs Group Pte Ltd';
Is this above line written by me is correct or not, but when I compile the object, it gives me error an unknown variable
Regards
KH
where is the pointer shows after pressing ok on Error?
-Mohana
http://mohana-dynamicsnav.blogspot.in/
https://www.facebook.com/MohanaDynamicsNav
sorry! The field name was not right, so after reading your reply, I did checked the field and realized that it has a dot (symbol) in between so I did exactly the same and then complied the form, no error! see the code that i have written
CurrForm."Change Requsted Del. Date".VISIBLE := COMPANYNAME = 'Interior Affairs Group Pte Ltd';
Perfect! Many thanks for your kind help.
Regards
KH
Hard coding is bad solution #-o
-Mohana
http://mohana-dynamicsnav.blogspot.in/
https://www.facebook.com/MohanaDynamicsNav
I am a functional consultant who has no clue of coding. Before I ask for help and get help on this forum, I put it to my local system and check it throughly and only after that I shall apply the same to the live server. So considering other options is not within my scope, I can give the requirement to the vendor but he will simply charge me half a man day to do this, so its better for me to get some advise and do it for my customer. With coding or without coding, I am ok as long as it works for me. Thanks for your advise and at same time also on the code help
Regards
KH