Skip to Content
avatar image
Former Member

TextEdit Component

Hello Guys,

I've create a Web Dynpro Application and inside the view I add a TextEdit component with "EMPTY VALUE". How can I set the value "TEST" on the wdDoInit() method on this value in Runtime ? I don't Context parameters.

Like:

TextEdit.setValue("TEST);

I should use a wdControllerAPI or wdComponentAPI ?

Thanks,

Evandro.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    avatar image
    Former Member
    Apr 20, 2006 at 11:39 AM

    Hi Evandro

    As Armin mentioned you must bind value property to a context attribute.

    Let xxx is the context value of type string.Inside wdDoInit() write:

    wdContext.currentContextElement().setxxx("TEST");

    You can also use inside wdDoModifyView() this code

    IWDTextEdit t= (IWDTextEdit)view.getElement("TextEdit1");
    t.setValue("TEST");

    but still context binding is needed.

    Regards

    Ananda

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member
      wdDoModifyView(...)
      {
        IWDTextEdit edit = (IWDTextEdit) view.createElement(IWDTextEdit.class, null);
        edit.bindText("<path-to-context-attribute>");
      }

      Value in TextEdit will be value in context attribute.

      Armin

  • avatar image
    Former Member
    Apr 19, 2006 at 11:45 PM

    You must bind the "value" property to a context attribute and set the context attribute value.

    Armin

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Apr 20, 2006 at 12:13 AM

    Armin,

    I just add the TextEdit on the view. I'm not using Context parameters. I would like set the value on the wdDoInit().

    Thanks,

    Evandro

    Add comment
    10|10000 characters needed characters exceeded