Jump to content
UBot Underground

Ui Stat Monitor Not Updating In Ui Window Until Reopen


Recommended Posts

I am working on a program that needs API input by the end user. I have decided not to clutter the main UI with the API input and display information. (Twitter has 4 API codes to input, for it to work!)

 

So, what I did, was I put the input of end-user API data to the UI window element. The bot uses aymen's free ini plugin (great resource btw!), so it stores the API data in an ini, and I pull each back as a variable, to display in the UI window. I then have a button that the end-user pushes to update the ini settings at any time, which ultimately re-writes the new input data into the ini file.

 

Now, if I put the stat monitoring UI elements in the main window, there is no problem, it updates as soon as I hit the update button. However, if I put the ui stat monitors into the UI window, it will not update until I close that window and reopen it. For the purposes of the functionality and the design of my bot, this is unacceptable behavior. So, I am wondering what I could do to fix this? Does anyone have any ideas? Are you familiar with this limitation, or have some better idea? Please let me know! This issue is driving me crazy for 2 days now, lol!

 

 

Here is an example of this working on the main UI:

ui text box("Username",#username)
ui button("Update Name:") {
    clear list(%usernamelist)
    add item to list(%usernamelist,#username,"Don\'t Delete","Global")
}
ui stat monitor("Updated User Name:",%usernamelist)

And here is an example of it not working:

ui window("This is bad stuff") {
    ui text box("Username",#username)
    ui button("Update Name:") {
        clear list(%usernamelist)
        add item to list(%usernamelist,#username,"Don\'t Delete","Global")
    }
    ui stat monitor("Updated User Name:",%usernamelist)
}

Thanks for any help on this!

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