cancel
Showing results for 
Search instead for 
Did you mean: 

Displaying 10 characters for a feild in a smartforms

Former Member
0 Kudos

Hi all,

I have this feild in smartform &L_CARGO_TYPE(C)& the requirement is to make it accept 10 characters only. Can you help me please. Thanks in advance

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

You can just declare a variable of length 10.

1. In Global data definition create a variable--> w_text ,, associate type --> CHAR10.

2. Just above that node create -> Program lines. In Input parameter put L_CARGO_TYPE and in output parameters put w_text.

3. In the coding section just put below lines:

w_text = L_CARGO_TYPE.

4. Drag and drop w_text form list filed into your text node.

Pls tell me if anything no clear.

Regards,

Lokesh.

Former Member
0 Kudos

tHANKS VERY MUCH BUT HOW CAN I CREATE PROGRAM LINE i MEAN WHICH OPTION iI CHOOSE WHEN CREATING

Former Member
0 Kudos

Hi,

To create any program lines, Just follow the steps:

1. On that node (Window, Text,...etc) whtaever it is, Right click, Create -> Flow Logic -> Program Lines. You get a node to write code same as SE38 editor.

2. then follow the steps that I told you earlier. Please tell me if anything is not clear.

Rgs,

Lokesh.

Edited by: Lokesh Tarey on Apr 26, 2010 11:58 AM

Answers (2)

Answers (2)

prakashjasti
Contributor
0 Kudos

Write as

&L_CARGO_TYPE(C)+0(10) &

Former Member
0 Kudos

No it is saying " Frild name not accepted"

former_member217544
Active Contributor
0 Kudos

Hi Shaheen,

Check if this link helps you:

http://help.sap.com/SAPHELP_NW70EHP1/helpdata/EN/1c/f40c6fddf311d3b574006094192fe3/content.htm

Regards,

Swarna Munukoti

Former Member
0 Kudos

thanks but I tried to incooperate but I'm getting an error.

What I did is :

&L_CARGO_TYPE(C)(10)&

Former Member
0 Kudos

Hi

try using

&L_CARGO_TYPE(10)&

Regards

Shiva