cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Learn how to build custom Python data connectors and further customize JMP’s Data Connector Framework with the Python Data Connector Demo, available now in the JMP Marketplace!
  • See how to move from signal modeling to system modeling at the first JMP Aerospace Analytics webinar. Register. June 18, 1 p.m. US Eastern Time.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar

Custom Busy Light( )?

Hello jmp community,

 

First of all, let me wish you a great new year!

 

I am currently working on a project and want to use something similar to busy light() function but with a custom animated gif.

The only way I find to animated a gif in a New Window() is to use this block of jsl  by incrementing the gif frame by frame.

 

spinner = New Image( gifpath || "\spinner.gif" );
nbFrame = spinner << Get N Frames();

[...]

For( i = 0, i < nbFrame, i++, spinner << Set Current Frame( i ); nwStatus << reshow(); wait(3/100); if(i == nbFrame, i = 0;); );

Is there another way to do it? Because this does not work independently of the main calculation script.

Is there a way to custom the busy light()?

 

Thanks

Regards,

Guillaume

 

Guillaume
1 ACCEPTED SOLUTION

Accepted Solutions

Re: Custom Busy Light( )?

Hello @guillaumebugnon ,

I think another possible way to show an animated gif in a new window, you can use Web Browser Box() function.
Here is a sample script to do this. In this script, you need to create html file, which is embedded gif animation.

nw = New Window( "Example",
	<<Show Menu( 0 ),
	<<show toolbars( 0 ),
	V List Box( Text Box( "Please Wait!" ), Spacer Box( size( 20, 20 ) ), wb = Web Browser Box() )
);
wb << Navigate( "file:///C:/xxxx/xxxx/test.html" );
nw << Set Window Size( 200, 200 );

//test
Wait( 5 );
nw << close window();

Here is an example of an html file.

<!doctype html>
<html>
  <body>
    <div style="text-align: center">
      <img src="./spinner.gif"  width="50" />
    </div>
  </body>
</html>

View solution in original post

3 REPLIES 3

Re: Custom Busy Light( )?

Hello @guillaumebugnon ,

I think another possible way to show an animated gif in a new window, you can use Web Browser Box() function.
Here is a sample script to do this. In this script, you need to create html file, which is embedded gif animation.

nw = New Window( "Example",
	<<Show Menu( 0 ),
	<<show toolbars( 0 ),
	V List Box( Text Box( "Please Wait!" ), Spacer Box( size( 20, 20 ) ), wb = Web Browser Box() )
);
wb << Navigate( "file:///C:/xxxx/xxxx/test.html" );
nw << Set Window Size( 200, 200 );

//test
Wait( 5 );
nw << close window();

Here is an example of an html file.

<!doctype html>
<html>
  <body>
    <div style="text-align: center">
      <img src="./spinner.gif"  width="50" />
    </div>
  </body>
</html>

Re: Custom Busy Light( )?

Hello @yuichi_katsumur,

That's a very good idea. I'll try that, it should work.

Guillaume

Re: Custom Busy Light( )?

It works !!

Thanks a lot @yuichi_katsumur 

 

Animation.gif

Guillaume

Recommended Articles