Problem with the use of colon (:)

Discussion in 'C Programming' started by KizilSakal, Aug 12, 2008.

  1. KizilSakal

    KizilSakal

    Joined:
    Aug 12, 2008
    Messages:
    2
    Hi everyone,
    I'm working on a project where we parse and create Xml messages with C language by making use of mxml libraries.I need to create an Xml file,and this Xml file contains nodes with various names.One of the nodes has the name "dm:note" or "rpid:activities",but I cannot declare such a node,compiler gives syntax error.I suppose the problem is related with the use of colon ':' but I have no idea about what to do.Actually my problem is a beginner-level one,I hope you can help me figure it out.

    Note:I attached the Xml file I'm trying to build to give you an idea.


    void createNewXML ()
    {

    /*Necessary node declarations*/

    mxml_node_t *xml;
    mxml_node_t *presence;
    mxml_node_t *tuple;
    mxml_node_t *status;
    mxml_node_t *basic;
    mxml_node_t *dm:person;
    mxml_node_t *rpid:activities;

    ....
    ....
    ....

    Attached Files:

    Last edited: Aug 12, 2008
    KizilSakal, Aug 12, 2008
    #1
    1. Advertising

  2. KizilSakal

    KizilSakal

    Joined:
    Aug 12, 2008
    Messages:
    2
    Ok I figured it out by myself,good thing for a beginner. = )

    I conditioned myself such that the variable's name must be rpid:activities.However we need the name of the node structure to be rpid:activities,which is a char type.So I declared my node as rpid_activities and set it's name as rpid:activities.

    Done! :veryprou:
    KizilSakal, Aug 12, 2008
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. KevinSimonson

    Use of Double Colon Operator

    KevinSimonson, Sep 9, 2009, in forum: C++
    Replies:
    2
    Views:
    721
    KevinSimonson
    Sep 15, 2009
  2. Xavier
    Replies:
    5
    Views:
    360
    Xavier
    May 17, 2004
  3. NuclearFusion

    Noob: use of the double colon

    NuclearFusion, Mar 26, 2006, in forum: Ruby
    Replies:
    12
    Views:
    167
    ara.t.howard@noaa.gov
    Mar 26, 2006
  4. robninja@gmail.com

    Use of Double-Colon ::

    robninja@gmail.com, May 9, 2007, in forum: Ruby
    Replies:
    6
    Views:
    172
    Bertram Scharpf
    May 10, 2007
  5. Mister Yu
    Replies:
    0
    Views:
    118
    Mister Yu
    Sep 30, 2007
Loading...

Share This Page