Jump to content
UBot Underground

Is there a way to do this?


Recommended Posts

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..

Link to post
Share on other sites

Hey Gary,

 

Use an if statement :

 

if "select all" = "True";

then

run sub1

run sub2

..and so on

 

or

if "select all" = "True";

then

Set all the varibles used for checkboxes to "True"

 

Praney

Link to post
Share on other sites

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..

Link to post
Share on other sites

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/

Link to post
Share on other sites
  • 1 month later...

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..

Link to post
Share on other sites

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.

Link to post
Share on other sites

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..

Link to post
Share on other sites

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...

Link to post
Share on other sites

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.

Link to post
Share on other sites

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..

Link to post
Share on other sites

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.

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...