Right off I will caution you about doing too much in Form Load. There's a weird thing, which some might reasonably call a bug, though it technically isn't, such that any exception thrown in the Load event (and ONLY the load event), which isn't also handled in the load event, gets quietly swallowed. So, if you have an exception outside of the code that you have in a Try...Catch...it can behave REALLY weird, because it might get to a point and then just stop. This will only be true on systems running a 64-bit version of Windows, but those are increasingly common. For this reason, I like to do things in the form constructor (Sub New), and be cautious with anything in Load.
Second, I like the fact that you were making use of the Using construct. I didn't like the fact that you used if for the datatable. The whole point of Using is that the object will be cleaned up when you are done with it....which is the End Using. However, you don't want the datatable to go away, you want to set it as the datasource for the table. You should be using the Using construct for the connection and the dataadapter, but not for the datatable. You want THAT particular object to persist for quite a bit longer than just the Using block.
Third, you have a poorly named Datatable variable called DataTable at form scope. The names a poor choice, because...well, datatable is the type name, so that will just cause confusion. You don't totally NEED the variable at form scope, but it might be useful, so go ahead, just give it a different name. However, you are loading a different table in the Load event. You should be loading the one datatable at form scope rather than that local datatable that you are loading in the Using block.
Fourth, a similar point could be made about the form scope dataadapter versus the local scope one created in the Load event. The SQL in the form scope version is better than the SQL in the local one, because writing out the field names is going to always have slightly better performance over using SELECT *, so if you are willing to write out the field names, then do so. Also, if you are making the one at form scope, then you don't need the local one.
Finally (at least for now), you don't need to write those INSERT and UPDATE statements. You can get that automatically in many cases, and this is one of those cases. You create the dataadapter with the SELECT statement, as you did, then you do something like this:
Code:
Dim cb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(adapter)
Then you just call adapter.Update. What the commandBuilder does is takes your SELECT statement, which you already have to the adapter when you created it, and generates UPDATE, INSERT, and DELETE sql based on that. The CommandBuilder does have some limitations, such as it won't generate the SQL if your SELECT statement has JOINS in it, but for a single table SELECT statement, as you have, then CommandBuilder takes care of the rest of the stuff, so you don't need to write any of that.
By the way, it may just be the poor choice of a name for DataTable that is causing the error you are getting, but the other items need to be addressed, too.