Please Help before i kill my machine (not realy but thats how i feel).
I have successfully created AND compiled AND referenced a new class in VB.NET, and created the counter program to use it in VB6, however this works fine if i pass a string but i want to pass a picture from VB6 to VB.NET.
Here is the snippit of code in VB.NET
--------------------------------------
Public Sub addimage(ByVal stdpic As stdole.StdPicture)
End Sub
--------------------------------------
Here is the snippet of code in VB6
--------------------------------------
Private Sub Command1_Click()
Dim o As ClassLibrary1.CCWClass
Set o = New ClassLibrary1.CCWClass
Dim i As StdPicture
Set i = LoadPicture("c:\test.bmp")
o.addimage (i)
End Sub
--------------------------------------
When i run it it generates an error :-
"Run-time error '5':
Invalid procedure call or argument"
Im sure its only because i havent passed the correct information.
Please help me.
Thanks.
P.S. i have only had VB.NET for a few days so please forgive me if there is a easy solution.
I have successfully created AND compiled AND referenced a new class in VB.NET, and created the counter program to use it in VB6, however this works fine if i pass a string but i want to pass a picture from VB6 to VB.NET.
Here is the snippit of code in VB.NET
--------------------------------------
Public Sub addimage(ByVal stdpic As stdole.StdPicture)
End Sub
--------------------------------------
Here is the snippet of code in VB6
--------------------------------------
Private Sub Command1_Click()
Dim o As ClassLibrary1.CCWClass
Set o = New ClassLibrary1.CCWClass
Dim i As StdPicture
Set i = LoadPicture("c:\test.bmp")
o.addimage (i)
End Sub
--------------------------------------
When i run it it generates an error :-
"Run-time error '5':
Invalid procedure call or argument"
Im sure its only because i havent passed the correct information.
Please help me.
Thanks.
P.S. i have only had VB.NET for a few days so please forgive me if there is a easy solution.