[Gambas-user] Possible bug

Charlie charlie at ...2793...
Wed May 15 15:25:46 CEST 2013


Hi Caveat and Benoît,

Thanks for the replys. I will try a workaround, and I am pleased it's 
not a issue for anybody else.

Should you be interested I have created a desktop video of the problem 
and supplied the code that causes my Gambas to crash. You will find the 
files at http://www.cogier.com/gambas/.

I have found that "SDir = Replace(SDir, " ", "\ ")" will cause a crash 
but "SDir = Replace(SDir, " ", "\\ ")" is fine.

Thanks,

Charlie


On 15/05/13 00:55, Caveat [via Gambas] wrote:
> Yeah, I see what you're trying to do. You can use \\ to make a single \
> as the \ is normally the first part of a special character constant
> (e.g. \t makes a Tab character).  I think you can just wrap file/dir
> names with spaces in them in quotes for use in bash scripts.
>
> Oh, and my Gambas doesn't crash with the code exactly as you had it.  As
> Benoit experienced, it just doesn't compile, same for me (compile error
> is"Bad character constant").
>
> Kind regards,
> Caveat
>
> On 15/05/13 01:17, Charlie wrote:
>
> > Hi  Benoit,
> >
> > It may, or may not, be good syntax but press F5 and Gambas crashes. 
> You can not compile it because Gambas crashes.
> >
> > The purpose of the code was to change "dir" string into a form tha 
> BASH would accept from Shell command if there are spaces in the "dir" 
> string.
> >
> > I am not an expert in any of this. I am just tring to help by 
> pointing this issue out. If it is a syntax error Gambas should detect 
> this and not crash.
> >
> > Regards,
> >
> > Charlie.
> >
> >
> >
> >
> >
> > Sent from Charlie's Samsung tablet"Benoît Minisini [via Gambas]" 
> <[hidden email] </user/SendEmail.jtp?type=node&node=41950&i=0>> 
> wrote:Le 14/05/2013 18:09, Charlie a écrit :
> >
> >> Hi all,
> >>
> >> You need one *Button* and one *DirChooser* on your form
> >> I have reduced code to the following to emulate this bug I am 
> getting: -
> >> '*********************************************************
> >> Public Sub _new()
> >> End
> >>
> >> Public Sub Form_Open()
> >> End
> >>
> >>
> >> Public Sub Button1_Click()
> >>
> >> Dim SDir As String
> >> Sdir = DirChooser1.SelectedPath
> >> SDir = Replace(SDir, " ", "\ ")
> > This line is not syntactically correct ("\ "). Please provide a project
> > or at least code that compiles!
> >
> > Regards,
> >
>
>
> ------------------------------------------------------------------------------ 
>
> AlienVault Unified Security Management (USM) platform delivers complete
> security visibility with the essential security capabilities. Easily and
> efficiently configure, manage, and operate all of your security controls
> from a single console and one unified framework. Download a free trial.
> http://p.sf.net/sfu/alienvault_d2d
> _______________________________________________
> Gambas-user mailing list
> [hidden email] </user/SendEmail.jtp?type=node&node=41950&i=1>
> https://lists.sourceforge.net/lists/listinfo/gambas-user
>
>
> ------------------------------------------------------------------------
> If you reply to this email, your message will be added to the 
> discussion below:
> http://gambas.8142.n7.nabble.com/Possible-bug-tp41943p41950.html
> To unsubscribe from Possible bug, click here 
> <http://gambas.8142.n7.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=41943&code=Y2hhcmxpZUBjb2dpZXIuY29tfDQxOTQzfC0xMjY5ODcwMTc2>.
> NAML 
> <http://gambas.8142.n7.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml> 
>





--
View this message in context: http://gambas.8142.n7.nabble.com/Possible-bug-tp41943p41957.html
Sent from the gambas-user mailing list archive at Nabble.com.


More information about the User mailing list