str = str.Replace("\"", string.Empty); fixed my problem, thanks a lot.
I am interesting your solution "@", for I read document also mentioned @ can
remove the escape character.
this is my code
RegistryKey readiexplorer1 =
Registry.ClassesRoot.OpenSubKey(iexplorer_registry , true);
String default_iexplorer = (String)readiexplorer1.GetValue("");
string launch_iexplorer_path = default_iexplorer +
default_command_path;
RegistryKey readiexplorer2 =
Registry.ClassesRoot.OpenSubKey(launch_iexplorer_p ath, true);
string launch_iexplorer = (String)readiexplorer2.GetValue("");
I got launch_iexplorer ="\"C:\Program Files\Internet Explorer\iexplore.exe\"
-nohome"
How can I remove the escpe character based on @?
"Chris Hyde" wrote:
Steve wrote: string str ="\"C:\Program Files\Internet Explorer\iexplore.exe\" -nohome"
How can I remove charcter to
string str = ="C:\Program Files\Internet Explorer\iexplore.exe -nohome"
I'm not entirely sure of what you are asking here, since in both
examples the escape character exists. If you mean how can you make the
string so that it "ignores" the escape character, you can define it like so:
string str = @"C:\Program Files\Internet Explorer\iexplore.exe -nohome";
The @ symbol forces the creation of a "literal string", in which escape
characters are not interpreted as such.
HTH...
Chris