cancel
Showing results for 
Search instead for 
Did you mean: 

SAP Cloud SDK : Display activity Note in the PDF form in table cell

Former Member
0 Kudos

Hi Experts,

I have requirement of display activity notes containing more than 255 characters in the PDF print form in table cell.

Here is my CustomOB.

Scenario:

businessobject CustomOB

{

[DependentObject(TextCollection)] node TxtNote;

node ClosedActivity [0,n]{

[Transient] element ClosedActivityCB: Indicator;

[Transient] element TransactionID : LANGUAGEINDEPENDENT_MEDIUM_Name;

[Transient] element Description : LANGUAGEINDEPENDENT_EXTENDED_Text;

[Transient] element ActivityType : LANGUAGEINDEPENDENT_EXTENDED_Text;

[Transient] element Status : LANGUAGEINDEPENDENT_EXTENDED_Text;

[Transient] element Note : LANGUAGEINDEPENDENT_EXTENDED_Text;

}

In an action script I retrieved closed activity details, like below script,

var CompActQry = Activity.QueryByElements;

var CompActSel = CompActQry.CreateSelectionParams(); CompActSel.Add(CompActQry.PartyID,"I","EQ",this.CustomerID); CompActSel.Add(CompActQry.LifeCycleStatusCode,"I","EQ","3");

var CompActRes = CompActQry.Execute(CompActSel);

var CAChild : elementsof CustomeFacet.ClosedActivity;

foreach (var CA in CompActRes)

{

CAChild.TransactionID = CA.ID.RemoveLeadingZeros();

CAChild.Description = CA.SubjectName;

CAChild.ActivityType = CA.TypeCode.GetDescription();

CAChild.Status = CA.LifeCycleStatusCode.GetDescription();

CAChild.Note = CA.Note;

}

But CAChild.Note only can contain 255 characters. As I declared LANGUAGEINDEPENDENT_EXTENDED_Text;

I mapped the Note to print form to print note on PDF.

How can I declered "element Note" that I can print more than 255 charaters.

How can I use textCollection 'TxtNote'? Should I declare element Note as TxtNote?

My output PDF will be like below, All activity notes should be print in complete content.

Pls Help me ASAP.

Thanks and Regards

Swati Goswami.

Accepted Solutions (1)

Accepted Solutions (1)

A-J-S
Active Participant
0 Kudos

Hi Swati,

Try FormattedText data type, it can have more characters.

Ajith

Answers (1)

Answers (1)

former_member183363
Active Contributor
0 Kudos

It says it can only contain 255 characters, but have you tried? Some screen fields we've seen or added, if memory serves, can take far more. You might have some luck with that or other text data types by testing to see if it actually limits you.

Former Member
0 Kudos

Hi Lewis,

Thanks for answer.

But 'LANGUAGEINDEPENDENT_EXTENDED_Text' type can only contain 255 characters,I tested it can't store more than that.I think 'Note' data type and Dependent Object 'TextCollection' can store any number of characters.

Do you know or test any other text data type that can extend its actual limits? Let me know if you find.

Thanks and Regards

Swati

former_member183363
Active Contributor
0 Kudos

Swami,

Try just the type 'Text' --- according to the repository explorer, 'An upper limit for the number of characters that a "Text" can contain is not defined.' If you can use that, great; if not, then I think you're out of luck.

Lewis