Free Support Forum - aspose.com

Mutliline textbox to excel merged cells

I want merged cells to show new lines, what character do i need to use in PutValue

cells(31, 0).PutValue(txtMnwdDescription.Text)

cells(31, 0).PutValue(txtMnwdDescription.Text.Replace(vbCrLf, ?????))

I want multiline vb.net text box to display in excel cell the same way the text is shown in multiline textbox

thanks

Please try:

cells(31, 0).PutValue(txtMnwdDescription.Text)

cells(31, 0).PutValue(txtMnwdDescription.Text.Replace(vbCrLf, vbLf))

cells(31, 0).Style.IsTextWrapped = True