You are beautiful person. I tried posting about this quite a while back and
no one who responde could quite help me. I did try the EVAL function but had
my syntax wrong. i was trying to do it without the parenthesis.
I just tested it and it works. that will make life so much easier.
thanks
Tony
I'm glad I am not the one who will have to debug that code.

Signature
Dave Hargis, Microsoft Access MVP
> You are beautiful person. I tried posting about this quite a while back and
> no one who responde could quite help me. I did try the EVAL function but had
[quoted text clipped - 44 lines]
> >> thanks
> >> Tony Vrolyk
John Spencer - 12 Jul 2007 00:34 GMT
Amen to that.
'====================================================
John Spencer
Access MVP 2002-2005, 2007
Center for Health Program Development and Management
University of Maryland Baltimore County
'====================================================
> I'm glad I am not the one who will have to debug that code.
Tony Vrolyk - 12 Jul 2007 17:57 GMT
Now I am curious why you say that. If you meant to imply that my coding in
general must be bad if I fogot the parenthesis - I did not mean the ones
required by the EVal funtion but rather the ones required by the function
within the Eval.
i.e.
EVAL(me.lstbox & "(" & lngArgument & ")")
vs
EVAL(me.lstbox lngArgument)
Before the Eval I called them like this
fFunctionName Argument1
Having not used the Eval before I assumed that within the Eval you would
call a function the same way you would outside the Eval. In this case these
functions do not require the parnethesis when run on their own. So I don't
think that is an unreasonable assumption.
Tony
> I'm glad I am not the one who will have to debug that code.
>
[quoted text clipped - 52 lines]
>> >> thanks
>> >> Tony Vrolyk
Tony Vrolyk - 12 Jul 2007 18:05 GMT
Sorry - my sent items only shows one, not sure what happened there.
> Now I am curious why you say that. If you meant to imply that my coding
> in general must be bad if I fogot the parenthesis - I did not mean the
[quoted text clipped - 74 lines]
>>> >> thanks
>>> >> Tony Vrolyk
John Spencer - 12 Jul 2007 19:13 GMT
No, I wasn't being critical of your coding. What I meant was that debugging
code that has a problem is difficult enough without having to work out which
function was being called depending on which string was in the field could
be tough.
I have actually used a similar technique to handle some complex importation
of legacy data that had to be manipulated different ways depending on the
year of the data file and the field name of the data itself. Long Story -
and it was difficult to debug and I had written the code and was very
familar with what was supposed to happen.

Signature
John Spencer
Access MVP 2002-2005, 2007
Center for Health Program Development and Management
University of Maryland Baltimore County
.
> Now I am curious why you say that. If you meant to imply that my coding
> in general must be bad if I fogot the parenthesis - I did not mean the
[quoted text clipped - 74 lines]
>>> >> thanks
>>> >> Tony Vrolyk
Tony Vrolyk - 12 Jul 2007 19:20 GMT
Gotcha. Sorry to be so sensative.
I think in this case it will be relatively easy. I am keeping as much
similarity between the functions called by the Eval as possible - same
number of arguments, same argument types, etc..
Thanks again
tony
> No, I wasn't being critical of your coding. What I meant was that
> debugging code that has a problem is difficult enough without having to
[quoted text clipped - 85 lines]
>>>> >> thanks
>>>> >> Tony Vrolyk
Tony Vrolyk - 12 Jul 2007 17:58 GMT
Now I am curious why you say that. If you meant to imply that my coding in
general must be bad if I fogot the parenthesis - I did not mean the ones
required by the EVal funtion but rather the ones required by the function
within the Eval.
i.e.
EVAL(me.lstbox & "(" & lngArgument & ")")
vs
EVAL(me.lstbox lngArgument)
Before the Eval I called them like this
fFunctionName Argument1
Having not used the Eval before I assumed that within the Eval you would
call a function the same way you would outside the Eval. In this case these
functions do not require the parnethesis when run on their own. So I don't
think that is an unreasonable assumption.
Tony
> I'm glad I am not the one who will have to debug that code.
>
[quoted text clipped - 52 lines]
>> >> thanks
>> >> Tony Vrolyk