BricsCAD Mac DCL dialog error

Hello,
I have a LISP routine which uses a DCL dialog, created for OtherCAD 12 years ago, works perfectly in BricsCAD for Windows.
On latest BricsCAD for Mac, it stops with an error :

       5: syntax error - unexpected symbol ':' 

which is strange because ':' is part of the standard DCL syntax, I really don't see what I could
use instead (has it something to do with the fact that the colon was the Mac's folder separator in ancient times ?),
and I haven't found anything in the LDSP on that subject.

Thanks for any insights,
Fabien.

Comments

  • The warning most likely means the symbol occurs in an unexpected position. Can you post the DCL?

  • @Roy Klein Gebbinck said:
    The warning most likely means the symbol occurs in an unexpected position. Can you post the DCL?

  • @Fa3ien said:

    @Roy Klein Gebbinck said:
    The warning most likely means the symbol occurs in an unexpected position. Can you post the DCL?

    Well, I've found the culprit !
    The problem was the presence of extended chars (french accents) in the previous line.
    The file was encoded with Windows 1252 or ISO-8859-1 (which is pretty normal since it was written in notepad).
    Saving it in UTF-8 (without BOM) solved the problem.

    I don't know if it qualifies as a "bug" in BC for Mac, but other people might encounter the problem someday,
    in a company where PCs and Macs share the same DCL file.

    Fabien.

  • I use notepad ++ and often just paste into plain notepad to stop bugs like this. Using word is a big No NO writing lips code as so many hidden characters get created so again paste to notepad from WORD and then save.

    I use word as you can do replace using end of line. Notepad++ has it also.

  • Dear Fabien,

    in a HexEditor I found several sequences :
    0x09 0x3A == .:
    (dot for character without visual representation)
    so that 0x09 character originates from a) non-ANSI/ASCII editor ? b) copy/paste using such editor ?

    Otherwise, saving as ANSII file should also work on Linux/Mac (incl. French characters), as long as the Linux/Mac is configured to use French code-pages ...
    many greetings !

  • @Torsten Moses said:
    Dear Fabien,

    in a HexEditor I found several sequences :
    0x09 0x3A == .:
    (dot for character without visual representation)
    so that 0x09 character originates from a) non-ANSI/ASCII editor ? b) copy/paste using such editor ?

    Otherwise, saving as ANSII file should also work on Linux/Mac (incl. French characters), as long as the Linux/Mac is configured to use French code-pages ...
    many greetings !

    The DCL file has been created/edited with Notepad or Notepad++. Maybe some code have been pasted from the Web. However,
    replacing accented chars with non accented ones ("é" -> "e") also "solved" the problem, that's how I thought about converting to UTF-8.

  • Dear Fabien,

    it might be possible, that NotePad/NotePad++ automatically switch to UTF-8 if they encounter any character above 0x7F :-(
    I encountered this as well with UltraEdit (there, such automatic switch can be disabled in Settings);
    saving a file with characters above 0x7F in ANSI file is fine - as long as it is used on a system with same code page :-)

    So keep an eye on NotePad/NotePad++ whether it switches to UTF-8, and/or force saving as ANSI then.
    many greetings !

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. Click one of the buttons on the top bar to get involved!