Author | Message | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Meka][Meka Unstopable Posts: 700 | note: you may use this tutorial on other sites as long as u post the author note. -------------------------- Understanding Classes -------------------------- Author: Meka][Meka -------------------------- http://www.meka-meka.com/ -------------------------- Ok start a new project, then create an empty class, on the left u have your com,.net components, think of them as a class, only with a usercontrol combined, your application is also a class. Ok lets get started, first we need our class code. Open the class and paste this code
close and save the class, we need a function to use to pass it forward for example, view form code and paste:
now we need to create an instance of the class,
we need now to give it some data, in form load paste
then we need to pass it to the function
now run your application and see your class work ;) | ||||||||||||
C0D3Z3R0 Pro Posts: 166 | The tutorial is useful but it's confusing me as well... heres my code, everything I paste shows as error. Form1.vb
Class1.vb:
hope you can help fix this | ||||||||||||
Meka][Meka Unstopable Posts: 700 | well this tut is for ametuars at VB7, by looks of it, u dont know much of vb6 neither, y u have the user item outside the function, i state in the tutorial 'we need now to give it some data, in form load paste'
-/Meka][Meka | ||||||||||||
C0D3Z3R0 Pro Posts: 166 | i'll forget trying to learn this, i'll stick to learning vb6 for now ;) | ||||||||||||
Meka][Meka Unstopable Posts: 700 |
learning vb6 is the same problem, ther is still same things like this, only this is the more advanced of it, dont bother with vb6 if u wanna come to vb7, come straight to vb7, ther is not much difference code should be like this: class1.vb
Form1:
-/Meka][Meka | ||||||||||||
MethodZ n00b Posts: 12 | i do it like this?:
cause i was getting the error with UserData lol.. im super newbie okay :roll: ... but i think this is it.. but i get:
more then likely... im just retarded and it's something simple that i have no idea of.. :? | ||||||||||||
Meka][Meka Unstopable Posts: 700 | when u create your class, by that error u have changed startup item, goto project settings, and select form 1 class as your startup item ;) |