[AccessD] [Spam]8.31 Re: Modify label on a form in vba and save

Darrell Burns dhb at flsi.com
Wed Jun 1 12:07:38 CDT 2011


Hi Jack. Rather than modify the label, replace the label with a text box.
The control source would be: ="last used Date: " & cstr([datefield])
HTH,
Darrell

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Jack and Pat
Sent: Friday, May 27, 2011 11:19 AM
To: 'Access Developers discussion and problem solving'
Subject: [Spam]8.31 Re: [AccessD] Modify label on a form in vba and save

Thanks Lambert,
I had mentioned saving the Date and concatenating it, which I think is the
best way. 

However, do you have a reference or a procedure for Opening the Form in
design view and modifying the label and saving it. I suppose it could be
done as a separate process when the database is closed.  I haven't tried
opening a form in design mode and modifying with vba.

TIA
Jack

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Heenan, Lambert
Sent: Friday, May 27, 2011 12:20 PM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] Modify label on a form in vba and save

Only if the users have an MDB file that they are working with, and you'd
have to open the form (via code) in design mode to make the change and then
save it. All very messy.

Much simpler way to do this is to save the date in a table. Then when the
form opens you can look up the date in the table and then change the label
caption. All this can be done in the form's Load event.

Lambert

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Jack and Pat
Sent: Friday, May 27, 2011 12:13 PM
To: AccessD Group Discussion
Subject: [AccessD] Modify label on a form in vba and save

 

Hi Group,

I had a question from an Access 2003 user. He has a Form with an option
group and some labels.

On one of the Options he wants to update the label  to include the Date the
option was selected. The result to be that when the Form is opened in
Future, the label for that Option will show that "last used Date" appended
to the original text.

 

?? Is it possible to Update the label on a form, and save the result via
vba?

 

Jack

--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com

-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com

-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com




More information about the AccessD mailing list