on 08-14-2007 1:00 AM
Hi,
Can we create some UI Element on the action of some button, i.e. writing code to create UI Element outside the wdDoModifyView() method of the view?
Regards,
Smriti.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes ...You certainly create a button ..in WdDoModifyView();
You have to import IWDAbstactButton or WDAbstactButton..check api..
first locate root container and use above method a button..it will enable during runtime..
Regards
Ravi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
create a context variable of type boolean name it "buutonAction"
write below code
in the Action of Button
OnActionClickButton{
wdContext.currentContextElement.setButtonAction(true);
}
write this code in wdDoModifyview(){
IWDLinkToAction actionDivision=(IWDLinkToAction)view.createtElement(IWDLinkToAction.class,null);
actionDivision.setText("generated link");
actionDivision.setReference("http://www.google.com");
}
Regards,
Naga
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
We can create an UI element dynamically, on button click action..Follow the steps given below:
1. Create a static variable say ' myvar ' of type com.sap.tc.webdynpro.progmodel.api.IWDView in last declaration part(ie. inside //@@begin others //@@end.
Eg: static IWDView myview;
2. 2. In wdDoModifyView(), add the following
myview=view;
3. Now add the following code in the "OnAction<Submit>" event to create an UI element dynamically:
IWDTransparentContainer rootContainer = (IWDTransparentContainer)view.getElement("RootUIElementContainer");
IWDLinkToAction Link1 = (IWDLinkToAction) view.createElement(IWDLinkToAction.class, "Link1");
rootContainer.addChild(Link1);
Hope it helps!!!
Regards,
TFG - Kumara Guru
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
i dont think you can do that, but certainly you can make the visibility of a UI element visible or invisible on click of a button and i think this can solve your problem.
Regards
TFG - Anirban
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Smriti, you can set the flag using context attribute and depending on flag value perform UI modification in wdDoModifyView.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.