Hw to set LineForm as NonEditable thrgh HeaderFrm fld value?

pskannaapskannaa Member Posts: 138
Hi,
I am having header field 'Sampling Type'(dropdown) based on this value need to set LineForm as non-editable/editable.

Eg:

Header Form:
Sampling Type (dropdown) values are 'Variable,Fixed,Percent'..

If Sampling Type is Not 'VARIABLE' the LineForm should be NONEDITABLE otherwise EDITABLE.

Note: The Trigger I need to fire when you are inserting/creating the record as well as naviage records(next,prv).
suggestion !!!!
Thanks ..

Regards,
Psk

Comments

  • prabhupdeshprabhupdesh Member Posts: 49
    Go to the "OnFormat" Trigger of the sampling type field by pressing F9 on the field in designer mode.

    Now add the following code in the trigger:

    "linecontrol" in the code just represents the value you have entered in the Name property of the subform, so please put exact value for line control.


    sampling type- OnFormat(VAR Text : Text[1024];)

    IF "sampling type" = sampling type :: variable THEN
    currform.linecontrol.EDITABLE(TRUE)
    ELSE
    currform.linecontrol.EDITABLE(FALSE);

    hope it works......as it worked for me.....gud luck!!!!!
  • pskannaapskannaa Member Posts: 138
    Excellent buddy !!!

    Working Cooool.

    Can you plz tell me what is the use for 'ONFORMAT()' Trigger and when it is calling ???
  • prabhupdeshprabhupdesh Member Posts: 49
    Regarding this trigger,
    This is the first trigger the system executes when a user highlights the control to enter data.

    well you can get more information if you see c/side reference guide,,,, :D
  • pskannaapskannaa Member Posts: 138
    Thanks buddy.
Sign In or Register to comment.