Conditional Formatting and "Has Module" (1 Viewer)

scalkins4

New member
Local time
Today, 05:11
Joined
May 18, 2013
Messages
2
Wrestled with a conditional formatting issue today for awhile. Successfully applied CF to one form. Then started working on a similar form I hadn't used in awhile. When I tried to apply conditional formatting to any of the controls the CF saved the expressions, but wouldn't display the conditional format. So I came straight to the forum. I tried many of the CF fixes suggested here, but they were all NoGo's.

Finally resorted to comparing all "Form Properties" and "Properties" in both forms. Buried deep in the Form Properties I found a difference. The "Has Module" in the non-working form was set to Yes. I don't remember setting to Yes. I changed it to No and the CF started to work.

Could the No to Yes switch have happened automatically when I copied and pasted the form to reuse it?
 

rzw0wr

I will always be a newbie
Local time
Today, 06:11
Joined
Apr 1, 2012
Messages
489
When you copy a from you copy everything.
Code, properties, the whole works.
 

missinglinq

AWF VIP
Local time
Today, 06:11
Joined
Jun 20, 2003
Messages
6,423
...The "Has Module" in the non-working form was set to Yes. I don't remember setting to Yes...
That;s because you didn't! Yes is the Default Setting for this Form Property. With it set to No, there can be no VBA code behind the Form. In point of fact, changing it from Yes to No has deleted any contents from the Form's Code Module.

More importantly, this making a difference in CF working suggests to me that you may very well have some type of corruption going on with the Form.

What kind of Conditional Formatting are you talking about, here? The one positive thing setting this Property to No does is cause the Form to run much faster, and I suppose it might improve the response time if you have complex expressions being used in your CF. Response time for CF is sometimes a problem.

Linq ;0)>
 

scalkins4

New member
Local time
Today, 05:11
Joined
May 18, 2013
Messages
2
Thanks Linq, that's good to know. I haven't written any VBA in this db. I know VBA is very powerful, but programming isn't my core competency. I use Access to support my day to day activities and turn a db over to developers when others see a need to distribute it outside my area. Can you suggest a good VBA reference for a beginner?
 
Last edited:

missinglinq

AWF VIP
Local time
Today, 06:11
Joined
Jun 20, 2003
Messages
6,423
When asked this question I always give this link:

http://www.functionx.com/vbaccess/index.htm

The page has a headline alluding to Access 2010, but they always insert the latest released version, although 90-95% of all VBA info applies to all versions since 2000!

FunctionX offers 28 clearly titled, well thought out lessons, complete with examples.

A site that many of us use and cite on a regular basis is Allen Browne’s Access site:

http://allenbrowne.com/tips.html

Much of the material would rate more than a 'beginner's' rating, but it's still a site you should bookmark, for it is sure to come in handy, sooner or later! A number of Allen's articles have been co-opted by Microsoft for their official Access 'help' site.

Linq ;0)>
 

Users who are viewing this thread

Top Bottom