big dog status 2 Posted November 7, 2013 Report Share Posted November 7, 2013 (edited) Hi, I've been trying different things for a few hours now and am resorting to going to forums. Can someone please tell me how one populates ALL rows of a table but only on, let' say, column 6 of each row, in a ui drop down? Any help would be greatly appreciated as I stumped. Thanks in advance. Edited November 7, 2013 by big dog status Quote Link to post Share on other sites
the_way 52 Posted November 7, 2013 Report Share Posted November 7, 2013 can you explain a bit more with an example? are you saying that you have a drop down menu with multiple choices, and depending on what is selected from the menu, a table gets updated but has to be in column 6? cheers Quote Link to post Share on other sites
big dog status 2 Posted November 7, 2013 Author Report Share Posted November 7, 2013 sure, sorry about that. I have a fb bot that works using data from a csv file. I want to make it possible to select any account I want from a UI drop down menu. The purpose would be to easily be able to switch between accounts when working instead of going and manually editing my .csv file every time. For example, right now my bot loops through all of the accounts in my .csv, but if I want to say, run account #10 first, (to do some maintenance or hand editing) I am forced to go to my .csv and rearrange my accounts to place the account I need to work on in the first place. Anyways, long story short I just need to be able to add column 0 from every row (in my table) to a ui drop down menu. Thanks for your response. Quote Link to post Share on other sites
LazyBotter 188 Posted November 7, 2013 Report Share Posted November 7, 2013 What version of UBot Studio are you using? Quote Link to post Share on other sites
Pete 121 Posted November 7, 2013 Report Share Posted November 7, 2013 This is the old way we have hacked it in the passed on load("Tab Loaded") { comment("Edit the file path") set(#mydropdown, $read file(#FilePath), "Global") set(#mydropdown, "<option>{$replace(#mydropdown, "", "</option><option>")}</option>", "Global")}ui html panel("<div><select variable=\"#value\" fillwith=\"value\" style=\"\"><optgroup variable=\"#mydropdown\" fillwith=\"innerhtml\"></optgroup></select></div>", 100) Quote Link to post Share on other sites
LazyBotter 188 Posted November 7, 2013 Report Share Posted November 7, 2013 If you have dev you can do it this way, ui html panel("<!DOCTYPE html> <html lang=\"en\"> <head> <meta charset=\"utf-8\"> <meta name=\"generator\" content=\"CoffeeCup HTML Editor (www.coffeecup.com)\"> <meta name=\"dcterms.created\" content=\"Thu, 07 Nov 2013 17:47:04 GMT\"> <meta name=\"description\" content=\"\"> <meta name=\"keywords\" content=\"\"> <title></title> <!--[if IE]> <script src=\"http://html5shim.googlecode.com/svn/trunk/html5.js\"></script> <![endif]--> </head> <body> <input type=\"file\" dialogtype=\"open\" variable=\"#CSV\" fillwith=\"value\"> <select list=\"#UI_Table_Rows\" list-fillwith=\"options\" variable=\"#UI_Table_Row_Selection\"></select> </body> </html>", 200) create table from file(#CSV, &Table) set(#Row, 0, "Global") loop($table total rows(&Table)) { set(#UI_Table_Rows, "{#UI_Table_Rows}{$table cell(&Table, #Row, 0)},", "Global") increment(#Row) } Carl 1 Quote Link to post Share on other sites
big dog status 2 Posted November 8, 2013 Author Report Share Posted November 8, 2013 Hmm don't have developer edition but may be a good time to upgrade, I'm going to try what you guys suggested now. Thanks for your help :-) Quote Link to post Share on other sites
big dog status 2 Posted November 8, 2013 Author Report Share Posted November 8, 2013 (edited) Very cool example Carl, as a designer for nearly two decades I think it would be fun to make my bots look more unique. Edited November 8, 2013 by big dog status 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.