CoCreate User Forum  

Go Back   CoCreate User Forum > Applications > Data Management

Reply
 
Thread Tools Search this Thread Rate Thread Display Modes
  #1  
Old 10-17-2014, 12:19 AM
alexniccoli alexniccoli is offline
Registered User
 
Join Date: Jul 2003
Location: pescia
Posts: 206
Programmatically change xml option

Hello
Is possible to change programmatically an xml option?
I mean during for example an action.I see that WMConfig class
hasn't set methods...
Alessandro
__________________
alessandro niccoli
pescia(PT)-italy
Reply With Quote
  #2  
Old 11-28-2014, 12:41 PM
parsi parsi is offline
Registered User
 
Join Date: Dec 2004
Posts: 5
Re: Programmatically change xml option

Yes, it is possible. but this require to start a distribution task that save the file back to the server.

a java example:
MMBuild build MMBuildUtil.getCurrentBuild();
Element options = build.getOptionsElement();
tree=new Element("Test");
options.addContent(tree);
build.addChangeDescription("Remember to click Distribute now!");
build.apply(true);
Reply With Quote
  #3  
Old 12-16-2014, 02:44 AM
alexniccoli alexniccoli is offline
Registered User
 
Join Date: Jul 2003
Location: pescia
Posts: 206
Re: Programmatically change xml option

I mean during execution,not changing xml files.
For example I'd like to change at run time
scan bom levels, but in some cases and not for all
users.
__________________
alessandro niccoli
pescia(PT)-italy
Reply With Quote
  #4  
Old 12-23-2014, 06:50 AM
parsi parsi is offline
Registered User
 
Join Date: Dec 2004
Posts: 5
Re: Programmatically change xml option

try something like:
List<Element> optionsAsElements =WMConfig.getInstance().getOptionsAsElements("MyOption");
optionsAsElements.get(0).setText("myValue");
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 03:43 AM.



Hosted by SureServer    Forums   Modeling FAQ   Macro Site   Vendor/Contractors   Software Resellers   CoCreate   Gallery   Home   Board Members   Regional User Groups  By-Laws  

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.