By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,274 Members | 2,229 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,274 IT Pros & Developers. It's quick & easy.

How to pass other than a primitive type as a property of a custom control?

P: n/a
I would like to do sth like this:

Page:
<MyNS:MyControl runat="server" Id="MyId" List="1,2,5,6" />
Code:
Public Property List As ArrayList
Get
If ViewState("List") Is Nothing Then
Return new ArrayList()
End If
Return CType(ViewState("List"), ArrayList) 'Is This possible?
End Get
Set
ViewState("List") = .... 'What can I do here if I want to parse the
received string to an ArrayList???
End If
End Set
End Property

There are lots of examples of String properties on the Web, but nothing
about Objects...
Thanks

Nov 18 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.