Jump to content
Developer Wiki and Function Reference Links ×

XML file creation error codes


Recommended Posts

I am trying to write an XML file with the procedure 

 

result := WriteXMLFile(hXML, -1, XMLFilePathName); 

 

Unfortunately, the result is equaling -1028

result = -1028

 

1. What does -1028 mean?

2. Is there s list of the error codes generated by file creation and specifically XML file creation

 

TIA

Link to comment

I don't have a list of error codes, but after a few minutes of playing I think it is the -1 path that is the problem.

 

It appears based on comments on the developer wiki reference list that you can't access the 1 and 12 (Applications folder and User App Data) folders. When I try I get the -1028 error.

 

Try -15 for now. This is the Settings folder in the User Library:Application Support:Vectorworks:2019:Settings.

 

It appears to create the file with no problem there.

Link to comment

Actually -2 works just fine.  The problem was a "/" instead of a "\" in the XML element description.  I later ran into a problem with a space in the XML element name.  However, you should know that accessing the User Folder's Plug-ins folder is easily done with the GetFolderPath(-2).  I do it all the time.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...