Results 1 to 7 of 7
  1. #1
    Join Date
    Feb 2005
    Location
    Princeton, NJ USA
    Posts
    13

    Unanswered: Can't find report FormatConditions(0)

    I am picking up a A2k db that was created/modified and played with by a lot of people and now I get the job of getting it to work - so with lots of different hands in this db there are lots of unique twists.

    One that I can not find is unique formatting based on the values of a couple of fields. I can not find any code behind this report - but when it executes there is clearly bold/underline and shading that occurs based on the values of a couple of key data elements.

    I used Speed Ferret and found conditional references to:
    dbname.Reports("reportname").Controls("controlname ").FormatConditions(0)
    but as I mentioned I can not find out where to get to these format conditions to revise them.

    Within Speed Ferret the property of the format conditions simply mentions the data conditions but not the formatting. I tried renaming the data element through Speed Ferret but the report simply fails with the message 'The Microsoft Jet database engine does not recognize "changedelementname" as a valid field name or expression.'

    I have a feeling that it is probably pretty simple - but I haven't been able to get there. Any suggestions?
    Thanks,

  2. #2
    Join Date
    May 2004
    Location
    New York State
    Posts
    1,178
    Have you opened the report's Property Sheet? That's the first place to look for things like that. Each control has its unique properties in the Sheet.

    To open the Sheet, right-click on the report's upper left hand (square) corner (NOT in the toolbox or in the toolbars) and select Properties.

    Sam

  3. #3
    Join Date
    Feb 2005
    Location
    Princeton, NJ USA
    Posts
    13
    I've tried the property sheet for the report and the detail section of the report (and every other section) and still do not see any event driven code behind this report. Since TextBoxes do not have "Events" I can't find anything on the specific data elements but have tried looking anywhere I can think. Hence my confusion.

  4. #4
    Join Date
    Feb 2004
    Location
    Chicago, IL
    Posts
    1,312
    The only thing I can think of is that you can put in the function call in the event property without it showing in the report's module.

    I would check the properties of the section where the textbox/control is, check the event properties and you might find them there.

  5. #5
    Join Date
    May 2004
    Location
    New York State
    Posts
    1,178
    Something else just occurred to me. In the report's property sheet, scroll all the way down to the third-from-the-last property, Has Module. Does it say Yes? Maybe your VBA modules are hidden.

    Also, click on the Window pull-down menu in the toolbar. Does the Unhide option appear in black, or is it disabled? If it's black, click on it, and select whatever it gives you. Maybe you'll yet find the elusive module.

    Sam

  6. #6
    Join Date
    Feb 2005
    Location
    Princeton, NJ USA
    Posts
    13
    Sam,

    Thanks for your help and guidance. I think you may be on to something here. The Report Properties "Has Module" is set to yes - but I still can't find it and the "UnHide" option is greyed out and not available.
    In playing with a test copy of the db I tried setting the Has Module property to No and the warning message window appeared telling me that it would delete the code and the report will open more quickly. Given how slow this report is to edit/save/run I think you may have found one cause of that problem.

    Now if I could just find that module...
    Thanks again for your assistance and guidance!
    Allen

  7. #7
    Join Date
    Feb 2005
    Location
    Princeton, NJ USA
    Posts
    13
    I found the elusive code!

    In looking at another post someone mentioned "Conditional Formatting". I then selected one of the data elements and chose Conditional Formatting from the Format menu - and lo and behold - there were the conditions and code that I had been unable to find.
    I had never used this Conditional Formatting option and had always done things through VBA.

    Thanks,
    Allen

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •