X
PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 11 Jul 2019 11:19 AM by  kwod12
APP_USER_DIR Error in Widget App
 3 Replies
Sort:
You are not authorized to post a reply.
Author Messages

kwod12



New Member


Posts:5
New Member


--
03 Jul 2019 10:34 AM
    I am trying to distribute a Widget based application using a .sav file. The steps I used to create the .sav file are below and are all done in a clean IDL session.


    IDL>.r traj3d_3d_animate
    IDL>RESOLVE_ALL
    IDL>SAVE, /ROUTINES, FILENAME='/path/to/file.sav'


    However, I get an error when the application runs. The error is below:

    % APP_USER_DIR: Null string not allowed in this context: .
    % Execution halted at: TRAJ3D_3D_PLOT_INIT 59
    % TRAJ3D_3D_ANIMATE 326
    % $MAIN$

    Line 59 in the TRAJ3D_3D_PLOT_INIT procedure is a call to the SURFACE() function.

    I've found that if I start IDL, call the SURFACE() function to create a plot (either in X11 or send to the buffer using the /BUFFER keyword) and then RESTORE the save file and call TRAJ3D_3D_ANIMATE, everything works just fine. But, if restore the file and then try to call any function graphics, they give a similar error as the one above.

    Thanks for any help.

    kwod12



    New Member


    Posts:5
    New Member


    --
    08 Jul 2019 11:50 AM
    Just some more information and a minimal working example.

    IDL version 8.7.2

    Have tried starting and IDL session, restoring the .sav file and running the procedure and running idl -vm=/path/to/file.sav with now luck.

    File runs fine on the machine that created it, but does not on other machines, namely ones running IDL v8.5

    Link to source code and .sav file

    https://drive.google.com/drive/folders/1SEt9m61BDPHN_BpVgnQgZDDMzubsAoLu?usp=sharing

    MariM



    Veteran Member


    Posts:2396
    Veteran Member


    --
    09 Jul 2019 01:08 PM
    If you compile it in IDL 8.5, it will launch with the VM from 8.5 and 8.7. In general, we suggest you compile in the oldest version you anticipate an end user having. The older .sav are generally compatible with newer versions of IDL but there is risk in creating a .sav in a newer version and using that program in an older version that may not have the same features.
    It is a curious error. I am investigating if there is something you can do to resolve it.

    kwod12



    New Member


    Posts:5
    New Member


    --
    11 Jul 2019 11:19 AM
    Compiling with v8.5 seems to have fixed the issue. Thank you!
    You are not authorized to post a reply.