Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Line Break after 132 words in web Dynpro java

Hi,

i want to pass a paragraph in R/3 through web dynpro java, because in r/3 there is restriction it will take 132 character in one row,due to this reason i want restrict in java also.means 132 character in one row, next word in second row.

String textLine = wdContext.currentContextElement().getText();

////                              int length = textLine.length();

//

//                              int currentLength = 0;

//                                                   while(text.length()>0)

//                                                   {

//                                                              currentLength = text.length();

//                                                              if(currentLength > 132)

//                                                              {

//                                                                                String[] lines = textLine.split("132");

//                                                                          text = text.substring(131);

//                                                              }

//                                                              else

//                                                              {

//                                                                         subString = text.substring(0,currentLength);

//                                                                         text = text.substring(currentLength);

//                                                              }

Please help or provide code for the solution.

Regards,

Shashank

Tags:
Former Member

Helpful Answer

by
Not what you were looking for? View more on this topic or Ask a question