Self-reference control in UDF

toast

Registered User.
Local time
Today, 23:56
Joined
Sep 2, 2011
Messages
87
Hello all,

I have a UDF in a module which is the controlsource of multiple textboxes.

In addition to setting the value of the textbox, I'd like the UDF to set the fore and back colors rather than use conditional formatting (I'm attempting to speed up a very slow report).

However, I can't find a way to self-reference the textbox in order to set the fore and back colors.

It'll be great if somebody has a suggestion about the best way to do this!
 
Depending on where the UDF is called, there are variable Control Source returned ?
Can you have a line of code before the UDF is called that holds the Properties you wish to set ?
Would a Global Variable be able to hold the key to what color to use ?
Late versions include TempVar that is an easy alternative to Global Variables.
 

Users who are viewing this thread

Back
Top Bottom