mljonzs
Posts: 124
|
| Posted: 02/09/2007, 2:36 PM |
|
I'm really lousy at knowing what to look for in forums so this might be posted somewhere already??
I'm wondering if there is a way (an easy way) to have a field appear as a label under some circumstances - i.e., in Edit Mode and in other circumstances - i.e., Insert Mode - appear as a Text Box?
I know how to use a TextBox and set it to read only for the update/edit mode, but in Edit mode I don't want it to be a text box at all, only in InsertMode.
Can anyone help with this?
Thanks!
Michelle
_________________
What does not begin WITH God, will end in failure!
|
 |
 |
peterr
Posts: 5971
|
| Posted: 02/09/2007, 3:11 PM |
|
You would need to hide one control and show another. Therefore your page would contain both.
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
 |
 |
mljonzs
Posts: 124
|
| Posted: 02/12/2007, 7:05 AM |
|
Good, I'm on the right track anyway then. But can you tell me the best way to code to check for which mode the form is in? I.e. - How do I know if it is in edit mode or insert mode?
Thanks!
Michelle
_________________
What does not begin WITH God, will end in failure!
|
 |
 |
wkempees
Posts: 1679
|
| Posted: 02/13/2007, 7:38 AM |
|
In CCS
Press Help
Search: Editmode
Function articles_OnValidate()
If articles.EditMode and IsEmpty(articles.modified_by.Value) Then
articles.Errors.AddError("The modified_by field cannot be empty when updating.")
End if
End Function
_________________
Origin: NL, T:GMT+1 (Forumtime +9)
CCS3/4.01.006 PhP, MySQL .Net/InMotion(Vista/XP, XAMPP)
if you liked this info PAYPAL me: http://donate.consultair.eu
|
 |
 |
|