NetTalk Central

Author Topic: EIP Validation  (Read 3458 times)

broche

  • Sr. Member
  • ****
  • Posts: 336
    • View Profile
    • Email
EIP Validation
« on: October 21, 2014, 10:32:15 AM »
Cl 9.0
NT 8.28

Trying to do some EIP validation on a check Box field and not succeeding.
When the user clicks the Check Box I want the code to check the the word FINAL is in a document name
The Browse is on a tab on the update record for the parent.

        Loc:Final        = p_web.GSV('FinalText')       
        Loc:FileName = p_web.GSV('cvfd:UploadName')
        Loc:Exists     = INSTRING(Loc:Final,Loc:FileName,1,1)
 
        IF Loc:Exists > 0
            IF p_web.GSV('cvfd:dcovf') = 'VOICE'
                loc:invalid = 'cvfd:MasterDoc'
                loc:alert   = 'Master cannot be a voice file'
                p_web.SSV('cvfd:MasterDoc','N')
            ELSE 
                loc:cvfsysid  = p_web.GSV('CVF:cvfsysid')
                Loc:MasterSet = p_web.GSV('cvfd:MasterDoc')
                IF Loc:MasterSet = 'Y'
                    p_web.SSV('CVF:MasterDocument',Loc:FileName)
                    p_web.SSV('CVF:MasterSet','Y')
                    p_web.SSV('CVF:MasterDocID',p_web.GSV('cvfd:cvfdtlid'))
                ELSE
                    p_web.SSV('CVF:MasterDocument','')
                    p_web.SSV('CVF:MasterDocID',0)
                    p_web.SSV('CVF:MasterSet','N')
                    p_web.SSV('CVF:EditCommitt','N')
                END
            END
        ELSE
            p_web.SSV('cvfd:MasterDoc','N')
            Loc:Alert = 'Make sure this is the final document'
        END

If the word FINAL is not in the document name I want to alert the user and reset the checkbox to No
Ihave the code in
! Start of "After Validate New Value"
  ! [Priority 4000]

When I test the code it is getting the correct text etc.  Just not setting the Check box to No.


Thanks in advance.




Brian

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: EIP Validation
« Reply #1 on: October 21, 2014, 11:27:13 PM »
is the checkbox set to refresh itself?

cheers
Bruce

broche

  • Sr. Member
  • ****
  • Posts: 336
    • View Profile
    • Email
Re: EIP Validation
« Reply #2 on: October 22, 2014, 02:33:13 PM »
Refresh Whole Browse has been set on the Client Side Tab on the Edit tab.
Brian

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: EIP Validation
« Reply #3 on: October 22, 2014, 09:45:24 PM »
I think you need to post an example Brian.

Maybe the Tagging example is a good place to start?

cheers
Bruce