Debugger is getting mixed up

  • Thread starter Thread starter cmdolcet69
  • Start date Start date
C

cmdolcet69

I have the fololwing code, it is simple yet the flag will never be hit
for some odd reason

Dim STRdata as string
Dim setRedFlag as boolean

If STRdata = "" then
setRedFlag = true
end if


When i debug the line I get a string value for STRdata = "1.00"
however if STRdata = ""

and i add watch on STRdata= it will give me a value of true

Why is the debugger getting mixed up?
 
This is answered in the thread where you first asked the question. Put
simply, you cannot rely on the characters displayed in a debugger watch to
prove that a string is equal to "" or to nothing. A string can include
things that are not displayable.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top