Problem in creating several attributes XML with the same name of the attribute

I am trying without success trying to create several attributes XML with the same name, as shown here in a Microsoft example configuration file:



  
     
     
     
  

I'm calling the NewDocument GetRootElement functions and then "newelement" (appSetting), "newelement" (add)

Then I call AddAttribute with add, key & Key0, then with add, value & 0.  This seems to work fine but when I try to add the second pair of key & Key1 and value attributes & 1 for item "Add" replaces ""and I find myself with"" only.

I do something wrong or CVI is not able to create an XML of this type?

Thank you

Here's how you do it. I show not to keep things simple error checking.

#include

public static void CreateAddElement (mother of CVIXMLElement, const char * key, const char * value)
{
Add the CVIXMLElement;
CVIXMLNewElement (parent, -1, 'Add', &add);)
CVIXMLAddAttribute (add, "touch", key);
CVIXMLAddAttribute (add, "value", value);
CVIXMLDiscardElement (add);
}

void main (void)
{
CVIXMLElement root, and appSetting;
Doc CVIXMLDocument.
 
CVIXMLNewDocument ("configuration", &doc);)
CVIXMLGetRootElement(doc, &root);)
CVIXMLNewElement (root,-1, "appSetting", and appSetting);
CreateAddElement (appSetting, "Key0", "0");
CreateAddElement (appSetting, "Key1", "1");
CreateAddElement (appSetting, "Key2", "2");
CVIXMLDiscardElement (appSetting);
CVIXMLDiscardElement (root);
CVIXMLSaveDocument (doc, 1, "c:\\temp\\temp.xml");
CVIXMLDiscardDocument (doc);
}

Tags: NI Software

