You want to read, edit and save texts in an TextEdit area and save it so a Standard Text object...
tCode: SO10
The first step is to create an SO10 standard text that we would like to read, edit and save
Go to SO10 and create this text object:
Let us add some bogus text so we can see the text later in the tests…
Don’t forget to save.
tCode: SE80
Create a new Web Dynpro
Click Yes 🙂
Click Ok
Look Teddy.. a nice starting point...
We need to create a context element to bind the text to.
In this case we will use a simple string… This is the simplest example:
You’ll probably know how to bind dictionary fields etc but for this example, we’ll use simple components only.
This screen is shown:
Click OK and TADA… We’ve just created the first node.
Now, create an attribute:
Right click on NODE1
Give an attribute name and choose for type STRING…
TADA (again…)
Now that we’ve created the context, let us use it in the view.
Double-click on the view MAIN and go to the Context tab.
Drag and drop NODE1 from right to left…
Result:
Open the Layout tab
We’ll change the Layout of the ROOTUIELEMENTCONTAINER to GridLayout:
=> Just for design purposes…
We will create a Load button, a TextEdit area and a Save button.
It is possible to create containers etc first… You can do this if you really like to do some extra work…
Create the load button:
And a TextEdit area:
And a Save button:
This will then look like this (It's rather ugly...):
Change the label of the button Load like this:
The rows and columns of the TextEdit area like this:
And button Save like this:
That looks a little more decent…
The clever boys and girls amongst you noticed that the buttons are not yet active.
Let us take care of that…
Select the Load button and ‘bind’ the onAction event…
Fill the popup like this:
Result:
Do the same for the Save button:
See the result:
The buttons are ACTIVE
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
37 | |
10 | |
5 | |
4 | |
3 | |
3 | |
3 | |
3 | |
2 | |
2 |