Everyone has been helpful during this learning process, Thanks!

I am not even sure this is doable or even how to start the code! Can anyone please point me in the right direction. I have searched everything I can on this but nothing seems to fit what I want to do.

I have 4 textboxes as listed below. This is in VB.Net behind a Webpage

Textbox1 = PalletID (max count for PalletID # = 90)

Textbox 2 = CartonID (max count for CartonID # = 5)

Textbox 3 = PartID Textbox 4 = PartSN

On enter - Textbox1, Textbox2, Textbox3, Textbox4, sends Textbox data to SQL database and then Textbox3.focus
Textbox1 & Textbox2 retains current data.
The code I have for the above is working!

I want to add these operations to the code
(how I want it to happen)

From the SQL Database
When Textbox2 current value count = 5 Then Textbox2 Clears and Textbox2.Focus
When Textbox1 current value count = 90 Then Textbox1 & Textbox2 Clears and Textbox1.focus
Then repeats for another pallet.
.

Member Avatar for LastMitch

I am not even sure this is doable or even how to start the code! Can anyone please point me in the right direction. I have searched everything I can on this but nothing seems to fit what I want to do.

I don't see any query?

A query should look like this (it's just an example):

Dim MyNewTable As DataTable = Mytable.DefaultView.ToTable

If you want to get COUNT values in the database then you need a query for that (it's just an example):

Filter = DataSet.Tables("TableName").Select(COUNT("ColumnName = 'valves')")

You need a query to SELECT the valves once you enter the values from each TEXTBOX.

When Textbox2 current value count = 5 Then Textbox2 Clears and Textbox2.Focus
When Textbox1 current value count = 90 Then Textbox1 & Textbox2 Clears and Textbox1.focus

Before you do something like that you need a query.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.