[Gambas-user] About Replace$

Daniel daniel.campos at ...338...
Sun May 30 14:41:54 CEST 2004


El dom, 30-05-2004 a las 14:21, Héctor Fernández López escribió:
> Hi, i try to convert every space in a string in a \+space for passing it to a 
> process as a unique parameter.  I use:
> SomeString = Replace$(SourceString, " ", "\ ")
> and it says me:
> Bad character constant in string en linea 31 en Principal.class
> 
> am i doing something wrong?

'\' is an special character, to represent carry returns and other
special control characters, so I think you should use this instead:

SomeString = Replace$(SourceString, " ", "\\ ")

Like C,C++ or bash

Regards,

Daniel Campos



> 
> 
> -------------------------------------------------------
> This SF.Net email is sponsored by: Oracle 10g
> Get certified on the hottest thing ever to hit the market... Oracle 10g. 
> Take an Oracle 10g class now, and we'll give you the exam FREE.
> http://ads.osdn.com/?ad_id=3149&alloc_id=8166&op=click
> _______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user





More information about the User mailing list