msvisual.com Forum Index
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Turning a textbox container into a integer?

 
Post new topic   Reply to topic    msvisual.com Forum Index -> VB DOS
Author Message
signrite



Joined: 04 Oct 2007
Posts: 9

PostPosted: Tue Dec 27, 2005 3:26 pm    Post subject: Turning a textbox container into a integer? Reply with quote

Hi,

I have a text box in vbdos it holds the number "3"

I need to use this container for changing desktop color.

Heres the normal way :

SCREEN.ControlPanel(DESKTOP_BACKCOLOR) = "3"


I need to do something like this :

SCREEN.ControlPanel(DESKTOP_BACKCOLOR) = MyTextBox.Text

But get the error 'mis match'

I don't think VBDOS likes this,,,,, unlike vb6.0

Is there a way I can turn the number i have in the textbox into a
readable integer so it's treated like "3" after :
SCREEN.ControlPanel(DESKTOP_BACKCOLOR) =

Thanks,

Archived from group: microsoft>public>vb>dos
Back to top
View user's profile Send private message
Stephen Howe



Joined: 04 Oct 2007
Posts: 59

PostPosted: Wed Dec 28, 2005 10:34 pm    Post subject: Re: Turning a textbox container into a integer? Reply with quote

> I need to do something like this :
>
> SCREEN.ControlPanel(DESKTOP_BACKCOLOR) = MyTextBox.Text

Try

SCREEN.ControlPanel(DESKTOP_BACKCOLOR) = VAL(MyTextBox.Text)

Stephen Howe
Back to top
View user's profile Send private message
signrite



Joined: 04 Oct 2007
Posts: 9

PostPosted: Wed Dec 28, 2005 3:17 pm    Post subject: Re: Turning a textbox container into a integer? Reply with quote

Thanks m8, that sorted it very well, a star.

Back to top
View user's profile Send private message
Display posts from previous:   
Related Topics:
How can I suppress textbox popup menu one textbox at a time? I have examined the MS article "How to suppress a textbox control's popup menu" It applies the whole time that the app is running. I want to suppress the popup and add my own popup, but only when a speci

Integer variable is shown &HA My integer variable showing &HA It's like my integers are showing in hexadecimal. I want to see the decimal value.

converting single to integer Hi all, In C++, I can memcpy the address of a float into the address of an integer, and get the memory of the float: float f = 1.23; int x; memcpy (&x, &f, sizeof (float)); How can I do something similar in VB? I have a Single array, and t

Check if variant variable is integer Hi, I have the following code:- Select Case Right(week, 2) Case "" Do some code Case "25" Do some code Case "50" Do some code Case "75" Do some code End Select week will be something like 6, 6.25, 6.50, 6.75. How can I check, in my case statement, if it'

Conversion from string "" to type 'Integer' is not valid.?? My code worked just earlier and now its throwing the error: "Conversion from string "" to type 'Integer' is not valid." Anyone have any idea?? Protected Sub sender As Object, ByVal e As Dim strLogin As
Post new topic   Reply to topic    msvisual.com Forum Index -> VB DOS All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group