Hi,
It may be a silly question but im new to Nav world
My client wants a data validation on fixed asset card. Basically he wants based on the asset type that only some FA Classes to Show up and based on the FA classe picked up by the user that only some sub classes to show up. I think that we gonna need to have a custom table for this purpose but my questions are:
1 - Do we have to put this logic in page 5600 or in table 5600? What are the main diferences?
2 - How can i achieve this purpose? in wicth event should i put the logic and how can i add/remove values from a optin field?
Thanks in advance
Best Regards
João Martins
Answers
I think you may find it most efficient to use a tablerelation - something like :
Look at the properties for field "FA Class Code" in table 5600
Tablerelation : IF (Main Asset/Component=CONST(Main Asset)) "FA Class".Code WHERE (Code=CONST(FINANCIAL))
Troels Bent Hansen
Senior Program Manager
Microsoft Dynamics NAV
****** This posting is provided "AS IS" with no warranties, and confers no rights ******
Add a new field to the subclass table that holds the FA class (from table 5607), use a table relation to limit values to those that are in table 5607. This approach has the advantage of allowing the users to add new subclasses and have them link to the correct class without any requirement for additional coding later on down the road.
Then change the current table relation for the subclass field in table 5600 so it looks something like this:
"FA Subclass".Code WHERE (FA Class=FIELD(FA Class Code))
Note - this is probably not the precise syntax, but it should be close enough to get you there. You will also need to modify the appropriate forms/pages to support the new field in table 5608.
Solved!!! Thank you guys.
Dleroux i've choosed your solution and it works in perfection!
Troelsh also thanks for your reply.
EDIT - Just one more thing, the classes and sub classes are showed just how i want but if i choose classe 1 and sub class 1, lets say that this one are right, and before save the FA change the Class to other value, without changing the subclass, where the subclass 1 does not belongs to, the system it´s giving me an error... Is'nt supossed to show an error message?
Regrads
João Martins