mchalkley
|
| Posted: 04/23/2003, 2:00 PM |
|
How do I make UserID be the default value for a field?
Thanks,
Mark C.
|
|
|
 |
mchalkley
|
| Posted: 04/23/2003, 2:45 PM |
|
Never mind.
I fixed it by putting 'CCGetUserID()' in the Default property.
|
|
|
 |
mchalkley
|
| Posted: 04/23/2003, 11:25 PM |
|
Actually, CCGetUserID won't work, as it turns out. Putting that in the "Default" property only sets it when inserting new records.
I need to be able to set the field to UserID every time a record is updated (or inserted).
Any ideas?
|
|
|
 |
Hamilton
|
| Posted: 04/25/2003, 8:57 AM |
|
You may need to add a hidden field for the user id.
Link the hidden field to the database field.
add a before_show event for the hidden field.
then add code similar to this;
myformname.hidden_field_name.value = Session("UserID")
If you already have a userid field, change that one to a hidden field.
|
|
|
 |
mchalkley
|
| Posted: 04/25/2003, 10:00 AM |
|
Ok, got it - that works. Thanks!
|
|
|
 |
|