Datatable Search (via a Searchbar)

Hello,

I’m currently trying to create an Enterprise application that relies on a Datatable to fetch and display data for various SKUs. However my programming knowledge is pretty awful, even though I went through online tutorials and training I’m always hitting an obstacle somewhere.

Basically what I wanted to do is have a search bar that searches through the datatable, Now I want users to search with either two different columns. (Via SKU name or SKU number)

I’ve attached a screenshot of what I’ve made so far. But I’m really drawing a blank on how to make the rest of the script.

So far what I’ve done is created a String variable so that I can make the search bar accept upper and lower case letters and the results would be found.

Afterwards is to get the Data Table Row (I didn’t see a Column node honestly so I don’t know if this will work.) and then make it into an array. But afterwards I’m honestly lost as to how I make it search

Thank you

did you ever figure it out im having a simular issue.

You probably can break blue pin and do Branch node.

cant get it to work yet everyime i press a key it adds another of the same even when i erase the letters and cant get it to erase the extras and also to give more possibles without repeating and adding wore children and id like ir to give possibles with simular letters without adding alot of children ive tried it several ways


This is what i have so far but it has alot of bugsbut its the only way yet that i have been able to get a output = to what im typeing

Your image is unreadable

sorry ill try to make it bigger one min





I’ll be honest, this is a mess. Visually.

Is this only search by name?

If so, maybe this is better?

I trying to make it get the name from what i type compare it to the list and then get the item or items without repeating it self ive never done a search bar before and im still pretty green in unreal so im a little lost

What do you mean repeating itself?


heres a pic

What im trying to do is make a search bar add one of all the possibles to the list in the scroll box depending on what the user types so they can slick on them and itll add it to the crafting menu the menu already works with the catory buttons like here im using the category button then ckicking on the item in the box


im basing my search bar off the logic in the category search and altered version of the search bar video. been trying different methods for a week now

Ok, here what you need to do:

You need grid for found items. When textbar is changed you need to empty this grid and rebuild with items that falls under needed name.

Something like that:

Made an error, is empty branch should go from false not true.

Do i need to put the items in the grid or just fill it with the items i can already fill it with the items just be running the whole funcion i made on the grid itself (itts not in the pics above) i tried that but got no where whith how to empty and fill it it would eigther erase everything or give me nothing

this is when i run the script to fill the grid with all the items


it works fine i tried the only video from the forum but got nowhere with it

ok ill try it thks

Ok i kinda got it but the slots stack on top of seah other in one slot like this


i had to do it a little differently though to be able to make it work hers the code



i could be the grid layout is the only thing i can think of heres the grid logic


Yes, all you need to copy code for the same node from old code

i did that but doesnt work right


this is the code on the widget

this is the code on event but soes the same thing
i did this to make it not stack

it stops the stacking but adds a bug shen you type senond letter or backspace doesnt matter any keystroke it add a bunch of empty slots and pushes the other slots to the bottom here i pressed the s key

all ok but i press another key and this happens

the origianal children are there but have a bunch of empty slots above them
and if you exit the text box end enter it again it doesnt clear the empty blocks or the ones that are full

Here is updated

You don’t need set row and set collum, there is pins for that on add childe to uniform grid.

And I don’t see the logic behind adding for loop. You do understand that it’s the reason you getting copys of the same item?

And you don’t need to lower node, find substring doesn’t care about if it’s lower or upper, if use case set to false