Need help building and Access (mdb) table from an existing table in VB.NET 2010
I have an Access (MDB) database that contains a table named NOZZLES and need to create a new table caalled NOZZLECOMBO. All of this need to be done programatically in VB.NET 2010.
I can create the template for the NOZZLECOMBO table but need help getting the data in.
Basically I have a NOZZLES table that consists of various size flow nozzles (sometimes the same size appears mor than once but needs to be treated separately since its exact measurement may differ from the other nozzle of the same nominal size.
Ultimately my progarm will use the data in the NOZLECOMBO table to determine which nozzle combination to use for a specific task.
Here is the layout of the NOZZLES table
Some combinations may seem to be duplicate but as I said the actual size of a nozzle may differ from one of the same nominal size (there may be two 6 inch nozzles but the first may actually be 5.95 and the other may be 6.1 and that will change the flow capacity.
My program will always try to use numbers between LO and HI but I will allow it to got down as low as LOWLOW and as high as HIHI
So what I need is help building the NOZLECOMBO table - making sure all of the possible combinations exist and end up in ascending order based on the LOLO data for each combination.
One final point: these may be as many as 12 different nozzles (depending on the application) but I think if I can get help with 5 nozzles then 12 will jest be more of the same.
This appears to be a very complete program and a lot of effort
I am having a problem however at line 13
Dim rdrNozzles = cmdReadNozzles.ExecuteReader()
The error:
ExecuteReader requires an open and available Connection. The connection's current state is closed.
I don't know what to do with this.
Any help
Beartlaoi
Do you have a file named Nozzles.accdb in the same folder as your exe?
If not either put your database there with that name or change line 6 so it can find your database.
charlieb01
ASKER
My database is an older version *.mdb (for compatability reasons) and I missed a line when changing that part of the code.
Also, my real airflow numbers are Double not Integer so I had to make a few changes to accomodate that but OTHERWISE:
This was the BEST assistance I have ever received since joining experts-exchange. I had no idea how I was going to do this and you came up with the perfect program. Fot that, I am extremly grateful. You are truly a master.
I am having a problem however at line 13
Dim rdrNozzles = cmdReadNozzles.ExecuteRead
The error:
ExecuteReader requires an open and available Connection. The connection's current state is closed.
I don't know what to do with this.
Any help