Line Break's


#1

hi,

trying to get line breaks to appear in cells of text.

I am using cell.PutValue_5

and in the text string I am putting \n where i want the link breaks to be

but instead of a line break it just prints the string:

Design\nAWH\nDC/DE1 T2

Any ideas?


#2

Please set wrap text property to true:

cell.Style.IsTextWrapped = true;


#3

Wrapping is set to true - still doesn’t work…


#4

Please post your sample code and generated file here. Thank you.


#5

Code:

Set cell = cells.item_3(""&Mid(str, intDayCount, 1)&""&NCount&"")
cell.PutValue_5 ""&strTTBText&""
cell.Style.IsTextWrapped = True
cell.Style.HorizontalAlignment = 1
cell.Style.VerticalAlignment = 1

strTTBText - contains a string of text - such as:

Divinity\l\nLJG\l\nFE/DI6 23

Thanks


#6

How about

cell.PutValue_5 strTTBText



#7

or cell.PutValue_5 “abc”&chr(10)&“def”


#8

genius - it works

thanks a lot


#9

on another issue - can you inject HTML into a cell and aspose format it correctly - such as or etc?


#10

No. We don’t support this feature now.