MikeTheMike 1 Posted September 20, 2015 Report Share Posted September 20, 2015 (edited) Hey all - Sorry for the basic request, but I've searched for the last hour or so and am struggling with something (I'm newish to ubot). I've got a csv file with a few rows & columns, such as: John smith, jsmith@blah.com, password123, homepage,alex jones, ajones@iuhdiuh.com, password321, homepage, What my goal is, is to make a UI dropdown from the first colum (names). I tried making a table (called &loaded) from the CSV (worked) and then making a list from that table, using 'list from table', to populate the dropdown... ui drop down("Select",$plugin function("TableCommands.dll", "$list from table", &loaded, "Column", 0),#name) This is where things go wrong! Instead of the dropdown having the names as two separate items like so: John smithalex jones It seems to see all the rows for column 1 as the same and puts them like this in the dropdown: 'John smith alex jones' ... As one option. I've search for help quite a bit, but keep just finding people trying to auto-reload the dropdown (a stage more advanced than what I'm trying to do!). Any help with just populating dropdown items from the first column of a CSV, with a single option for each row? < Is making a table from the CSV, then using a 'list from table' command the right way to do it? Thanks in advance! Edited September 20, 2015 by MikeTheMike Quote Link to post Share on other sites
pash 504 Posted September 20, 2015 Report Share Posted September 20, 2015 try. ui drop down("Select",$replace($replace regular expression("John smith, jsmith@blah.com, password123, homepage, alex jones, ajones@iuhdiuh.com, password321, homepage,",",.*",""),$new line,","),#Select) Quote Link to post Share on other sites
pash 504 Posted September 20, 2015 Report Share Posted September 20, 2015 and from you code ui drop down("Select",$replace($plugin function("TableCommands.dll", "$list from table", &loaded, "Column", 0),$new line,","),#name) 1 Quote Link to post Share on other sites
MikeTheMike 1 Posted September 20, 2015 Author Report Share Posted September 20, 2015 Heyyyyyy A MASSIVE thanks! The code below works perfectly! You're an absolute star and from you code ui drop down("Select",$replace($plugin function("TableCommands.dll", "$list from table", &loaded, "Column", 0),$new line,","),#name) Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.