on 05-28-2009 7:16 AM
Hi,
I'm developing an occasionally connected application using NetWeaver Mobile 7.1. In one of the view, I use TextEdit control to display the address information where the address is a multiline text data. During testing of the application in the simulator, the wrapping of text in the TextEdit control is not working properly. The wrapping property of TextEdit control is set to "soft" but the text is not getting wrapped. Even I tried the other option "hard" wrapping but it throws some error while building of the application.
Please suggest a solution to do wrapping of text using TextEdit control.
Thanks in advance.
Regards,
DVR.
Hi,
Set the rows and cols for the Text Edit. it should work.Also you can leave the wrapping to soft
for e.g. : You can maybe set rows as 5 and cols as 40
Regards,
Narayani
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Nipun,
The rows and cols properties are already set and also the data is multiline but the text is not wrapping.
Say the properties of a TextEdit control rows is "4" and cols is "30" was set. The data is also a multiline text say each line has more than 30 characters. During wrapping of text with in TextEdit control the first row should have only 30 characters and rest should be wrapped off to the next row and so on.
But during execution what happens is the text is not getting wrapped instead the first row itself has all the characters of first line of the text and second row has next line of text and so on. The text in a row can be scrolled through using horizontal scrollbar.
My need is the horizontal scroll bar should not come and the text need to the wrapped off with number of cols specified.
Regards,
DVR
Hi Nipun,
Here I'm not using TextEdit control inside the Table control.
For sample text, here it is.
"Printer at John desk not working properly.
Check the problem and refill the catridges."
First set the rows and cols properties of TextEdit contorl as "3" and "20" respectively. They try using the above sample text.
Regards,
DVR.
Hi Vinodh,
As the text itself suggests that there is no newline character like \n is there. So the control will not show the text in multilines.
Any text need to contain new line characters to be shown in multiple lines in any control. Please see that if you are entering this text using a control then these characters are auto inserted on enter but if you are creating this text in program then u need to new line chars.
E.g Printer at John desk not working properly.\n
Check the problem and refill the catridges."
Hope this this will solve the problem.
Regards,
Nipun
Hi Nipun,
Here the problem is not with multiline of TextEdit control, it works fine. The real issue is with wrapping of text in the TextEdit control.
Say the TextEdit control whose cols property is 30, suppose if the text goes beyond 30 characters it should get automatically wrap to the next row and so on. Either the text can be multiline or single line.
Regards,
DVR
Hi Vinodh,
I checked the TextEdit control. Please check the properties at your end. for e.g. keep the column property to 30 rows to 4 and wrapping to soft.
Give a value of around 50 chars as string to the bound context attribute for the control.
The control wraps the text according to the character size. If the characters are less than column prop then you need to add newline character to see the text in multiline.
Please check again.
Regards,
Nipun
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.