Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations IDS on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

'This callback allows the dialog to enable/disable the OK and Apply button.

Status
Not open for further replies.

Ehaviv

Computer
Jul 2, 2003
1,012
Hi

The doc say:
'This callback is executed when any block (except the ones which receive keyboard entry such as Integer block) receives focus.
'This callback is executed when block which can receive keyboard entry, receives the focus.

But for enableOKButton_cb it only say:
'This callback allows the dialog to enable/disable the OK and Apply button.
But not 'This callback is executed when

Do someone know when This callback is executed ?

Code:
    '------------------------------------------------------------------------------
    'Callback Name: focusNotify_cb
    'This callback is executed when any block (except the ones which receive keyboard entry such as Integer block) receives focus.
    '------------------------------------------------------------------------------
    Public Sub focusNotify_cb(ByVal block As BlockStyler.UIBlock, ByVal focus As Boolean)
        Try
        
            '---- Enter your callback code here -----

            'msgbox(block.ToString & "  -  " & focus.ToString)

        Catch ex As Exception
        
            '---- Enter your exception handling code here -----
            theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString)
        End Try
    End Sub
    
    '------------------------------------------------------------------------------
    'Callback Name: keyboardFocusNotify_cb
    'This callback is executed when block which can receive keyboard entry, receives the focus.
    '------------------------------------------------------------------------------
    Public Sub keyboardFocusNotify_cb(ByVal block As BlockStyler.UIBlock, ByVal focus As Boolean)
        Try
        
            '---- Enter your callback code here -----

            'msgbox(block.Name)
            'string1.Focus   
        
        Catch ex As Exception
        
            '---- Enter your exception handling code here -----
            theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString)
        End Try
    End Sub
    
    '------------------------------------------------------------------------------
    'Callback Name: enableOKButton_cb
    'This callback allows the dialog to enable/disable the OK and Apply button.
    '------------------------------------------------------------------------------
    Public Function enableOKButton_cb() As Boolean
        enableOKButton_cb = IsEnableOkButton
        Try
        
            '---- Enter your callback code here -----

            'Return IsEnableOkButton
        
        Catch ex As Exception
        
            '---- Enter your exception handling code here -----
            theUI.NXMessageBox.Show("Block Styler", NXMessageBox.DialogType.Error, ex.ToString)
        End Try
    End Function
 
Replies continue below

Recommended for you

enableOKButton_cb gets called after every interaction with the dialog. You have the option to check if all the required inputs have been satisfied or not. You can return true to enable the OK button or false to disable it.


Suresh
 
Hi ufsure and thank you.

That's strong my guess.

Thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor