One of the biggest struggles in Ubot Studio isn’t so much learning how a loop works or what the heck a while statement is, no –it’s getting your data into a table that works the way you do!
Of course you can put your data into a standard HTML table, but these are often too simple. Most users want to sort, filter, search, delete, insert, and export table data. Being able to do this makes taking action on information your bots collect far easier. It also makes them look and feel nicer.
Today there are paid plugins available that can help you build tables using a feature called a Datagrid. Datagrids are features of XAML that bring table functionality to C# software. It is a product provided by Microsoft and looks similar in syntax to XML.
While Datagrids are nice, they aren’t the only way to build a slick table in Ubot. There is another way and fortunately for us, it’s free.
I first stumbled across Tabulator while searching for JQuery scripts to use in Ubot. JQuery will be a topic for another post, but if you didn’t know there’s actually quite a lot of excellent things you can do with it.
Tabulator popped up with high marks everywhere I looked. It is an extensive script but there’s plenty of documentation available to help walk you through setting up its amazing features.
It had everything I could ever need and more. One feature that got me excited was the ability to create tables automatically from JSON, even JSON from a live web page.
If you do a lot of work with API’s, being able to create a table out of JSON that exists on a web page is huge. This ability takes out a huge amount of steps. You’ll see.
Some of these features have already been inserted in this example bot. It’s going to take time to get every Tabulator feature into it, but that’s the goal.
- Save selection to clipboard
- Select all rows
- Deselect all selected rows
- Count rows selected
- Create table from JSON on a webpage/API
- Create table from your own JSON data
- Show table in External Browser
For now you can see how you might use Tabulator in your own bots by downloading the example available to members. Join here to become a member, it’s basically free and gets you helpful bot examples like this that will speed up production.
You will want to check out Tabulator’s documentation and examples to see how it works and what features are available. If you plan on building a lot of bots, then definitely do that because this is one tool that will MASSIVELY speed up development.