cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Browse apps to extend the software in the new JMP Marketplace
%3CLINGO-SUB%20id%3D%22lingo-sub-801318%22%20slang%3D%22en-US%22%20mode%3D%22UPDATE%22%3E%E9%98%B2%E6%AD%A2%E6%96%B0%E8%A6%96%E7%AA%97%E6%9C%80%E5%A4%A7%E5%8C%96%2F%E8%AA%BF%E6%95%B4%E5%A4%A7%E5%B0%8F%EF%BC%9F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-801318%22%20slang%3D%22en-US%22%20mode%3D%22UPDATE%22%3E%3CP%3E%3CSPAN%3E%E4%BD%A0%E5%A5%BD%EF%BC%8C%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%20%3C%2FP%3E%3CP%3E%3CSPAN%3E%E6%88%91%E6%83%B3%E9%98%B2%E6%AD%A2%E6%96%B0%E8%A6%96%E7%AA%97%E6%9C%80%E5%A4%A7%E5%8C%96%2F%E8%AA%BF%E6%95%B4%E5%A4%A7%E5%B0%8F%E3%80%82%E6%88%91%E7%9F%A5%E9%81%93%E2%80%9C%20%3CSTRONG%3E%26lt%3B%26lt%3B%20%3CEM%3EModal%3C%2FEM%3E%3C%2FSTRONG%3E%20%E2%80%9D%E7%AA%97%E5%8F%A3%EF%BC%8C%E4%BD%86%E6%98%AF%E6%9C%89%E5%85%B6%E4%BB%96%E6%96%B9%E6%B3%95%E5%97%8E%EF%BC%9F%3CBR%20%2F%3E%3CBR%20%2F%3E%E7%99%BC%E7%8F%BE%E4%BA%86%E9%80%99%E5%80%8B%E5%A8%81%E8%84%85%EF%BC%8C%E4%BD%86%E5%AE%83%E5%9C%A8%E5%BE%8C%E5%8F%B0%E9%81%8B%E8%A1%8C%E4%B8%80%E5%80%8B%E6%88%91%E4%B8%8D%E5%96%9C%E6%AD%A1%E7%9A%84%E8%AA%BF%E5%BA%A6%E7%A8%8B%E5%BA%8F%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fcommunity.jmp.com%2Ft5%2FDiscussions%2FHow-to-stop-users-from-resizing-windows-in-JSL%2Ftd-p%2F15168%22%20target%3D%22_blank%22%3Ehttps%3A%2F%2Fcommunity.jmp.com%2Ft5%2FDiscussions%2FHow-to-stop-users-from-resizing-windows-in-JSL%2Ftd-p%2F15168%3C%2FA%3E%3CBR%20%2F%3E%3CBR%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22Jackie__0-1727098266586.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22Jackie__0-1727098266586.png%22%20style%3D%22width%3A%20198px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22Jackie__0-1727098266586.png%22%20style%3D%22width%3A%20198px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22Jackie__0-1727098266586.png%22%20style%3D%22width%3A%20198px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22Jackie__0-1727098266586.png%22%20style%3D%22width%3A%20198px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22Jackie__0-1727098266586.png%22%20style%3D%22width%3A%20198px%3B%22%3E%3Cspan%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22Jackie__0-1727098266586.png%22%20style%3D%22width%3A%20198px%3B%22%3E%3Cimg%20src%3D%22https%3A%2F%2Fcommunity.jmp.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F68534i81DADF8B3EAD97DF%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22Jackie__0-1727098266586.png%22%20alt%3D%22Jackie__0-1727098266586.png%22%20%2F%3E%3C%2Fspan%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%20%3C%2FP%3E%3CP%3E%3CSPAN%3E%20%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-801318%22%20slang%3D%22en-US%22%20mode%3D%22UPDATE%22%3E%3CLINGO-LABEL%3E%E8%87%AA%E5%8B%95%E5%8C%96%E5%92%8C%E8%85%B3%E6%9C%AC%E7%B7%A8%E5%AF%AB%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-801339%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%E5%9B%9E%E8%A6%86%EF%BC%9A%E9%98%B2%E6%AD%A2%E6%96%B0%E8%A6%96%E7%AA%97%E6%9C%80%E5%A4%A7%E5%8C%96%2F%E8%AA%BF%E6%95%B4%E5%A4%A7%E5%B0%8F%EF%BC%9F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-801339%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3E%E5%9C%A8%E8%85%B3%E6%9C%AC%E7%B4%A2%E5%BC%95%E4%B8%AD%E5%B0%8B%E6%89%BE%E8%A6%96%E7%AA%97%E5%A4%A7%E5%B0%8F%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22%20language-jsl%22%3Ew%20%3D%20new%20window(%22test%22)%3B%0Aw%20%26lt%3B%26lt%3B%20Set%20Window%20Size(%20800%2C%201200%20)%3B%3C%2FCODE%3E%3C%2FPRE%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-801341%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%E5%9B%9E%E8%A6%86%EF%BC%9A%E9%98%B2%E6%AD%A2%E6%96%B0%E8%A6%96%E7%AA%97%E6%9C%80%E5%A4%A7%E5%8C%96%2F%E8%AA%BF%E6%95%B4%E5%A4%A7%E5%B0%8F%EF%BC%9F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-801341%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3E%E6%93%9A%E6%88%91%E6%89%80%E7%9F%A5%EF%BC%8C%E4%BD%A0%E5%BE%88%E9%9B%A3%E5%81%9A%E5%88%B0%E9%80%99%E4%B8%80%E9%BB%9E%EF%BC%8C%E4%BD%86%E6%9C%89%E5%B9%BE%E5%80%8B%E5%95%8F%E9%A1%8C%EF%BC%9A%3C%2FP%3E%0A%3COL%3E%0A%3CLI%3E%E6%9C%80%E9%87%8D%E8%A6%81%E7%9A%84%E5%95%8F%E9%A1%8C%EF%BC%9A%E7%82%BA%E4%BB%80%E9%BA%BC%E8%A6%81%E9%98%BB%E6%AD%A2%E4%BD%BF%E7%94%A8%E8%80%85%E8%AA%BF%E6%95%B4%E8%A6%96%E7%AA%97%E5%A4%A7%E5%B0%8F%EF%BC%88%E4%B8%8D%E5%A4%AA%E7%AC%A6%E5%90%88%20JMP%20%E7%84%A1%E6%B3%95%E8%AA%BF%E6%95%B4%E8%A6%96%E7%AA%97%E5%A4%A7%E5%B0%8F%E7%9A%84%E6%84%9F%E8%A6%BA%EF%BC%89%E3%80%82%3CBR%20%2F%3E%3COL%3E%3CLI%3E%20JMP%20%E4%B8%AD%E7%9A%84%E4%B8%80%E5%80%8B%E8%A6%96%E7%AA%97%E9%98%BB%E6%AD%A2%E6%82%A8%E6%9C%80%E5%A4%A7%E5%8C%96%E5%AE%83%EF%BC%8C%E5%AE%83%E6%98%AF%E5%9C%96%E4%BE%8B%E7%AA%97%E5%8F%A3%EF%BC%8C%E4%BD%86%E6%82%A8%E4%BB%8D%E7%84%B6%E5%8F%AF%E4%BB%A5%E8%AA%BF%E6%95%B4%E5%AE%83%E7%9A%84%E5%A4%A7%E5%B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%0A%3C%2FOL%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-801345%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%E5%9B%9E%E8%A6%86%EF%BC%9A%E9%98%B2%E6%AD%A2%E6%96%B0%E8%A6%96%E7%AA%97%E6%9C%80%E5%A4%A7%E5%8C%96%2F%E8%AA%BF%E6%95%B4%E5%A4%A7%E5%B0%8F%EF%BC%9F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-801345%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fcommunity.jmp.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F14366%22%20target%3D%22_blank%22%3E%40jthi%3C%2FA%3E%20%3C%2FP%3E%3COL%3E%3CLI%3EJMP%20%E4%B8%AD%E7%9A%84%E4%B8%80%E5%80%8B%E7%AA%97%E5%8F%A3%E9%98%BB%E6%AD%A2%E6%82%A8%E6%9C%80%E5%A4%A7%E5%8C%96%E5%AE%83%EF%BC%8C%E5%AE%83%E6%98%AF%E5%9C%96%E4%BE%8B%E7%AA%97%E5%8F%A3%EF%BC%8C%E4%BD%86%E6%82%A8%E4%BB%8D%E7%84%B6%E5%8F%AF%E4%BB%A5%E8%AA%BF%E6%95%B4%E5%AE%83%E7%9A%84%E5%A4%A7%E5%B0%8F%EF%BC%8C%E5%9B%A0%E6%AD%A4%E4%B9%9F%E8%A8%B1%E6%9C%89%E4%B8%80%E7%A8%AE%E6%96%B9%E6%B3%95%E5%8F%AF%E4%BB%A5%E7%A6%81%E7%94%A8%E6%9C%80%E5%A4%A7%E5%8C%96%20-%3CSTRONG%3E%E6%88%91%E5%BE%9E%E6%9C%AA%E9%81%87%E5%88%B0%E9%81%8E%E9%80%99%E7%A8%AE%E6%83%85%E6%B3%81%EF%BC%8C%E6%82%A8%E5%8F%AF%E4%BB%A5%E5%88%86%E4%BA%AB%E7%A4%BA%E4%BE%8B%E4%BB%A3%E7%A2%BC%E5%97%8E%EF%BC%9F%3C%2FSTRONG%3E%3C%2FLI%3E%3C%2FOL%3E%3COL%3E%3CLI%3E%E5%A6%82%E6%9E%9C%E6%82%A8%E5%B8%8C%E6%9C%9B%E9%98%B2%E6%AD%A2%E8%AA%BF%E6%95%B4%E5%A4%A7%E5%B0%8F%EF%BC%8C%E7%82%BA%E4%BB%80%E9%BA%BC%E4%B8%8D%E4%BD%BF%E7%94%A8%E6%A8%A1%E5%BC%8F%E8%A6%96%E7%AA%97%E5%91%A2%EF%BC%9F%20-%20%3CSTRONG%3EBcos%20%E6%A8%A1%E6%85%8B%E8%A6%96%E7%AA%97%E9%98%BB%E6%AD%A2%E5%AD%98%E5%8F%96%E5%85%B6%E4%BB%96%E6%AA%94%E6%A1%88%2F%E8%A1%A8%3C%2FSTRONG%3E%3C%2FLI%3E%3CLI%3E%E4%BD%BF%E7%94%A8%E8%AA%BF%E5%BA%A6%E7%A8%8B%E5%BC%8F%E6%9C%89%E4%BB%80%E9%BA%BC%E5%85%B7%E9%AB%94%E5%95%8F%E9%A1%8C%E5%97%8E%EF%BC%9F%3CSTRONG%3E%E5%95%8F%E9%A1%8C%E6%98%AF%E5%AE%83%E6%B8%9B%E6%85%A2%E4%BA%86%E5%BE%AA%E7%92%B0%E9%80%9F%E5%BA%A6%3C%2FSTRONG%3E%3C%2FLI%3E%3C%2FOL%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-801347%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%E5%9B%9E%E8%A6%86%EF%BC%9A%E9%98%B2%E6%AD%A2%E6%96%B0%E8%A6%96%E7%AA%97%E6%9C%80%E5%A4%A7%E5%8C%96%2F%E8%AA%BF%E6%95%B4%E5%A4%A7%E5%B0%8F%EF%BC%9F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-801347%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3E%E4%B8%8D%E7%9F%A5%E9%81%93%E5%A6%82%E4%BD%95%E5%81%9A%E5%88%B0%E9%80%99%E4%B8%80%E9%BB%9E%E3%80%82%3C%2FP%3E%0A%3CP%3E%20%3C%2FP%3E%0A%3CP%3E%E4%BD%86%E5%A6%82%E6%9E%9C%E6%82%A8%E5%B8%8C%E6%9C%9B%E6%8F%90%E4%BE%9B%E9%9D%9E%E5%B8%B8%E7%85%A9%E4%BA%BA%E7%9A%84%E7%94%A8%E6%88%B6%E9%AB%94%E9%A9%97%EF%BC%8C%E6%82%A8%E5%8F%AF%E4%BB%A5%E4%BD%BF%E7%94%A8%E5%9C%96%E5%BD%A2%E8%85%B3%E6%9C%AC%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22%20language-jsl%22%3ENames%20Default%20To%20Here(1)%3B%0A%0Anw%20%3D%20New%20Window(%22Example%22%2C%20%26lt%3B%3CSIZE%3E%3C%2FSIZE%3E%3C%2FCODE%3E%3C%2FPRE%3E%3CCODE%20class%3D%22%20language-jsl%22%3E%0A%3CP%3E%20%3C%2FP%3E%3C%2FCODE%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-801350%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%E5%9B%9E%E8%A6%86%EF%BC%9A%E9%98%B2%E6%AD%A2%E6%96%B0%E8%A6%96%E7%AA%97%E6%9C%80%E5%A4%A7%E5%8C%96%2F%E8%AA%BF%E6%95%B4%E5%A4%A7%E5%B0%8F%EF%BC%9F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-801350%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3E%E9%80%99%E6%98%AF%E4%B8%80%E5%80%8B%E5%BE%88%E5%A5%BD%E7%9A%84%E6%8A%80%E5%B7%A7%E3%80%82%E8%AC%9D%E8%AC%9D%E8%B3%88%E8%8E%AB%3C%2FP%3E%3C%2FLINGO-BODY%3E
Choose Language Hide Translation Bar
Jackie_
Level VI

Preventing New Window from being maximized/resized?

Hello,

 

I want to prevent the new window from being maximized/resized. I am aware of the "<<Modal" window, but is there an alternate way? 

Found this threat but it runs a scheduler in the background which I don't prefer

https://community.jmp.com/t5/Discussions/How-to-stop-users-from-resizing-windows-in-JSL/td-p/15168

Jackie__0-1727098266586.png

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
jthi
Super User

Re: Preventing New Window from being maximized/resized?

No idea how that could be done.

 

But if you wish to provide very annoying user experience you can use graphic scripts

Names Default To Here(1);

nw = New Window("Example", <<size(200, 200),
	gb = Graph Box(
		Frame Size(1, 1)
	),
	box = V Splitter Box(
		Size(640, 480),
		H Splitter Box(
			Spacer Box(
				<<Set Fill(1);
				<<Color(RGB Color(9, 112, 84));
			),
			Spacer Box(
				<<Set Fill(1);
				<<Color(RGB Color(255, 222, 0));
			)
		),
		H Splitter Box(
			Spacer Box(
				<<Set Fill(1);
				<<Color(RGB Color(101, 153, 255));
			),
			Spacer Box(
				<<Set Fill(1);
				<<Color(RGB Color(255, 153, 0));
			)
		)
	)
);

(gb << Xpath("//AxisBox")) << visibility("Collapse");

Eval(EvalExpr(
	gb[FrameBox(1)] << Add Graphics Script(
		Expr(nw) << Zoom Window;
	);	
));

 

-Jarmo

View solution in original post

5 REPLIES 5
txnelson
Super User

Re: Preventing New Window from being maximized/resized?

Look in the Scripting Index for Window Size

w = new window("test");
w << Set Window Size( 800, 1200 );
Jim
jthi
Super User

Re: Preventing New Window from being maximized/resized?

To my knowledge you cannot easily do this, but few questions:

  1. The most important question: why would you want to prevent user from resizing a window (doesn't really fit the feeling of JMP to not be able to resize a window).
    1. One window in JMP which prevents you from maximizing it and it is Legend window but you can still resize it so maybe there is a way to disable maximizing
    2. Other is Caption() but it is it's own thing
  2. If you wish to prevent resizing, why not use modal window?
  3. Is there a specific issue in using scheduler?
  4. That thread has the most probable answer: you might have to go outside the scripting language and do it from the operating system
-Jarmo
Jackie_
Level VI

Re: Preventing New Window from being maximized/resized?

@jthi 

  1. One window in JMP which prevents you from maximizing it and it is Legend window but you can still resize it so maybe there is a way to disable maximizing - I have never came across this, can you share an example code?
  1. If you wish to prevent resizing, why not use a modal window? - Bcos Modal window prevents accessing other files/tables 
  2. Is there a specific issue in using scheduler? The issue is it slows down the loop
jthi
Super User

Re: Preventing New Window from being maximized/resized?

No idea how that could be done.

 

But if you wish to provide very annoying user experience you can use graphic scripts

Names Default To Here(1);

nw = New Window("Example", <<size(200, 200),
	gb = Graph Box(
		Frame Size(1, 1)
	),
	box = V Splitter Box(
		Size(640, 480),
		H Splitter Box(
			Spacer Box(
				<<Set Fill(1);
				<<Color(RGB Color(9, 112, 84));
			),
			Spacer Box(
				<<Set Fill(1);
				<<Color(RGB Color(255, 222, 0));
			)
		),
		H Splitter Box(
			Spacer Box(
				<<Set Fill(1);
				<<Color(RGB Color(101, 153, 255));
			),
			Spacer Box(
				<<Set Fill(1);
				<<Color(RGB Color(255, 153, 0));
			)
		)
	)
);

(gb << Xpath("//AxisBox")) << visibility("Collapse");

Eval(EvalExpr(
	gb[FrameBox(1)] << Add Graphics Script(
		Expr(nw) << Zoom Window;
	);	
));

 

-Jarmo
Jackie_
Level VI

Re: Preventing New Window from being maximized/resized?

This is a nice hack. Thanks Jarmo