Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Val()

0 views
Skip to first unread message

Corsipo

unread,
Feb 22, 2001, 8:54:58 PM2/22/01
to
Okay. I got a small problem. I'm trying to use the Val command tot urn a
object in to the number part only. The problem is, it doesn't work with
values of a list.

x = Val(List1.List)

that in itself will error. Any help will be appreciated VB5.

Corsipo


Randy Birch

unread,
Feb 22, 2001, 9:03:46 PM2/22/01
to
The list property is an array ... the selected item is
List1.List(List1.ListIndex).

--

Randy Birch
MVP Visual Basic

Take the vb.net poll at:
http://www.mvps.org/vbnet/
http://www.mvps.org/ccrp/

Please respond only to the newsgroups so all can benefit.

"Corsipo" <cor...@iximd.com> wrote in message
news:Spjl6.1499$Ms3.1...@typhoon2.ba-dsg.net...
: Okay. I got a small problem. I'm trying to use the Val command tot urn a

:
:


Corsipo

unread,
Feb 23, 2001, 4:54:52 PM2/23/01
to
hehe. You're right there. I have that in the code. I'm mostly wondering
about how to do the Val command with that. It seems not to be working.
"Randy Birch" <r...@mvps.org> wrote in message
news:6yjl6.217988$KP3.53...@news3.rdc1.on.home.com...

Bryan Ecker

unread,
Feb 23, 2001, 5:09:10 PM2/23/01
to
"Corsipo" <cor...@iximd.com> wrote in
<M_Al6.30$3y6....@typhoon2.ba-dsg.net>:

>hehe. You're right there. I have that in the code. I'm mostly wondering
>about how to do the Val command with that. It seems not to be working.

Try Val(List1.Text)


Unless I'm misunderstanding what you're shooting for.

--
Bryan Ecker | I would burn for you.
ec...@us.hsanet.net | Feel pain for you.
http://www.hsanet.net/user/ecker | I would twist the knife
BAE SYSTEMS | And bleed my aching heart.

Randy Birch

unread,
Feb 23, 2001, 6:15:12 PM2/23/01
to
just wrap val around it.

--

Randy Birch
MVP Visual Basic

Please respond only to the newsgroups so all can benefit.

"Corsipo" <cor...@iximd.com> wrote in message

news:M_Al6.30$3y6....@typhoon2.ba-dsg.net...
: hehe. You're right there. I have that in the code. I'm mostly wondering

: > :
: >
: >
:
:


Corsipo

unread,
Feb 23, 2001, 9:24:27 PM2/23/01
to
Thanks. The List1.Text worked perfectly. Many thanks people!


"Bryan Ecker" <ec...@us.hsanet.net> wrote in message
news:Xns9051A74FCec...@207.126.101.100...

Randy Birch

unread,
Feb 23, 2001, 10:21:02 PM2/23/01
to
Ah .. but if you were to later use this against a combo box, where the combo
style was 0 or 1, the user could modify the contents of the edit portion,
making the value returned by Text and List(ListIndex) different. Just
something to remember.

--

Randy Birch
MVP Visual Basic

Please respond only to the newsgroups so all can benefit.

"Corsipo" <cor...@iximd.com> wrote in message

news:vXEl6.715$3y4.1...@typhoon2.ba-dsg.net...
: Thanks. The List1.Text worked perfectly. Many thanks people!

:
:


0 new messages