<?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 Populate  List Box with list of Strings in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Populate-List-Box-with-list-of-Strings/m-p/276808#M53757</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I would like to give the user the opportunity of choosing a Tag name, which will then show a time series plot of various variables based on that tag name.&lt;/P&gt;&lt;P&gt;I have created this script to create a list of the TAG names, and will then use that selection (onchange) to populate the variables in a graph builder script.&lt;/P&gt;&lt;P&gt;However, this is creating an empty list box. Can anyone identify why?&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
dt = Current Data Table();
ET_LIST = {};
ET_TAG_List = {};

//removes empty column from the column list
For( i = N Col( dt ), i &amp;gt;= 1, i--,
	ET_col = Column( dt, i ) &amp;lt;&amp;lt; Get Name();
	If( (Col N Missing( Column( i ) ) / N Row()) != 1 &amp;amp; Contains( ET_col, "ETarg" ),
		Insert Into( ET_LIST, ET_col )
	);
);

Show( ET_LIST );
//takes column list and removes the TAG extension to provide the list of tags
n = N Items( ET_LIST );
For( i = 1, i &amp;lt;= n, i++,
	ETARG = ET_LIST[i] ;
	NFull = Length(ETARG) ; 
	ETTAG = Left(ETARG,(NFull-6)) ;
Insert Into(ET_TAG_List, ETTAG);

);	
	Show(ET_TAG_List);
//want to now take that list and put it into a list box for user to select. will use getselected/onchange to update the charts
New Window( "Example",
	List1 = List Box( ET_TAG_List );
	List1 &amp;lt;&amp;lt; Set Items( ET_TAG_List );
);&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;empty input box..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="spudton_0-1593793813267.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/25036i63F1B1D68B63D8FE/image-size/medium?v=v2&amp;amp;px=400" role="button" title="spudton_0-1593793813267.png" alt="spudton_0-1593793813267.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sun, 11 Jun 2023 11:03:05 GMT</pubDate>
    <dc:creator>spudton</dc:creator>
    <dc:date>2023-06-11T11:03:05Z</dc:date>
    <item>
      <title>Populate  List Box with list of Strings</title>
      <link>https://community.jmp.com/t5/Discussions/Populate-List-Box-with-list-of-Strings/m-p/276808#M53757</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I would like to give the user the opportunity of choosing a Tag name, which will then show a time series plot of various variables based on that tag name.&lt;/P&gt;&lt;P&gt;I have created this script to create a list of the TAG names, and will then use that selection (onchange) to populate the variables in a graph builder script.&lt;/P&gt;&lt;P&gt;However, this is creating an empty list box. Can anyone identify why?&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
dt = Current Data Table();
ET_LIST = {};
ET_TAG_List = {};

//removes empty column from the column list
For( i = N Col( dt ), i &amp;gt;= 1, i--,
	ET_col = Column( dt, i ) &amp;lt;&amp;lt; Get Name();
	If( (Col N Missing( Column( i ) ) / N Row()) != 1 &amp;amp; Contains( ET_col, "ETarg" ),
		Insert Into( ET_LIST, ET_col )
	);
);

Show( ET_LIST );
//takes column list and removes the TAG extension to provide the list of tags
n = N Items( ET_LIST );
For( i = 1, i &amp;lt;= n, i++,
	ETARG = ET_LIST[i] ;
	NFull = Length(ETARG) ; 
	ETTAG = Left(ETARG,(NFull-6)) ;
Insert Into(ET_TAG_List, ETTAG);

);	
	Show(ET_TAG_List);
//want to now take that list and put it into a list box for user to select. will use getselected/onchange to update the charts
New Window( "Example",
	List1 = List Box( ET_TAG_List );
	List1 &amp;lt;&amp;lt; Set Items( ET_TAG_List );
);&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;empty input box..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="spudton_0-1593793813267.png" style="width: 400px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/25036i63F1B1D68B63D8FE/image-size/medium?v=v2&amp;amp;px=400" role="button" title="spudton_0-1593793813267.png" alt="spudton_0-1593793813267.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 11 Jun 2023 11:03:05 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Populate-List-Box-with-list-of-Strings/m-p/276808#M53757</guid>
      <dc:creator>spudton</dc:creator>
      <dc:date>2023-06-11T11:03:05Z</dc:date>
    </item>
    <item>
      <title>Re: Populate  List Box with list of Strings</title>
      <link>https://community.jmp.com/t5/Discussions/Populate-List-Box-with-list-of-Strings/m-p/276810#M53759</link>
      <description>&lt;P&gt;The ";" are stopping the processing, change to&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;New Window( "Example",
	List1 = List Box( ET_TAG_List ),
	List1 &amp;lt;&amp;lt; Set Items( ET_TAG_List )
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 03 Jul 2020 17:42:02 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Populate-List-Box-with-list-of-Strings/m-p/276810#M53759</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2020-07-03T17:42:02Z</dc:date>
    </item>
  </channel>
</rss>

