cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Check out the JMP® Marketplace featured Capability Explorer add-in
Choose Language Hide Translation Bar
Setsuna
Level II

Open a .jrp file with JSL, but the open function returns nothing

Hello, I met a problem that confused me so much.
When I open a .jrp file using Open() function, nothing is returned.

Names Default To Here( 1 );
rp = Open("<PATH-TO-FILE>\RxOsnrTol-01-Distribution-By(Temperature).jrp");
Show(rp);


Then in the log window, I got:

{Distribution[], Distribution[], Distribution[]}
rp = .;


By the way, the .jrp file is opened and displays normally. It seems that the only problem is the return value is missing.


The .jrp file is saved earlier with embeded data table.

I'm sure that I used the same code several days ago on some other jrp file, the Open() function returns an object. So I'm able to save its picture.
So I'm confused.

JMP Version: 16.2

If any further information or attachment is needed, please tell me.
Thank you very much.

 

===== Update =====

I attached a very simple example which shows the same problem.

For me, the log shows:

Distribution[]
Open(".\abc.jrp") = ␀;

 

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Open a .jsl file with JSL, but the open function returns nothing

[ Edit: I thought I saw this issue for Journal files, but now I am seeing a return value ]

There does seem to be some inconsistency in the return values from Open().  I don't think this behavior has changed, but I see the same thing that you describe for both .jrp (JMP Report) and .jrn (JMP Journal) files.  While the initial Open() does not return the result, if you call Open() a second time, it will return the top-most box in the already open window:

Show(Open(".\abc.jrp"));
Show(Open(".\abc.jrp"));

Result:

Open(".\abc.jrp") = ␀;
Open(".\abc.jrp") = DisplayBox[HeadBox];

 

View solution in original post

10 REPLIES 10

Re: Open a .jsl file with JSL, but the open function returns nothing

We might need more information to address your question. Are you able to open the .jrp file via the GUI with no problems?

txnelson
Super User

Re: Open a .jsl file with JSL, but the open function returns nothing

@Setsuna , a .jrp file is actually just a special type of .jsl file.  Therefore, you can change the extension from .jrp to jsl and then open the file in JMP an it will open using the Script Editor.  That may also help you understand what a possible problem may be with the file.

Jim
Setsuna
Level II

Re: Open a .jsl file with JSL, but the open function returns nothing

@txnelson I tried to change the ext to jsl, and it runs well, and no log or error occured.

By the way, with the code above, I'm able to open the .jrp report normally, the only problem is the Open() function returns nothing.

Sorry that I didn't make it clear in the original post

hogi
Level XII

Re: Open a .jsl file with JSL, but the open function returns nothing

wow, cool!

Definitely worth to dig deeper and lean from the jsl code!

Setsuna
Level II

Re: Open a .jsl file with JSL, but the open function returns nothing

Yes, with the script above, I can see the report opened normally. The only problem is that the Open function returns nothing.
txnelson
Super User

Re: Open a .jsl file with JSL, but the open function returns nothing

Can you share the .jrp file with the community?

Jim
Setsuna
Level II

Re: Open a .jsl file with JSL, but the open function returns nothing

Thanks for your help. I uploaded a very simple jrp with the jsl code together. For me the problem is the same.

Re: Open a .jsl file with JSL, but the open function returns nothing

[ Edit: I thought I saw this issue for Journal files, but now I am seeing a return value ]

There does seem to be some inconsistency in the return values from Open().  I don't think this behavior has changed, but I see the same thing that you describe for both .jrp (JMP Report) and .jrn (JMP Journal) files.  While the initial Open() does not return the result, if you call Open() a second time, it will return the top-most box in the already open window:

Show(Open(".\abc.jrp"));
Show(Open(".\abc.jrp"));

Result:

Open(".\abc.jrp") = ␀;
Open(".\abc.jrp") = DisplayBox[HeadBox];

 

Setsuna
Level II

Re: Open a .jsl file with JSL, but the open function returns nothing

Thanks very much. 

I'm nearly sure that 2 weeks ago, I can get an object with only one Open() function, when I open a .jrp file.

So I guess what you saw with the .jrn files are probably ture