Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
How declare structs in VB?
Name: Carlos Meyer Date: September 5, 2004 at 19:52:43 Pacific OS: Windows XP CPU/Ram: Duron 1600 / 512
Comment:
I´ve created a dll using C and now I want to access the dll functions from my exe created in VB. I dont have problems with functions with simples parameters like int and double, but I dont know how to deal with structs. How can I deal with these issues?
Name: egkenny Date: September 5, 2004 at 20:50:02 Pacific
Reply:
You did not say which versions of VB you are using. VB 6.0 has Type to declare structures VB.NET has Structure to declare structures VB.NET has Class to declare classes
Examples:
Visual Basic 6.0 ----------------
Private Type Employee GivenName As String FamilyName As String Extension As Long Salary As Currency End Type
VB.NET ------
Private Structure Employee Public GivenName As String Public FamilyName As String Public Extension As Long Private Salary As Decimal Public Sub GiveRaise(Raise As Double) Salary *= Raise End Sub Public Event ReviewTime() End Structure
Private Class Employee Public GivenName As String Public FamilyName As String Public Extension As Long Private Salary As Decimal Public Sub GiveRaise(Raise As Double) Salary *= Raise End Sub Public Event ReviewTime() End Class
0
Response Number 2
Name: Carlos Meyer Date: September 5, 2004 at 21:35:04 Pacific
Reply:
Thank you very much! Im using VB 6.0... thats all I needed. Thanks. :)
Summary: I am writing a software program in VB 6.0 that accepts input from a user and stores it to an Access database - both text and numeric. How do I declare the variables for these items. For instance, I ha...
Summary: Hello, How do you delete a row in vb.net where there is a blank data? I've tried the following, and all do not work... strSQL = DELETE FROM tblProducts WHERE prodID = & " " strSQL = DELETE FROM tblPro...