Choose Language Hide Translation Bar
Highlighted
LeeP
Level III

Prevent Objects From Displaying When Running Scripts

I'm trying to automate my JMP chart creation. I'm creating an application.As the script runs it displays the output of the query and the report. It then saves the report as an HTML document. The full script has 4 different queries and reports. Is there a way to run the script where it doesn't display anything? I plan on having the application show a pop-up saying the report is running, but don't want the actual artifacts displaying. Attached is a sample script.

 

planetQ = New SQL Query(
	Connection(
		"CONNECTION INFO HERE"
	),
	QueryName( "ON_TIME_SPC_PLANET" ),
	Select(
		Column( "ReleaseMonth", "t1", Numeric Format( "m/d/y", "-1", "NO", "" ) ),
		Column( "PLANET", "t1" ),
		Column(
			"On-Time",
			"t1",
			Alias( "Sum-On-Time" ),
			SavedJMPName( "On-Time" ),
			Aggregation( "Sum" ),
			JMP Name( "Sum-On-Time", 0 )
		),
		Column(
			"Total",
			"t1",
			Alias( "Sum-Total" ),
			SavedJMPName( "Total" ),
			Aggregation( "Sum" ),
			JMP Name( "Sum-Total", 0 )
		),
		Column( "Phase", "t1", Analysis Type( "Nominal" ) )
	),
	From( Table( "ON_TIME_SPC", Schema( "dbo" ), Alias( "t1" ) ) ),
	Group By(
		Column( "ReleaseMonth", "t1", Numeric Format( "m/d/y", "-1", "NO", "" ) ),
		Column( "PLANET", "t1" ),
		Column( "Phase", "t1" )
	),
	Order By(
		Column(
			"ReleaseMonth",
			"t1",
			Numeric Format( "m/d/y", "-1", "NO", "" ),
			Order( "Ascending" )
		)
	)
) << Run Foreground();

planetQ << New Column( "OnTimePct",
	Formula( :Name( "Sum-On-Time" ) / :Name( "Sum-Total" ))
);
wait(1.0);

current data table(planetQ);

planetP = Control Chart(
	Sample Label( :ReleaseMonth ),
	Phase( :Phase ),
	Sample Size( :Name( "Sum-Total" ) ),
	KSigma( 3 ),
	Chart Col( :OnTimePct, P( Phase Level( "1" ), Phase Level( "2" ) ) ),
	By( :PLANET )
);

 

3 ACCEPTED SOLUTIONS

Accepted Solutions
Highlighted
txnelson
Super User

Re: Prevent Objects From Displaying When Running Scripts

You should be able to specify to run your query in "Background".  Look in the Scripting Index under SQL Query for "Run Background".  And as for the Control Chart, you can always specify the "Invisible" option.

Jim

View solution in original post

Highlighted
txnelson
Super User

Re: Prevent Objects From Displaying When Running Scripts

ppnP = Control Chart(invisible,
Sample Label
( :ReleaseMonth ),
Phase
( :Phase ),
Sample Size
( :Name( "Sum-Total" ) ),
KSigma
( 3 ),
Chart Col
( :OnTimePct, P( Phase Level( "1" ), Phase Level( "2" ) ) ),
By
( :name )
);

 

Jim

View solution in original post

Highlighted
Jeff_Perkinson
Community Manager Community Manager

Re: Prevent Objects From Displaying When Running Scripts

5 REPLIES 5
Highlighted
txnelson
Super User

Re: Prevent Objects From Displaying When Running Scripts

You should be able to specify to run your query in "Background".  Look in the Scripting Index under SQL Query for "Run Background".  And as for the Control Chart, you can always specify the "Invisible" option.

Jim

View solution in original post

Highlighted
LeeP
Level III

Re: Prevent Objects From Displaying When Running Scripts

Thanks for the response. I was able to hide the tables by using the "private" option (since I didn't want to have to close them when done) I am not seeing where I would use the invisible option when generating the chart:

 

ppnP = Control Chart(
	Sample Label( :ReleaseMonth ),
	Phase( :Phase ),
	Sample Size( :Name( "Sum-Total" ) ),
	KSigma( 3 ),
	Chart Col( :OnTimePct, P( Phase Level( "1" ), Phase Level( "2" ) ) ),
	By( :name )
);
Highlighted
txnelson
Super User

Re: Prevent Objects From Displaying When Running Scripts

ppnP = Control Chart(invisible,
Sample Label
( :ReleaseMonth ),
Phase
( :Phase ),
Sample Size
( :Name( "Sum-Total" ) ),
KSigma
( 3 ),
Chart Col
( :OnTimePct, P( Phase Level( "1" ), Phase Level( "2" ) ) ),
By
( :name )
);

 

Jim

View solution in original post

Highlighted
Jeff_Perkinson
Community Manager Community Manager

Re: Prevent Objects From Displaying When Running Scripts

Highlighted
LeeP
Level III

Re: Prevent Objects From Displaying When Running Scripts

Thanks for the quick response. Works perfectly.
Article Labels

    There are no labels assigned to this post.