structures

S

Sam

Hi,

I have a public structure defined in a global module.
I have a public function of a class that returns this structure:


Structure CtrlStatus
Public FieldID As Integer
Public Status As String
End Structure

Public Function ChkCtrlFields(ByVal dtCtrl As DataTable) As CtrlStatus


And it gives me this error :

'ChkCtrlFields' cannot expose a Friend type outside of the Public class
'Fields'.

How can I overcome this ?

Thx
 
A

Anthony Sox

delcare it as Public i.e

Public Structure CtrlStatus
Public FieldID As Integer
Public Status As String
End Structure

A structure is Friend by default. To specify the accessibility in more
detail, include Public, Protected, Friend, Protected Friend, or Private in
the Structure statement.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top