Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Text Box Problem
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00062935
Message ID:
00063093
Vues:
39
>>>>Is there a bug in the wizrards or do I have to do something else?
>>>>
>>>>All I want is for these four fields to be seen and not edited.
>>>
>>>
>>>Are you using Wiz-style command buttons?
>>>
>>>
>>Yes, I made a copy of the library and made some chnges to the
>>Wiz-Style Text Buttons. Removed Print & Delete and Modified the Add
>>Button
>
>The advice on the Wiz-style buttons is use them to view and learn. Do not add them to your project. One of the things that the wiz-style does is that it enables or disables most of your buttons based on the edit mode. You can look into the class if your interested. But I would refrain from using it and develop your own buttons.
>
>HTH

The .SetAllProp method of the txtbtns class sets the .Enabled property for all textboxes and the .ReadOnly property for all editboxes based on your "editmode". It uses .ReadOnly instead of .Enabled for editboxes so that you can scroll them without editing the data. If you attempt to type in the editbox when not in editmode, the class gives you a "read only" message. It also plays around with .Disabledforecolor and .Disabledbackcolor so that textboxes and editboxes will look similar. The .SetAllProp method is called from the txtbtns.Refresh and in some button.clicks, overriding values set in design mode or .Init. It also ignores classes of controls not created by the wizard, such as combos and spinners. If you want to keep your version of txtbtns, you can easily modify it to handle them. Code for handling controls in a particular form that are not to be enabled or disabled according to "edit mode" can be put in the refresh of the form or the form's instance of txtbtns. You may also eventually want to edit it to handle controls inside pageframes, which are not true containers and which it ignores.

If you haven't already invested too much in your button bar, compare txtbtns with the nav button classes in tastrade, then consider using a system more like the one in tastrade, which comes closer to what people here have recommended to me. Tastrade won't take long to figure out, compared to the big frameworks people have been discussing in several other threads recently.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform