cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Browse apps to extend the software in the new JMP Marketplace
Choose Language Hide Translation Bar
KST-CPT
Level II

User input dates

I have a column of date time in a table.  When I run my script I want a dialog box to come up (calendar selection would make selection easier), which asks for a start date and end date.  They can be seperate dialog boxes, or they can be the same, either would suffice.  I want to store these dates in variables so that I can "select where" to create a subset within or around these dates.

 

I have tried numerous approaches, the one I like best:

startDate = new window("Start Date of Data",<<Modal, numbereditbox(today(),20,<<setformat(Format("m/d/y", 12)),Button Box( "OK", StartDateRT << get ), Button Box( "Cancel" )));

Show(StartDateRT);
show(StartDate);

 

gives me this result in the Log:

StartDateRT = DisplayBox[];
StartDate = {Button(1)};

 

How do I get the selected date so that I can use it later?

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
txnelson
Super User

Re: User input dates

Use a Calendar Box().  Go to 

     Help==>Scripting Index==>Calendar Box()

for details.

Here is the JSL example from the Help entry

Names Default To Here( 1 );
New Window( "Calendar Box Example", Calendar Box() );

calendar.PNG

Jim

View solution in original post

1 REPLY 1
txnelson
Super User

Re: User input dates

Use a Calendar Box().  Go to 

     Help==>Scripting Index==>Calendar Box()

for details.

Here is the JSL example from the Help entry

Names Default To Here( 1 );
New Window( "Calendar Box Example", Calendar Box() );

calendar.PNG

Jim