Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

problem add text in textbox

Status
Not open for further replies.

cmaknp

Programmer
Aug 28, 2002
25
IN
Hello pls help again

i want to add this text in text box

Txtbox.height = 1245
txtbox.width=4455
txtbox.multiline=true

like

a="Its New One"
b="HowEver its good"
c="plss tell me add, how to use"

so how to add in text box row wise, like below, becoz i m adding so..its adding in same line, but i want to add in next row of text box, pls guide me

Its New One
HowEver its good
plss tell me add, how to use



 

Txtbox.height = 1245
txtbox.width=4455
txtbox.multiline=true

I'm not sure how you can achieve a setting of 4455 for the width of a textbox (my screen resolution is 1024 so it's way off the screen) or maybe we are talking a different scale. But I cannot see any references to multiline being a property of a textbox. My suggestion is to change you field (in the table) to a memo and change your control to an EditBox.
Mike Gagnon
 
Are you looking for something like this...

X=[Its New One] + CHR(10)+ CHR(13);
+ [HowEver its good] + CHR(10) + CHR(13);
+ [plss tell me add, how to use]

?X

HTH - Wayne
 
change to editbox as mgagnon sugested and concatanate the string as xbasedude suggest.

you can leave out the chr(10).

if you don't need the items on each line then leave out the chr(13). chr(13) is the carrage return. Attitude is Everything
 
HI cmaknp,

Going with the title of the thread How to add 4 fields in a TextBox...
1. It is assumed that this is only a display TextBox and not a read/write textbox i.e. bound to a field in a table, and then used to input data.
2. If this assumption is correct, then I suggest the follwoing..
Create a form property .. let us say.. myText2
And in the refresh event of Text2.. OR...In the LostFocus Event of the text box which decides the value of these four fields.. add the code..
ThisForm.myText2 = MyField1+CHR(10)+MyField2+CHR(10) etc.
Set the controlSource property of Text2 to ThisForm.myText2

Another way is to use a LABEL.. set its height and width to whatever you want.. set its back color to RGB(255,255,255) to imitate a textbox back color... In the caption value.. enter
=myField1+CHR(10)+myField2+chr(10)+myField3
This will take care of the requirement.

Hope this helps you :)
ramani :)
(Subramanian.G),FoxAcc, ramani_g@yahoo.com
 
HI
my computer mouse click is behaving indifferently. And this is happening only when I get into this forum. The odd thing is that, when I click on a thread it jumps to Home.. when I click on Submit POst.. It again jumps to Home and wont post the qnswer.. If I hold the mouse for a while on the button say 30 seconds and then click, at times, I get it work properly. Outside of the forum, everything is fine. I am not complaining it to the forum thinking I alone am having the odd behaviour and want to find out the reason. Also this is making me either keep silent or at times make me commit errors.. as in this thread. This answer is for the same person's question but another thread. Sorry to confuse other viewers. :)
Good day to everyone :) ramani :)
(Subramanian.G),FoxAcc, ramani_g@yahoo.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top