If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Conditional Formatting Programming
In Access 2007, I want to program the detail fields in a report so that they
will be bolding when the amount field is more than $500. I am using a form to open the report so this has to be done through VBA. How is that done? |
#2
|
|||
|
|||
Conditional Formatting Programming
LA Lawyer,
That can be handled by Conditional Formatting. In design mode, highlight the field you want to Bold, and select Format/Conditional Formatting from the menu bar. Expression Is [YourNum] 500 And then select the Bold button. -- hth Al Campagna Microsoft Access MVP http://home.comcast.net/~cccsolutions/index.html "Find a job that you love... and you'll never work a day in your life." "LA Lawyer" wrote in message ... In Access 2007, I want to program the detail fields in a report so that they will be bolding when the amount field is more than $500. I am using a form to open the report so this has to be done through VBA. How is that done? |
#3
|
|||
|
|||
Conditional Formatting Programming
Yes, I understand that.
However, I am using the report form for different purposes and sometimes I want the bolding to be added and sometimes not. That's why I need a VBA snippet to turn the conditional formatting on and off. "Al Campagna" wrote in message ... LA Lawyer, That can be handled by Conditional Formatting. In design mode, highlight the field you want to Bold, and select Format/Conditional Formatting from the menu bar. Expression Is [YourNum] 500 And then select the Bold button. -- hth Al Campagna Microsoft Access MVP http://home.comcast.net/~cccsolutions/index.html "Find a job that you love... and you'll never work a day in your life." "LA Lawyer" wrote in message ... In Access 2007, I want to program the detail fields in a report so that they will be bolding when the amount field is more than $500. I am using a form to open the report so this has to be done through VBA. How is that done? |
#4
|
|||
|
|||
Conditional Formatting Programming
On Tue, 21 Jul 2009 12:45:52 -0700, LA Lawyer wrote:
Yes, I understand that. However, I am using the report form for different purposes and sometimes I want the bolding to be added and sometimes not. That's why I need a VBA snippet to turn the conditional formatting on and off. "Al Campagna" wrote in message ... LA Lawyer, That can be handled by Conditional Formatting. In design mode, highlight the field you want to Bold, and select Format/Conditional Formatting from the menu bar. Expression Is [YourNum] 500 And then select the Bold button. -- hth Al Campagna Microsoft Access MVP http://home.comcast.net/~cccsolutions/index.html "Find a job that you love... and you'll never work a day in your life." "LA Lawyer" wrote in message ... In Access 2007, I want to program the detail fields in a report so that they will be bolding when the amount field is more than $500. I am using a form to open the report so this has to be done through VBA. How is that done? Code the Detail Format event: Me.[ControlName].FontBold = Me.[OtherControlName] 500 If you wish to be able to use the exact same report and have the option to turn Bold on or off from a form, add a check box to the form. Change the code in the report to: Me.[ControlName].FontBold = Me.[OtherControlName] 500 and forms!FormName!CheckName = -1 Placing a check in the form check box will turn Bold on if the value is 500. Remove the check and the report control will not be bold even if the other control's value is 500. Remember, however, the form must be open when the report is run. -- Fred Please respond only to this newsgroup. I do not reply to personal e-mail |
#5
|
|||
|
|||
Conditional Formatting Programming
LA Lawyer,
sometimes I want the bolding to be added and sometimes not. A whole different question... Fred G has the solution using the OnFormat event of the report. -- Al Campagna Microsoft Access MVP http://home.comcast.net/~cccsolutions/index.html "Find a job that you love... and you'll never work a day in your life." "LA Lawyer" wrote in message ... Yes, I understand that. However, I am using the report form for different purposes and sometimes I want the bolding to be added and sometimes not. That's why I need a VBA snippet to turn the conditional formatting on and off. "Al Campagna" wrote in message ... LA Lawyer, That can be handled by Conditional Formatting. In design mode, highlight the field you want to Bold, and select Format/Conditional Formatting from the menu bar. Expression Is [YourNum] 500 And then select the Bold button. -- hth Al Campagna Microsoft Access MVP http://home.comcast.net/~cccsolutions/index.html "Find a job that you love... and you'll never work a day in your life." "LA Lawyer" wrote in message ... In Access 2007, I want to program the detail fields in a report so that they will be bolding when the amount field is more than $500. I am using a form to open the report so this has to be done through VBA. How is that done? |
#6
|
|||
|
|||
Conditional Formatting Programming
L.A. Lawyer; is saying "Thank you" too high a price to pay for
valuable services rendered? The responses you've received in this thread alone saved you from many hours to many days of research. Your original post in this thread was promptly answered with a solution that was right on the mark. Your response was "Oh, yes, I understand that but what I really want (but didn't tell you) is that it not only do that but also do this other thing". Again you received a response that was right on the mark. This time you not only didn't say "Thank you", you didn't even acknowledge it. I suggest that you visit www.mvps.org/access and read "Netiquette". It explains a lot of the quirky behaviors and folkways and expectations of those of us who hang out in these Access newsgroups. These newsgroups are provided by microsoft so that they and their customers get the benefits of peer support from developers at all levels to developers at all levels. All service here is provided free of charge by unpaid volunteers. There is one persistent troll who attempts to prey on newbies. A few interlopers sometimes try it too. Legitimate service here is limited to helping people over a single technical hurdle or issue per thread and occasional general concept and general knowledge about the product at hand. Service for hire and free consulting and development are not on offer here Your questions about Access issues are welcome. First make a good effort to solve your issues yourself and learn to use the resources at your disposal. Many of the MVPs are the products of self-directed study: Help files, these newsgroups and (libraries of) books and newsletters and magazines, We're not an homogeneous group. We all have different styles of approach and completeness. We all want to help budding developers become journeymen and craftsmen/artisans (choose your gender). HTH -- -Larry- -- "LA Lawyer" wrote in message ... In Access 2007, I want to program the detail fields in a report so that they will be bolding when the amount field is more than $500. I am using a form to open the report so this has to be done through VBA. How is that done? |
Thread Tools | |
Display Modes | |
|
|