Jump to content
Developer Wiki and Function Reference Links ×

Getting VW file list


Recommended Posts

It is possible to import resources from a file into the current file.  There are a variety of ways to do this with BuildResourcList() and ImportResourceToCurrentFile() and CopySymbol().  All of these require that the script maker know the file name or folder name containing the resource.  Is it possible to present the user with a Finder brower or Director trouser similar to the one presented with the PutFile() command?  I would like to present the user with a way to find a file or folder from which to import resources.  Possible ??

 

Link to comment

I don't see how these help.  They don't let the user look around their hard disk for the file they want to get resources from.  With "PutFile", the user can look around their hard disk for the text file they desire.  Perhaps, you have nifty little algorithm that simulates this functionality for finding .vwx files?????

 

Link to comment

Unfortunately, I cannot get that to work.  This code from the developer wiki fails to allow the selection of a .vwx file.

 

PROCEDURE Example;

VAR

    fileName, title :STRING;

    defaultFolder :STRING;

    mask :STRING;

BEGIN

    title := 'Select the object library file...';

    defaultFolder := '';

    mask := '*.vwx';

    fileName := 'Drafting Tools.vwx';

    IF GetFileN(title, defaultFolder, mask, fileName) THEN

        AlrtDialog(fileName);

END;

RUN(Example);

Link to comment

Unfortunately, I don't think Vectorscript has any commands dealing with files outside of text files for logs or resources.  I think you might need to use Python's ability to deal with files using PythonBeginContext and PythonExecute to pull Python coding into Vectorscripts.  As a disclaimer, I have not yet tried this, but I suspect it's very possible.

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...