Similar Questions

  • Failed to save the system or create the image of the system, error: the problem occurred while trying to connect with the VSS writers (0 x 80042318).

    Original title: cannot backup Windows 7 system.

    When I try to back up the system or create the image of the system I get the following message, the error was detected in the Volumn Service VSS (Shadow Copy) the problem occurred while trying to connect with the VSS writers.  Verify that the event system Service and the VSS service are running and look for errors related to event logs. (0 x 80042318).

    Hi bernardolahoustino,

    Please keep us informed. Please let us know the State of the question, so that we can help you further.

  • Can FrameMaker to create several Master Pages with sizes different pages in a single file of FM?

    Can FrameMaker to create several Master Pages with sizes different pages in a single file of FM?

    N °

    You must break your content between files and use the book feature to apply numbering to make look it seamless. Sometimes, if you can, re - organize the content so that all oversize pages come at the end of a chapter/file makes it easier to manage a such split files in the book.

  • VRA unable to create groups of companies with the same name in different tenants with vRO

    vRA 6.2.2 Build - 2754020

    vRO 6.0.1

    Through the vRA GUI I can create groups of companies with the same names in different tenants as follows:

    Tenant1: BusGroup1, BusGroup2, BusGroup3

    Tenant2: BusGroup1, BusGroup2, BusGroup3


    However, to create business groups with the same names in different tenants via the vRO, specifically the workflow plugin Library / vCloud Automation Center / Administration / Business groups / create a group of companies, fails in the second tenant with the below error:


    [42106] the specified condition is not respected for 'name '. (Name of the dynamic Script Module: createBusinessGroup #12)

    If I change the naming convention to be different by tenant, then I have no problem. I thought it might be a restriction in the product, but as said I was able to create with the names of same origin through the user interface.

    Anyone experience the same thing?

    This is a known problem within IaaS API the plugin vRO uses to manage groups of companies through business groups workflows. You don't have the same problem of the vRA UI because the user interface (according to the 6.x) does not use the same API IaaS to manage groups of companies.

    The only alternative to 6.x for now is to directly use the helper generic entity Manager plug-in itself. You can take a look at the first example in example CRUD Infrastructure tasks management Scripts.

    I hope it helps.

    Sergio

  • I have a column with two values, separated by a space, in each line. How to create 2 new columns with the first value in a column, and the second value in another column?

    I have a column with two values, separated by a space, in each line. How do I create 2 new columns with the first value in one column and the second value in another column?

    Add two new columns after than the original with space separated values column.

    Select cell B1 and type (or copy and paste it here) the formula:

    = IF (Len (a1) > 0, LEFT (A1, FIND ("", A1) −1), ' ')

    shortcut for this is:

    B1 = if (Len (a1) > 0, LEFT (A1, FIND ("", A1) −1), ' ')

    C1 = if (Len (a1) > 0, Member SUBSTITUTE (A1, B1 & "", ""), "")

    or

    the formula of the C1 could also be:

    = IF (Len (a1) > 0, RIGHT (A1, LEN (A1) −FIND ("", A1)), "")

    Select cells B1 and C1, copy

    Select cells B1 at the end of the C column, paste

  • launch of checkers problems: error: trying to re-launch your game. If the problem persists, it may be network with the server problems or a problem with the configuration of your firewall.

    Windows Vista can not launch problem of checkers: try to re-launch your game. If the problem persists, it may be network with the server problems or a problem with the configuration of your firewall. Please check your firewall settings by visiting the Open Ports FAQ.

    Original title: launch of the problems of checkers:

    Hello

    If you have not yet tried to disable the antivirus/firewall software, then try the following steps to disable them.

    Disable the anti-virus software: http://windows.microsoft.com/en-US/windows-vista/Disable-antivirus-software

    Enable or disable Windows Firewall: http://windows.microsoft.com/en-US/windows-vista/Turn-Windows-Firewall-on-or-off

    IMPORTANT: Antivirus software can help protect your computer against viruses and other security threats. In most cases, you should not disable your antivirus software. If you do not disable temporarily to install other software, you must reactivate as soon as you are finished. If you are connected to the Internet or a network during the time that your antivirus software is disabled, your computer is vulnerable to attacks

  • When I'm accommodating the toolbar of the new option to arrange the icons on the toolbar toolbar change several tools come with the words "wrong tool" and have no icon associated with them. What are these missing tools 'bad '?

    When I'm accommodating the toolbar of the new option to arrange the icons on the toolbar toolbar change several tools come with the words "wrong tool" and have no icon associated with them. What are these missing tools 'bad '?

    I see you have fixed this now, but I was about to tell you that you could have accommodated in the 'Bad' by its shortcut "I" tool.

    To save a custom toolbar, get everything the way you want and click on the button space work, click new workspace

    Type a name for the workspace, and check all three options.

    If I have to use a single screen, I use a variant of the Essentials workspace with minor panels collapsed and dock for main panels.  I call this Essentials 2

    It also seems to me that with all these options, it's stupid not to take full advantage of them, so I separate my most used instruments for their own group and double column toolbar to adjust the screen.  I tried to drop in the groups for the most used tool near the document image (right). I love it, but it take some time remembering the new positions.

  • Create a local user with the vSphere Client

    Hello

    I want to create a new user with the permission of readonly. In the vmware documation salon, they say I have to go to the tab local users and groups, but there is no tab with that name.

    And sorry for my English I'm not a native speaker.

    Hi and welcome to communities,

    This tab is visible only when you connect to the ESXi directly with the vSphere Client. You won't see when you connect to a vCenter server.

  • I need to update the screenshots for a new version of an app existing Itune application to download a new version. Since I did not create the original version, can you guide me how to create a new version with the new version number?

    I need to update the screenshots for a new version of an existing iTunes Connect App asks me to download a new version. Since I did not create the original version, can you guide me how to create a new version with the new version number?

    You must call the assistance of the company and ask them to help you with this. You can find contact information by logging on http://digitalpublishing.acrobat.com/ and looking at the Middle at the bottom of the page.

    Neil

  • When I use dreamweaver cs6 browser Checker to find pages, it creates another page starting with the letter T. And he added this page to my folder. How can I prevent that from happening. I use a Mac.

    When I use Dreamweaver cs6 browser Checker to find pages, it creates another page starting with the letter T. And he added this page to my folder. How can I prevent that from happening. I use a Mac.

    Are you spotted with temporary files?  In Edition > Preferences > Preview in browser.

    Nancy O.

  • Question about several popular vm with the same kernel version

    So, I have been informed that ESX is smart enough for to run several virtual machines with the exact same kernel that it loads only one instance of the kernel in memory for all of them so that it saves space in RAM. This seems quite remarkable to me, and I'd like to see if VMWare has any white papers or other documents on this. I'd like to believe it's true, but it seems incredible to believe.

    Is this really how ESX functions? If I have 10 XP SP3 machines with the same level and exact same version of the kernel patch, VMWware won't really load only one instance of the core XP in RAM to separate the 10 machines? If he does that, how handles when 10 machines all want access to the same statement in kernel mode at the same time separate?

    Welcoem to the Forums - ESX will actually 10 instances of the core of the customer even if they are the same OS - but once loaded using Transparent Page Sharing the vmkernel (the o/s of the ESX Server) can recognize identical pages and store them a time-read only memory - if the virtual machine tries to write to that page a copy and writing is done - if this new page is another page in memory that one instance is maintained. This saves a TON of memory-

    If you find this or any other answer useful please consider awarding points marking the answer correct or useful

  • How to create several contours growing with every distance equal to the original form?

    outlines.png

    Here is a very simple example... It works with a circle or a square, obviously because he has the same height and width. The problem is when you have irregular shapes (or in this case, an oval). I know I've seen solutions to this in the past, but I can not just think how Word of this question and find them.

    I know that you can create several shots of an object in the appearance palette, but I'm looking for something more effective than simply STROKE color > white line > race color > white race > etc.

    Some examples of the kind of effect I'm looking for.

    FRSH-SLCTS-Captain-Murphy-DUALITY-494x494.jpg

    captain-murphy.jpg

    Any help would be greatly appreciated.

    You must use the path of the Offset. Object > path > offset path. Use negative numbers to go inside a form existing, positive to go outside.

    [signature removed by the host of the forum - advertising is prohibited]

  • Demarshalling xml with the automatically generated class JAXB2.0 file does not work in jdeveloper 11.1.1.9

    I'm trying to familiarize themselves with JAXB in jdeveloper. I am facing some problems. There are a few test cases for which he works, for others it is not.

    Case 1:

    XML file is created manually. Respective java class to xmlelements is created manually. There is no ObjectFactory.java or jaxb.properties. Demarshalling this XML file works fine.

    Case 2:

    XML file is not created manually. All the respective java classes including ObjectFactory.java and jaxb.properties are generated using the widget ' JAXB 2.0 content XML Schema model "jdeveloper. I deleted ObjectFactory.java, jaxb.properties, and package - info.java. Demarshalling xml with this class file works fine.


    Case 3:

    Even in case 2, but this time I do not delete or change whatever it is generated and used as it is. It does not work. Get the following error.

    Picked up _JAVA_OPTIONS: -Dawt.useSystemAAFontSettings=on -Dswing.aatext=true
    javax.xml.bind.UnmarshalException
     - with linked exception:
    [Exception [EclipseLink-25008] (Eclipse Persistence Services - 2.3.1.v20111018-r10243): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: A descriptor with default root element rss was not found in the project]
      at org.eclipse.persistence.jaxb.JAXBUnmarshaller.handleXMLMarshalException(JAXBUnmarshaller.java:816)
      at org.eclipse.persistence.jaxb.JAXBUnmarshaller.unmarshal(JAXBUnmarshaller.java:109)
      at com.example.jaxbintro.JAXBExampleClass.main(JAXBExampleClass.java:36)
    Caused by: Exception [EclipseLink-25008] (Eclipse Persistence Services - 2.3.1.v20111018-r10243): org.eclipse.persistence.exceptions.XMLMarshalException
    Exception Description: A descriptor with default root element rss was not found in the project
      at org.eclipse.persistence.exceptions.XMLMarshalException.noDescriptorWithMatchingRootElement(XMLMarshalException.java:129)
      at org.eclipse.persistence.internal.oxm.record.SAXUnmarshallerHandler.startElement(SAXUnmarshallerHandler.java:208)
      at oracle.xml.parser.v2.NonValidatingParser.parseElement(NonValidatingParser.java:1598)
      at oracle.xml.parser.v2.NonValidatingParser.parseRootElement(NonValidatingParser.java:455)
      at oracle.xml.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:401)
      at oracle.xml.parser.v2.XMLParser.parse(XMLParser.java:239)
      at org.eclipse.persistence.internal.oxm.record.XMLReader.parse(XMLReader.java:157)
      at org.eclipse.persistence.internal.oxm.record.SAXUnmarshaller.unmarshal(SAXUnmarshaller.java:688)
      at org.eclipse.persistence.internal.oxm.record.SAXUnmarshaller.unmarshal(SAXUnmarshaller.java:271)
      at org.eclipse.persistence.internal.oxm.record.SAXUnmarshaller.unmarshal(SAXUnmarshaller.java:258)
      at org.eclipse.persistence.internal.oxm.record.SAXUnmarshaller.unmarshal(SAXUnmarshaller.java:218)
      at org.eclipse.persistence.oxm.XMLUnmarshaller.unmarshal(XMLUnmarshaller.java:306)
      at org.eclipse.persistence.jaxb.JAXBUnmarshaller.unmarshal(JAXBUnmarshaller.java:106)
      ... 1 more
    

    The project is included in the annex to this issue. It is ready for use. More information in the commentary to the java code. The main class is JAXBExampleClass.java.

    What is the problem with case 3?

    OK, I've been messing around with codes generated a bit and found the solution. The problem is that the value of the XmlSchema namespace had error in package - info.java class. There is no specified XmlSchema namespace in the XML file. Thus, the given value in the package - info.java was wrong.

    @javax.xml.bind.annotation.XmlSchema (namespace = "http://www.example.org", value / / wrong, set it to an empty string or that of your xml file, if it has any)

    elementFormDefault =

    javax.xml.bind.annotation.XmlNsForm.QUALIFIED)

    package com.example.jaxbintro.xmlerror;

    After you set the namespace to the empty string, since my xml file do not have one, code ran very well.

    @javax.xml.bind.annotation.XmlSchema (namespace = "",)

    elementFormDefault =

    javax.xml.bind.annotation.XmlNsForm.QUALIFIED)

    package com.example.jaxbintro.xmlerror;

    The file package - info.java can also be removed and it will work. For more details on the package and XmlSchema annotated level, what information on the package class is for, be found in the following link.

    https://JAXB.Java.NET/NoNAV/jaxb20-FCS/docs/API/javax/xml/bind/annotation/XmlSchema.html

  • Satellite U400 cannot create DVDs of recovery with the recovery disk creator

    Hello

    I have a Satellite U400 (a few years), and I never created the recovery DVDs.
    Now I want to do, but for some reason, when I run creator of Toshiba Recovery disk, nothing happens...
    The partition containing the files of recovery is there, as well as the folder HDDRecovery. I have add a few files on this partition, this could be the problem?

    Thanks for your help.

    > I have some files on this partition, this could be the problem?
    N ° if you didn t change the partition structure should not be the problem.

    It is: does this Toshiba recovery disc creator market or not? If you can not star this tool has nothing to do with the recovery files.
    You will find this file - C:\Program Toshiba Toshiba Recovery Disc Creator\TRORDCLauncher.exe?

  • Printer problems. Error "computer cannot communicate with the printer.

    I had problems to access Windows Explorer and the rep Dell IT installed Mozilla Firefox 4.0 Beta 10 for my Windows Vista as an alternative.  Now my Dell AIO 946 printer does not work.  Whenever it is fixed, it prints until I am notified to download an upgrade of the system.  After that I downloaded the upgrade, the printer does not work yet.  The ink cartridges will not align.  I get a message of "remove stickers ink", which is clearly not the problem because the cartridges are not new.  Now, I get a message that says "computer cannot communicate with the printer.  I re-installed the printer several times, disconnected from the power source and the URL and re-connected.  Nothing seems to work.  Any positive advice will be appreciated.

    grandmainontario,

    You can copy a document under the glass? B & W and color?

    If so, executing delete print jobs to remove items stuck print jobs in the queue.

    Unplug the printer.

    Download and run the patch (cleaning printer utility) until it prompts you to restart your computer.

    Restart your computer.

    Download the Vista drivers.

    Install the Vista drivers. You will get a message, the printer is not connected. Connect the printer at the moment (power on)

    You will find links to the patch/drivers to...

    Reference Dell 946 Photo all-in-One Printer owners thread (W7)

    Also try this tweak...

    Go into Device Manager (right click on my computer, left click Properties, material of the left click, left click Device Manager)

    Go to the section USB controller, and then click the plus sign +.

    Go to each USB hub root and right-click on it, on the left, click Properties, on the left, click power management. Uncheck the allow the computer to turn off this device to save power.

    Restart your computer.

    You can also read...

    You cannot print or preview before printing a Web page in Internet Explorer 9

    Rick

Maybe you are looking for