Re: Step Mode Values





Joel, there's a small but important difference: e-mail adresses aren't
case-sensitive but string comparisons are. VB(A) doesn't know the meaning of
a string, it can't determine whether a string is an e-mail address or
something else.

The user enters the e-mail address, either in an e-mail or a contact. And
you never know if the address is entered in lower cases or not, because for
the user (and for delivering e-mails) it makes no difference. That is, the
same user can enter the same address once in lower cases and once in upper
ones. You code must recognize both as equal adresses, so for being sure
convert them all either in lower or upper cases.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
-- www.VBOffice.net --

Am Fri, 8 Dec 2006 15:20:00 -0800 schrieb Joel:

Hello Michael:

FYI, I found the value of Recipient.Addess to definetly to be case
sensitive.

Also I used the Watch window to show me the value of the Recipient.Address
and upon copy and paste the value into code all worked fine. The data in
the caption when I looked at values in Step Mode showed all CAPS which in
not
how the watch window showed the data and being case sensitive made the
difference.

Thanks,
Joel

"Michael Bauer [MVP - Outlook]" wrote:



Yes, you can trust the Debugger. At least I could always do that. As for
e-mail addresses: They aren't case sensitive and so your code should
treat
them, you never know what a user enters. Due to that for comparing values
I
always convert them with LCASE.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
-- www.VBOffice.net --

Am Thu, 7 Dec 2006 16:21:01 -0800 schrieb Joel:

TIA:

When running through code in Step Mode when I put my cursor over a
variable
or item property, I see a caption with the current value. Can I really
trust
that this is the exact value (case sensistive text) that would need to
be
in
code to match an eqaulity statement ie if I see a value of "Bob@xxxxxxx
then
for my If to be true I would need If reciepient.address =
Bob@xxxxxxx
Then...

The issue is the caption in Step Mode shows a value in all CAPS but the
data
itself is mixed upper and lower case. I know my code is case sensitive
to
the "actual" email address used in the email To: field.

I would hope a way around is to set a variable for email address and
LCase
the data...

Thanks for any help,

Joel

.



Relevant Pages

  • Re: Step Mode Values
    ... there's a small but important difference: e-mail adresses aren't ... case-sensitive but string comparisons are. ... The issue is the caption in Step Mode shows a value in all CAPS but the ...
    (microsoft.public.outlook.program_vba)
  • Re: [Help] At wits end about zOrder and API
    ... as the owner of Windowand Windowas the owner of your userform? ... > (ByVal lpClassName As String, ... > Dim hWndFocus As Long ... > 'Create a string buffer to hold the owner's caption ...
    (microsoft.public.vb.winapi)
  • Re: Setting control properties through code
    ... Will you be updating other properties as well as the Caption? ... I have a string expression that evaluates to the property name, ... > Dim strcount As String ...
    (microsoft.public.access.formscoding)
  • Re: Label.Caption Question
    ... >>> How can the new Caption be stored after changed? ... retrieve that stored text string and assign it to the Label's Caption ... FileName or registry storage string as desired)... ... Dim FileName As String ...
    (microsoft.public.vb.controls)
  • Re: Report issue -- What is field you want to loop?
    ... The caption field is a concatenate of charectors and field names that is ... required to create the magic string. ... please post the current one for your report recordsource ... MVP Access ...
    (microsoft.public.access.modulesdaovba)