cancel
Showing results for 
Search instead for 
Did you mean: 

set the maximum length of textedit element in webdynpro

Former Member
0 Kudos

Hi All,

How to set the maximum length of texedit element to a some constant characters.setting col and row property to 10 and 2 didnot set max length to 40.setting width and height also didnt helped to limit the characters user can enter to 20.

Thanks,

pkv

Accepted Solutions (0)

Answers (5)

Answers (5)

Former Member
0 Kudos

Hi,

You can create a simple type in the local dictionary and set the maximum length for the simple type you created.

Create a context which having the simple type you created as the context data type. Then in your view, mapped the inputfield to the context you've created.

Regards

Former Member
0 Kudos

Hi

you can create simple string data type.there you can set the maximum and minimum length for your data type and bind it to the text edit using context attributes .

u can also refer the thread :

Former Member
0 Kudos

Hi,

use simple type to bind the textedit ui element.

In simpletype definition tab take type as string and set maximum length property to your desired value.

hope it helps you.

Regards,

ramesh

0 Kudos

>

> Hi All,

>

> How to set the maximum length of texedit element to a some constant characters.setting col and row property to 10 and 2 didnot set max length to 40.setting width and height also didnt helped to limit the characters user can enter to 20.

>

> Thanks,

> pkv

Hi,

Setting row and height is for layout purposes and not for the limiting of text in a TextEdit UI Element.

To ensure that the Text Exit has only 40 characters in 04s - you can do as Alka has suggested.

For doing the same in CE 7.1 - you can use the onChange Action and write code inside that method to limit the number of characters.

I would suggest that you use IWDMessageManager to show a message in the MessageTray whenever the user goes over the limit of 40 characters - rather than accept the whole text and then show some sort of popup.

Thanks.

p256960

Former Member
0 Kudos

Hi,

The properties that you have mentioned for the TextEdit UI element are used to control the visible appearance in the GUI.

To limit the content of the text edit, you will have to control the context assigned to this Text Edit element.

You can Create a simple type of String Type with its length limited to 40 (any value of your choice), and then for the context to be used for Text Edit, choose this Simple Type as its type.

Regards,

Alka.