VB & OOP Question

  • Thread starter Thread starter Chan
  • Start date Start date
C

Chan

SqlParameter is a class, consider the following statements:

1>
Dim Q1() as SqlParameter

2>
Dim Q2 as SqlParameter()

3>
Dim Q3() as SqlParameter()

- Q1 is an array of SqlParameter type.
- What is Q2?
- Is Q3 an array of what?

Thanks!
 
Dim a() As String = New String() {"test"} 'array of strings
Dim b As String() = New String() {"test"} 'array of strings
Dim c() As String() = New String() {"test"} 'syntax error :-)

Array modifiers cannot be specified on both a variable and its type.
 
Good, thanks.

Additional question, still take SqlParameter(),

public function MyFun() as SqlParameter()

The returned object should be an array of SqlParameter objects, right?
 

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

Back
Top