Re: Report Heading Parameter Look-up

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Jim Shaw (jeshaw2_at_comcast.net.work)
Date: 01/03/05


Date: Mon, 3 Jan 2005 17:36:02 -0500

Never mind, I figured it out...I was not putting the 103 in single quotes!
This works =DLookUp("ParamText","tblAppState","ParamCode = '103'")

Thanks
Jim

"Jim Shaw" <jeshaw2@comcast.net.work> wrote in message
news:eI3wxLe8EHA.2608@TK2MSFTNGP10.phx.gbl...
> I tried : =DLookUp("ParamText","tblAppState","ParamCode = " & 103)
> also tried =DLookUp("ParamText","tblAppState","ParamCode = 103")
> Both gave me the result of "#Error" in my textbox field. I've double
> checked the table definition against my code and can't see the source of
the
> problem.
>
> The underlying query already has an outer join so I'd have to do several
> stacked queries to get the data in that way, so I was hoping for the
> Dlookup() to work.
>
> Thanks
> Jim
>
>
> "Marshall Barton" <marshbarton@wowway.com> wrote in message
> news:eobjt0dqj71s9cs1m983jjoqkq0gr3ebp4@4ax.com...
> > Jim Shaw wrote:
> >
> > >BlankIn my report heading is the name of a contact person to be called
> when
> > >the report users need to ask a question about the report. The name of
> the
> > >contact is in a parameter table:
> > > tblAppState
> > > -------------
> > > ParamCode Integer
> > > ParamText Text
> > >
> > >A ParamCode value of 103 points to the record with the contact's name.
> > >When I run the report, I want to access this name and put it into the
> report
> > >heading.
> > >How can I do this without doing an outer join of my underlying data
table
> to
> > >tblAppState?
> >
> >
> > Doing the Join would be the most efficient, but you can also
> > use a text box expression to look up the contact:
> >
> > =DLookup("ParamText""tblAppState", "ParamCode=" & ParamCode)
> >
> > --
> > Marsh
> > MVP [MS Access]
>
>



Relevant Pages

  • Re: input of complex number
    ... You can do that if you don't mind some algebraic goings-on. ... The single quotes are still there but don't appear on the stack. ... I allways forget about the trignometric expression. ...
    (comp.sys.hp48)
  • Re: input of complex number
    ... How can I use variables for the absolute value and the argument of a ... You can do that if you don't mind some algebraic goings-on. ... The single quotes are still there but don't appear on the stack. ...
    (comp.sys.hp48)
  • Re: Speeding question, " vs
    ... It just crossed my mind, that I usually do it like this: ... I can't say whats faster because the difference is so small that if i iterate both methods 10M times the result get corrupted by external factors like if there are other tasks that "steal" cpu time. ... From the logical point of view single quotes should be faster because single quotes don't support varibale substitution. ...
    (comp.lang.php)
  • Re: Quick sed question -- thanks
    ... Please keep in mind that this is just a first pass attempt to help you ... The thing that jumps out at me from your 'snippet' is that the single ... interpreter expanding/replacing the $LINENO variable. ... This will cause those single quotes to be interpreted as ...
    (comp.unix.shell)