on 01-21-2009 7:14 AM
Hello,
I can't cange selection property of context to 0..n. Some other fields in property page of Context element are changeble but selection is set to 0..1 and does not allow to change.
Could you please help ?
Hi,
See to avoid this what you can do-> Suppose you have create a context node and you changed some of its property. Now creating the same type of node what you can do just copy the previous node and just paste it where you want to create same type of node.
This will minimize such type of error and wastage of time.
Regards
Narendra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
See to avoid this what you can do-> Suppose you have create a context node and you changed some of its property. Now creating the same type of node what you can do just copy the previous node and just paste it where you want to create same type of node.
This will minimize such type of error and wastage of time.
If I stay in Context of in View Editor, I copy and paste one of existing node of request with its subelements, response and result elements. I suppose this one new structure will automatically connected with coresponding webservice method ? How can I use it from logic of view ?
Is it enough to use lines below to call method of webservice, or I have to do additional initialization ?
wdContext.currentFilterCompany_2Element().setACompanyId("0008");
wdContext.currentFilterCompany_2Element().modelObject().execute();
Could you please suggest me some tutorial how to use technic copy/paste of context node ?
Hi Sergey,
Selection cardinality of a mapped node being fixed is ok. You are not supposed to change the selection cardinality of a mapped node. The mapped node will take the selection cardinality of the original node. So your context size becoming zero has nothing to do with the selection cardinality of the mapped node.
From your previous posts what I could understand is that you need to execute a webservice model, then make some changes and then re-execute the webservice model without affecting your original data. Correct me if I am wrong.
Once you execute a webservice model if you execute the same model again old data will be refreshed. If you don't want the old data to be refreshed then you need to have two instances of the webservice model.
I would suggest you to use separate controllers for that. One can be your component controller (can be mapped to the view and UI elements) second one can be a custom controller. (can be done in the component controller itself but will make things complecated.) Both the webservice models has to be initialized and executed separately.
Sanyev
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Strange but even after copy new context mapping has selection property 0..1 (((
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You need to change the selection property of both contexts(View as well as component controller). The properties must be same.
Please revert if you require more info.
Regards
Narendra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sergey,
Please check if you have done the mapping between this View Context element with component controller context etc.
You need to remove the mapping then you can change the selection property of context.Then again you can map it.
Hope this will help
Regards
Narendra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
When I create mapping I drug and drop context from right side to left side. Element node Result_bla_bla_bla under element node Response... became with selection property 0..1 but corresponding result element of model context has selection property 0..n. Is it bug ? I can't change this property when mapping exists, so in order to change it I must delete mapping. When mapping deleted I cant restore it because appears arrow pointed directly to model.
This is continue of problem started here
I want to use one method of webservice twice in diferent places of one application. In order to make it I applied template on Component controller from right click context menu. Now I try to make new context hiererchy like already existed in application but connected with new method of webservice (made using template above). I noticed that Result element of mapping has selection property 0..1 not like as in other existed mapping where 0..n.
I suspect that it is the reason of problem where in code I receive size of wdContext.nodeCompanyCheckResult().size() = 0
P.S. I can't debug application because it hungs server very often so I obliged use some absurd method to understang If code worked well
//@@begin javadoc:onActionCheckCompany(ServerEvent)
/** Declared validating event handler. */
//@@end
public void onActionCheckCompany(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
{
//@@begin onActionCheckCompany(ServerEvent)
requestCompanyCheck = wdContext.currentCompanyCheckElement();
sDebug = " onActionCheckCompany ";
requestCompanyCheck.setACompanyId(contextElement.getCompanyID());
companyComponent.executeCompanyCheck();
responseCompanyCheck = wdContext.currentCompanyCheckResponseElement();
resultCompanyCheck = wdContext.currentCompanyCheckResultElement();
if (responseCompanyCheck != null) {
sDebug += " responseCompanyCheck not null";
} else {
sDebug += " responseCompanyCheck null";
}
resultCompanyCheck = wdContext.currentCompanyCheckResultElement();
if (resultCompanyCheck != null) {
sDebug += " resultCompanyCheck not null";
} else {
sDebug += " resultCompanyCheck null";
}
sDebug += "size:" + wdContext.nodeCompanyCheckResult().size();
//sDebug = " company Id=" + resultCompanyCheck.getCompanyId();
contextElement.setSDebug(sDebug);
//@@end
}
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
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.