on 09-01-2009 7:45 AM
hi all,
I am implementing teh following code,i am getting resource exception.Can anybody advsie me what problem i am having.
Here i am trying to update km property file.
IWDClientUser wdClientUser = WDClientUser.getCurrentUser();
com.sap.security.api.IUser sapUser = wdClientUser.getSAPUser();
IUser ep5User = WPUMFactory.getUserFactory().getEP5User(sapUser);
IResourceContext context = new ResourceContext(ep5User);
RID rid1 = RID.getRID("/documents/MWRD/internet/portalActivity_9409950_1246005881870.txt");
IResource fileResource = ResourceFactory.getInstance().getResource(rid1, context);
IPropertyName propName = new PropertyName("_http://mwrd/xmlns/propertiesnamespace","DepartmentName");
IProperty mutableProperty = fileResource.getProperty(propName);
if(mutableProperty == null){
wdComponentAPI.getMessageManager().reportSuccess("null");
mutableProperty = new Property(propName,"Engineeringreports");
wdComponentAPI.getMessageManager().reportSuccess("null1");
fileResource.setProperty(mutableProperty);
}
Regards,
Anupama
Hi Anupama,
Change your namespace to http://sapportals.com/xmlns/cm instead of _http://mwrd/xmlns/propertiesnamespace and check
And tell us where exactly it is failing in the code..
For more reference go through this thread
/message/2909551#2909551 [original link is broken]
Regards,
Saleem
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
What is the exact exception message?
Do you have enough permissions on this file/dir? Is your application running with authentication set to true?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
101 | |
13 | |
13 | |
11 | |
11 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.