R
Rico Rivera
I have two files:
FileA.vb
FileB.vb
FileA.vb contains the following sample code:
NameSpace SomeNamespace
Public Class SomeClassA
Public Shared Function MethodA() As String
...
End Function
End Class
End NameSpace
FileB.vb contains the following sample code:
NameSpace SomeNamespace
Public Class SomeClassB
Public Sub MethodB()
Dim strA As String
Error? ---> strA = SomeNamespace.SomeClassA.MethodA()
...
End Sub
End Class
End NameSpace
What I'm trying to do is call the shared method, MethodA, in
SomeClassA in FileA.vb within FileB.vb. They both have the same
namespace. FileA.vb compiles fine into a .dll but Fileb.vb has
trouble compiling saying:
error BC30456: 'MethodA' is not a member of 'SomeNamespace'
Can I do this? I would like to keep the classes in their own seperate
files.
Thanks!
FileA.vb
FileB.vb
FileA.vb contains the following sample code:
NameSpace SomeNamespace
Public Class SomeClassA
Public Shared Function MethodA() As String
...
End Function
End Class
End NameSpace
FileB.vb contains the following sample code:
NameSpace SomeNamespace
Public Class SomeClassB
Public Sub MethodB()
Dim strA As String
Error? ---> strA = SomeNamespace.SomeClassA.MethodA()
...
End Sub
End Class
End NameSpace
What I'm trying to do is call the shared method, MethodA, in
SomeClassA in FileA.vb within FileB.vb. They both have the same
namespace. FileA.vb compiles fine into a .dll but Fileb.vb has
trouble compiling saying:
error BC30456: 'MethodA' is not a member of 'SomeNamespace'
Can I do this? I would like to keep the classes in their own seperate
files.
Thanks!