New Guy 4 Posted September 19, 2010 Report Share Posted September 19, 2010 Hello all, So here's the situation. I have a UI window, within that window there is about 20 check boxes that all apply to variables which determine if certain subs will be ran or not. What I am trying to do is add a "select all" check box within my UI window. Is there a way to accomplish this?? Thanks... Gary.. Quote Link to post Share on other sites
Praney Behl 314 Posted September 19, 2010 Report Share Posted September 19, 2010 Hey Gary, Use an if statement : if "select all" = "True";thenrun sub1run sub2..and so on or if "select all" = "True";thenSet all the varibles used for checkboxes to "True" Praney Quote Link to post Share on other sites
New Guy 4 Posted September 19, 2010 Author Report Share Posted September 19, 2010 Hi Praney, I thought of that but it still doesn't do what I am looking for it to do. Both of those solutions would would work but it's not exactly what I am looking for. What I would like is for all of the check boxes to actually be checked when the select all check box is checked. Both of those solutions technically work but I don't want to confuse the end user.. Quote Link to post Share on other sites
IRobot 43 Posted September 19, 2010 Report Share Posted September 19, 2010 Hi Gary, What I would like is for all of the check boxes to actually be checked when the select all check box is checked.I think this is a limitation of the current UI. You can get UI element's value's, but you cannot set them, so they display on the UI. Both of those solutions technically work but I don't want to confuse the end user..Yes, I agree. Checking the 'Select All' checkbox should check all other checkboxes. Maybe you could add this to the 'Enhancements' section. I think the new UI that Seth has suggested may be able to solve your problem:http://ubotstudio.com/forum/index.php?/topic/4894-a-perfect-solution-to-ui/ Quote Link to post Share on other sites
New Guy 4 Posted October 23, 2010 Author Report Share Posted October 23, 2010 Hey Praney, I was hoping the HTML UI would have been available by now but since it's not I am going to try to implement your strategy. One question though, how do I set the variables used for checkboxes to "True"? I don't see a way to really accomplish this. Or maybe I am just over thinking it right now.. Quote Link to post Share on other sites
zerofill 0 Posted October 23, 2010 Report Share Posted October 23, 2010 Hey Praney, I was hoping the HTML UI would have been available by now but since it's not I am going to try to implement your strategy. One question though, how do I set the variables used for checkboxes to "True"? I don't see a way to really accomplish this. Or maybe I am just over thinking it right now.. Unfortunately your going to probably just have to do an evaluate "if true" on the select all check box variable and then do everything under that that you would do if all the boxes where checked. It is a hard thing to get used to if you have a programming background always trying to make your code so it isn't so bloated. But because of the way you have to do it with this visual concept of coding... you find you have to bloat it right up lol. That is the only thing I can think of for you to do unless someone has a better idea. Quote Link to post Share on other sites
New Guy 4 Posted October 23, 2010 Author Report Share Posted October 23, 2010 Exactly what I was trying to avoid. Seems like there is no real way to do this right now other than making the bot so big that it won't even compile.. There's like 50 check boxes that have to be checked and having to do so manually each time is a pain in the rear. I really hope that there is a fix for these kind of limitations in the works.. Quote Link to post Share on other sites
Praney Behl 314 Posted October 23, 2010 Report Share Posted October 23, 2010 Wait I'll try something maybe a nested operation will work. So I assume that then you'll have 50 variables that need to be true, is that correct? Praney Quote Link to post Share on other sites
New Guy 4 Posted October 23, 2010 Author Report Share Posted October 23, 2010 Yep, there's actually more like 52 variables that I have.. Quote Link to post Share on other sites
Praney Behl 314 Posted October 23, 2010 Report Share Posted October 23, 2010 Mate, I was thinking to use nested evaluate command and assign value to variables but it is a conditional operator.. silly me.. No couldn't get it to work either, well an option would be to have a sub called 'select all' and use if statement in it to check if the 'select all' checkbox is ticked, then set var1 =true; set var2 = true; etc... Quote Link to post Share on other sites
New Guy 4 Posted October 23, 2010 Author Report Share Posted October 23, 2010 I think I may be missing something here Praney. How can you set a variable to = true using an if command? I don't see any way to do that. Quote Link to post Share on other sites
Praney Behl 314 Posted October 23, 2010 Report Share Posted October 23, 2010 Here is a sample New Guy, I hope you'll get the idea of what I am trying to say. PraneyNewGuy_Sample.ubot 1 Quote Link to post Share on other sites
New Guy 4 Posted October 23, 2010 Author Report Share Posted October 23, 2010 Hmm, I guess that's something new to me there. Didn't know you could set the variable to true by entering the word true as the content. Thanks.. Quote Link to post Share on other sites
zerofill 0 Posted October 23, 2010 Report Share Posted October 23, 2010 Didn't know you could set the variable to true by entering the word true as the content. Thanks.. Yeah like I was saying... if you have a programming background... it is like your are throwing everything you believe out the window sometimes LOL... But you're right it still isn't "True" in the way you are thinking but same result when it comes to Ubot hehe. 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.