<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to ask title or other text to Journal in Dialog? in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-to-ask-title-or-other-text-to-Journal-in-Dialog/m-p/35707#M21069</link>
    <description>&lt;P&gt;Try 'Help &amp;gt; Scripting Index' and seraching for 'Column Dialog'. I added 'Edit Text()' to the example given to get the code below.&lt;/P&gt;
&lt;PRE&gt;Names Default To Here( 1 );
Open( "$SAMPLE_DATA/Consumer Preferences.jmp" );
Column Dialog(
	ex y = ColList( "Y",
		Min Col( 1 ),
		Max Col( 2 ),
		Data Type( "Numeric" )
	),
	ex x = ColList( "X",
		Max Col( 1 ),
		Modeling Type( {"Continuous", "Multiple Response"} )
	),
	Line Up( 2,
		Text Box( "Alpha" ), ex = EditNumber( .05 ),
		Text Box( "Beta" ), ey = EditText( "xyz" )
	),
	HList( cb = Check Box( "check", 1 ) ),
	HList( combo = Combo Box( "option1", "option2" ) ),
	HList( rb = RadioButtons( "a", "b" ) ),
	HList( et = EditText( "Edit Me" ) )
);&lt;/PRE&gt;</description>
    <pubDate>Mon, 13 Feb 2017 11:16:06 GMT</pubDate>
    <dc:creator>ian_jmp</dc:creator>
    <dc:date>2017-02-13T11:16:06Z</dc:date>
    <item>
      <title>How to ask title or other text to Journal in Dialog?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-ask-title-or-other-text-to-Journal-in-Dialog/m-p/35706#M21068</link>
      <description>&lt;P&gt;I have been doing a script that asks from user which two columns from original data will be chosen for Journal. I have manage to do that (see the code) but I want to add also&amp;nbsp;item for input dialog where you could put any text that will appear later in the Journal (preferable before table). I do not know how to add "user can write text" option in dialog nor how to "print" that text later in Journal. I know that with&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;Current Journal () &amp;lt;&amp;lt; Append (TextEditBox("Change Me"));&lt;/PRE&gt;&lt;P&gt;you can add text to Journal but I want to ask the text with same time as "which two columns to choose" dialog.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can try this script with any data table but I also attached one very simple table with two columns.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;dt = Current Data Table();

If( Is Empty( dt ),
	dt = Open()
);

DraftTabl = Current Data Table() ;//&amp;lt;&amp;lt; Get Name;

col_name_list = dt &amp;lt;&amp;lt; get column names( string );
Show( col_name_list );

dialogA = Empty();
If( Contains( col_name_list, "A" ),
	dialogA = Column( "A" )
);
dialogB = Empty();
If( Contains( col_name_list, "B" ),
	dialogB = Column( "B" )
);

// Dialog to choose column roles, ...
dlg = Column Dialog(
	ACol = Col List( "A param",
		Min Col( 1 ),
		Max Col( 1 ),
		Columns( dialogA )
	),
	BCol = Col List( "B param",
		Min Col( 1 ),
		Max Col( 1 ),
		Columns( dialogB )
	)
);
// I want to add here item for input where you could put any text that will show later in Journal

Show( dlg["Button"] );
If( dlg["Button"] == -1,
	Throw()
);

Remove From( dlg );
Eval List( dlg );
ACol = ACol[1] &amp;lt;&amp;lt; get name;
BCol = BCol[1] &amp;lt;&amp;lt; get name;


DT = Data Table(DraftTabl) &amp;lt;&amp;lt;
	Subset(
		columns (	Column(ACol), 
					Column(BCol),
				),
		Output Table Name("Draft_table")
		)
;

Data Table("Draft_Table") &amp;lt;&amp;lt; Journal;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you in advance for any hint.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 13 Feb 2017 09:21:00 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-ask-title-or-other-text-to-Journal-in-Dialog/m-p/35706#M21068</guid>
      <dc:creator>sami_hokkanen</dc:creator>
      <dc:date>2017-02-13T09:21:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to ask title or other text to Journal in Dialog?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-ask-title-or-other-text-to-Journal-in-Dialog/m-p/35707#M21069</link>
      <description>&lt;P&gt;Try 'Help &amp;gt; Scripting Index' and seraching for 'Column Dialog'. I added 'Edit Text()' to the example given to get the code below.&lt;/P&gt;
&lt;PRE&gt;Names Default To Here( 1 );
Open( "$SAMPLE_DATA/Consumer Preferences.jmp" );
Column Dialog(
	ex y = ColList( "Y",
		Min Col( 1 ),
		Max Col( 2 ),
		Data Type( "Numeric" )
	),
	ex x = ColList( "X",
		Max Col( 1 ),
		Modeling Type( {"Continuous", "Multiple Response"} )
	),
	Line Up( 2,
		Text Box( "Alpha" ), ex = EditNumber( .05 ),
		Text Box( "Beta" ), ey = EditText( "xyz" )
	),
	HList( cb = Check Box( "check", 1 ) ),
	HList( combo = Combo Box( "option1", "option2" ) ),
	HList( rb = RadioButtons( "a", "b" ) ),
	HList( et = EditText( "Edit Me" ) )
);&lt;/PRE&gt;</description>
      <pubDate>Mon, 13 Feb 2017 11:16:06 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-ask-title-or-other-text-to-Journal-in-Dialog/m-p/35707#M21069</guid>
      <dc:creator>ian_jmp</dc:creator>
      <dc:date>2017-02-13T11:16:06Z</dc:date>
    </item>
  </channel>
</rss>

