CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 Making UserID a default value

Print topic Send  topic

Author Message
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!

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

MS Access to Web

Convert MS Access to Web.
Join thousands of Web developers who build Web applications with minimal coding.

CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.