Text box changes

FACTOR 21

Board Regular
Joined
Mar 3, 2014
Messages
110
I have a text box that pulls the Windows User Id into a form, I need this to set once a new record is created and not to change when someone else views the record.

The user id is pulled via a module and this module is referenced in the default value field on the Data tab of the properties sheet.

Code:
Public Function getWinUser() As String
getWinUser = Environ("UserName")
End Function

Thanks in advance
 

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.
I need this to set once a new record is created and not to change when someone else views the record.
Then you want to store it in a field in an underlying table, so that the field is "bound".
That is the only way to have it remember the value.
 
Upvote 0

Forum statistics

Threads
1,196,288
Messages
6,014,481
Members
441,821
Latest member
IG89

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top