August 10, 2004
By the way, in reviewing the posts, I don't think you have the property
concept wrong. You've got it right. I was more in the mind-set of
functions,
as I didn't see the full code. Good job!
Joseph MCP
"Just Me" wrote:
> Thanks for the reply. It's getting late and I'm not too sharp but I'm having
> a problem following your reply.
>
> In a sense I already have a class level variable with the data in it (for
> Get); or into which I want to put the data (with Set)
> It is a combobox. The property is to get that data or set it.
> With that said, do you still think what you wrote applies?
>
> Thanks
>
>
> "Joseph MCP" <(E-Mail Removed)> wrote in message
> news:160A261A-FBAB-4F86-B29E-(E-Mail Removed)...
> >
> > August 10, 2004
> >
> > The property does not maintain an instance of ArrayList itself.
> > You also have the concept of the property wrong. What you should
> > do is create a page level variable of ArrayList and then create a
> > sub that you call to add a filter. Then if you want to retrieve the
> > filters,
> > just access the arraylist variable directly. This looks something
> like:
> >
> > dim filters as new ArrayList
> >
> > Private Sub AddFilter()
> > filters.add(cbofilter.text)
> > End Sub
> >
> > Private Sub Button1_Click(....)
> > if filters(0) = "Something" then
> > .... ' do something with list
> > End Sub
> >
> > A property is maintained by something like this:
> >
> > dim _userinput as string
> >
> > Public Property UserInput() as String
> > Get
> > return _userinput
> > End Get
> > Set (byval value as string)
> > _userinput = value
> > End Set
> > End Property
> >
> > Then you can use the property like this: Class.Userinput =
> Something.
> > I hope this makes sense! Have a good day!
> >
> >
> > Joseph MCP
> >
> >
> > "Just Me" wrote:
> >
> > > This doesn't work. I guess New is needed someplace but I don't know
> where?
> > >
> > >
> > >
> > > Public Property Filters() As ArrayList
> > >
> > > Get
> > >
> > > Filters.Add(cboFilter.Text)
> > >
> > > ---snip--
> > >
> > > Thanks in advance for any info
> > >
> > >
> > >
>
>
>
|