Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6223585
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T08:30:55+00:00 2026-05-24T08:30:55+00:00

All of the examples I followed for tinyxml resulted in xml files that I

  • 0

All of the examples I followed for tinyxml resulted in xml files that I was able to view in Internet Explorer.

However, when I programmably created mine, nothing showed in IE. I can confirm however that the xml file has everything I expect it to have.

Here is the code to create the xml:

bool InputIO::saveDevice( const std::string & fileName, const InputDevice& device ) const
    {

        TiXmlDocument doc;
        TiXmlDeclaration* decl = new TiXmlDeclaration( "1.0", "", "" );  
        doc.LinkEndChild( decl );  
        TiXmlElement* root = new TiXmlElement("Input Devices");
        doc.LinkEndChild(root);
        TiXmlElement* dev = new TiXmlElement("Device");
        root->LinkEndChild(dev);
        dev->SetAttribute("number",1);
        for(int p = 0; p < 2; ++p)
        {
            for(int i = 0; i < NUM_KEYS; ++i)
            {
                //Primary configuration when p is 0
                InputKey key = device.getKey(InputEvent::Uniform_inputEnum(i),p == 0);

                TiXmlElement* button = new TiXmlElement("button");
                dev->LinkEndChild(button);
                button->SetAttribute("configuration",p);
                button->SetAttribute("number",i);
                button->SetAttribute("input type",key.inputType);
                button->SetAttribute("key code",key.keyCode);
                button->SetAttribute("joy axis",key.axis);
                button->SetAttribute("joy button",key.button);
                button->SetAttribute("joy stick",key.stick);

                if(key.positiveAxis)
                {
                    button->SetAttribute("axis direction","positive");
                }
                else
                {
                    button->SetAttribute("axis direction","negative");
                }
            }

        }
        doc.SaveFile(fileName.c_str());
        return true;
    }

And here is the resulting xml

<?xml version="1.0" ?>
<Input Devices>
    <Device number="1">
        <button configuration="0" number="0" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="1" input type="1" key code="216" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="2" input type="1" key code="84" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="3" input type="1" key code="85" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="4" input type="1" key code="82" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="5" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="6" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="7" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="8" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="9" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="10" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="11" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="12" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="13" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="14" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="15" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="16" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="17" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="18" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="19" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="0" number="20" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="0" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="1" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="2" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="3" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="4" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="5" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="6" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="7" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="8" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="9" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="10" input type="1" key code="83" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="11" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="12" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="13" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="14" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="15" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="16" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="17" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="18" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="19" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
        <button configuration="1" number="20" input type="0" key code="0" joy axis="0" joy button="0" joy stick="0" axis direction="positive" />
    </Device>
</Input Devices>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T08:30:55+00:00Added an answer on May 24, 2026 at 8:30 am

    The W3 XML Validator program tells us this about your XML:

    XML Parsing Error: not well-formed 
    Location: http://www.w3schools.com/xml/xml_validator.asp 
    Line Number 2, Column 15: <Input Devices>
                              --------------^
    

    At the end, you terminate Input Devices, but the space is what is wrong. After that, you have more problems with your XML. See here for how to make your XML well-formed.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to use CKEditor with DynamicData Web Site. The all examples that I
All examples are taken from the SICP Book: http://sicpinclojure.com/?q=sicp/1-3-3-procedures-general-methods This was motivated from the
Suppose we have abstract class A (all examples in C#) public abstract class A
I'm using opengl and trying to create a first person camera. All examples use
I am trying to find rectangle buttons with gloss effect. all examples are relevant
I've read through the Google Spreadsheets API PHP documentation. All examples are using Zend,
Is there any way to compute length of va_list ? All examples I saw
I'm trying to create plugins for Umbraco 5. I see in all examples mention
All the examples I've come across using Google Maps API seem to show a
All the examples I have seen where the PropertyPlaceHolderConfigurer is used seem to be

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.