cadwalli
Active member
Hi, I'm new to the forum and pretty new to vb.net so I obviously have a few questions I need to ask to help me along, I hope some of you are able to help.
Firstly, I'm not new to programming, I've been a DB Administrator and programmer in Progress for over 14 years, however I am new to VB.NET and would like some help with regards to understanding DB interaction.
Could someone please explain if my logic/thinking is correct, if I had a table in SQL Server which held purchase order details (po) which had a format such as:
po-num
po-supplier
po-date etc....
Would I then be right in thinking the best way to handle this in VB.NET would be to create a class/object that then maniuplates this, i.e.
Class: POClass
Properties :
POClass.po-num
POClass.po-supplier
POClass.po-date
Methods:
POClass.Load-PO (Loads the po from the db into the relevant properties, i.e. POClass.po-num = po.po-num etc)
POClass.Add-PO (Creates a new purchase order)
POClass.Delete-PO (Deletes the currently loaded po)
OR
Would i simply create load/maniuplation procedures within a form?
My thoughts were that I would go the class/object route for POClass so it could then be added to any other form that wanted to access PO's
Could someone help me understand if I am thinking correctly or if way off the mark here. If anyone has an example of what they think I am trying to do then I would really appreciate it.
I look forward to hearing from you.
Ian
Firstly, I'm not new to programming, I've been a DB Administrator and programmer in Progress for over 14 years, however I am new to VB.NET and would like some help with regards to understanding DB interaction.
Could someone please explain if my logic/thinking is correct, if I had a table in SQL Server which held purchase order details (po) which had a format such as:
po-num
po-supplier
po-date etc....
Would I then be right in thinking the best way to handle this in VB.NET would be to create a class/object that then maniuplates this, i.e.
Class: POClass
Properties :
POClass.po-num
POClass.po-supplier
POClass.po-date
Methods:
POClass.Load-PO (Loads the po from the db into the relevant properties, i.e. POClass.po-num = po.po-num etc)
POClass.Add-PO (Creates a new purchase order)
POClass.Delete-PO (Deletes the currently loaded po)
OR
Would i simply create load/maniuplation procedures within a form?
My thoughts were that I would go the class/object route for POClass so it could then be added to any other form that wanted to access PO's
Could someone help me understand if I am thinking correctly or if way off the mark here. If anyone has an example of what they think I am trying to do then I would really appreciate it.
I look forward to hearing from you.
Ian