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

Crash when Script cannot find folder/file

Postby 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
Mschmidt
Newbie Member
 
Posts: 5
Joined: Fri Jun 06, 2008 4:37 pm
Location: Calgary, Alberta, Canada

Postby 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
User avatar
andrew
Site Admin
 
Posts: 2524
Joined: Fri Mar 30, 2007 6:07 am


Return to QCAD 2.1/2.2 Developers

Who is online

Users browsing this forum: No registered users and 1 guest

cron