Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to do this?
Message
 
À
Tous
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Titre:
How to do this?
Divers
Thread ID:
00718646
Message ID:
00718646
Vues:
45
Hi All,
I am adding some controls in the form how to do it without repeating the code, like check for the form components and check if the component type = field then do the these actions:
1.Change the Backcolor
2.object.Readonly (true / false)
3.Enable/disable buttons

Code sample:
------------
Me.btnAdd.Enabled = pbbolReadOnly
Me.btnDelete.Enabled = pbbolReadOnly

Me.ToolTip1.SetToolTip(btnDelete, pbstrBtnDelete)
Me.ToolTip1.SetToolTip(btnAdd, pbstrBtnAdd)

Me.txtEnter.ReadOnly = pbbolReadOnly
Me.txtCompanyName_e.ReadOnly = pbbolReadOnly

I would like to know if above actions can be called from a public module to avoid writing same code in every form.

Thank you in advance
<><><><><><><><><><><><><><><><><><><><>
<><> REMEMBER,,,,KNOWLEDGE IS POWER <><>
<><><><><><><><><><><><><><><><><><><><>
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform