Crash when Script cannot find folder/file

Post here to ask questions about or get help with the scripting module of QCAD 2.1/2.2.

Moderator: andrew

Locked
Mschmidt
Newbie Member
Posts: 5
Joined: Fri Jun 06, 2008 4:37 pm
Location: Calgary, Alberta, Canada

Crash when Script cannot find folder/file

Post by Mschmidt » Tue Oct 07, 2008 5:21 pm

I've discovered that the program will crash when the script line cannot find the specific file or folder...

Code: Select all

    var ins = new Insert(doc, "templates/TitleBlock", 0, 0, 1.0, 0.0);
    doc.addEntity(ins);
Anyone else have this problem?
Any code to do a check for instance? (i.e. if ( filename.isReal ) )

Maybe this has something to do with the last post I made.

http://www.ribbonsoft.com/rsforum/viewtopic.php?t=420

User avatar
andrew
Site Admin
Posts: 5556
Joined: Fri Mar 30, 2007 6:07 am

Post by andrew » Wed Oct 08, 2008 3:13 pm

Have a look at class File, function exists:
http://doc.trolltech.com/qsa-1.2.2/exte ... ework.html

Locked

Return to “QCAD 2.1/2.2 Developers”