VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



Create a function that will disable command button in all form... Works 100%... plus 1 for accessin

by Stray (3 Submissions)
Category: Custom Controls/Forms/Menus
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Thu 3rd January 2002
Date Added: Mon 8th February 2021
Rating: (1 Votes)

Create a function that will disable command button in all form... Works 100%... plus 1 for accessing this code....

Rate Create a function that will disable command button in all form... Works 100%... plus 1 for accessin



   FrmCtrl Me  
End Sub

'Copy and paste this code in a module
Function FrmCtrl(FrmName As Form)
   Dim ICtrl as Control

   For Each ICtrl In FrmName.Controls
     If TypeOf ICtrl is CommandButton Then FrmName.ICtrl.Enabled = False
     'If... another Control goes here....
   Next
End Function

Download this snippet    Add to My Saved Code

Create a function that will disable command button in all form... Works 100%... plus 1 for accessin Comments

No comments have been posted about Create a function that will disable command button in all form... Works 100%... plus 1 for accessin. Why not be the first to post a comment about Create a function that will disable command button in all form... Works 100%... plus 1 for accessin.

Post your comment

Subject:
Message:
0/1000 characters