Link to home
Start Free TrialLog in
Avatar of bwaller
bwaller

asked on

" does not work (VB6)

I'm trying to use the Shell command to launch an external application.  The command line I need to use has parameters.  I've reviewed many answers in this forum, and most talk about using the " keyword to replace quote marks.  However, when I try to use this approach, I get a Compile Error: Expected expresson.

Example:

    Dim sString As String
    sString = "This is a string "

Is there some setting which allows VB to interpret " as a quote?

Thanks
Avatar of Erick37
Erick37
Flag of United States of America image

Chr(34) is the "

sString =Chr(34) & "This is a string" & Chr(34)
Avatar of bwaller
bwaller

ASKER

I'm aware of Chr(34), but I keep seeing references to "
Why doesn't this work for me?
where are you seeing references to " ?  becuase that will NEVER work in VB or VBScript.

AW
&Quot; is used in HTML
Avatar of bwaller

ASKER

Arthur,

Do a search for "quote" in the Visual Basic section.  You'll see " in almost every answer.
ASKER CERTIFIED SOLUTION
Avatar of vinnyd79
vinnyd79

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
vinnyd79 is right on...I have NEVER seen notation like " in ANY Visual Basic section answer, and I have been on this site DAILY for almost 2 years.  It has something to do with YOUR browser, or how YOU are accessing the pages, and that notaion is NOT in the original text as posted to the page, by the user entering the response.

AW
Avatar of bwaller

ASKER

Vinny, Arthur,

Your answers make sense.  I wonder what the problem is with my browser (IE6).  I guess that's a question for a different forum.  Thanks for your help.