As was foretold, we've added advertisements to the forums! If you have questions, or if you encounter any bugs, please visit this thread: https://forums.penny-arcade.com/discussion/240191/forum-advertisement-faq-and-reports-thread/
Options

Access problem re: reports and values

jclastjclast Registered User regular
edited April 2008 in Help / Advice Forum
Okay, got an Access problem. I've got a shitty form called 'Form1' and a shitty list called 'List1' that has 2 tabs each of which display report numbers, and 3 other fields that don't matter. Clicking on a report number and then hitting print, in theory, generates a report and prints it. This works fine in the first tab (active reports) but shitty in the second tab (archived reports).

I see what it's doing wrong: when I click print it assigns the report number into a var. Active reports are numbered like so: RPT-0001 while archived reports are numbered like this: RPT-0002(01) to indicate a rev number. The variable fills in fine when I select RPT-0001 from the active list, but it fills in as RPT-0002 instead of RPT-0002(01) when I select from the archived list. For what it's worth, the assign statement looks like this:
rpt = Forms![Form1]![report number]

Both columns are text, and the archived report number is stored as one continuous string (i.e., it is really stored as RPT-0002(01).)

camo_sig2.png
jclast on

Posts

  • Options
    mspencermspencer PAX [ENFORCER] Council Bluffs, IARegistered User regular
    edited April 2008
    Around my office I'm considered an MS Access "expert" but I deny the appellation. I'll still try to help.

    I think I need more detail, or at least confirmation that my guesses are correct:
    Form1 has a control called [report number] whose value is derived from the values of two List controls. Right?

    If so, what are these list controls called and what data populates them?

    Maybe it'd help explain things if you take each of the controls on that form and list everything about them. What control type, what row source if it's a list or combo box, control name, data bound to what, etc.

    Once I know that I can drum up a statement for you that should accomplish what you need, and even explain how it works if it ends up being an ugly nested IIF() and DLookup() monster.

    I may forget to check back here, so feel free to bug me on Live (since I know you either are currently or used to be on my friend list) at GT "Michael Spencer" -- just remind me to read the Access question thread again and I'll come back here. :-)

    mspencer on
    MEMBER OF THE PARANOIA GM GUILD
    XBL Michael Spencer || Wii 6007 6812 1605 7315 || PSN MichaelSpencerJr || Steam Michael_Spencer || Ham NOØK
    QRZ || My last known GPS coordinates: FindU or APRS.fi (Car antenna feed line busted -- no ham radio for me X__X )
Sign In or Register to comment.