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

  • Home
  • SEARCH
  • 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 8476217
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T18:07:08+00:00 2026-06-10T18:07:08+00:00

This is my xml generated for retrieving members of a group. I need to

  • 0

This is my xml generated for retrieving members of a group. I need to get the value tech\abc1234 from this xml.

<tcm:Trustee xlink:href="tcm:0-61-65552" xlink:type="simple" xlink:title="tech\abc1234" Type="65552" Icon="T65552L0P0" xmlns:xlink="http://www.w3.org/1999/xlink"  xmlns:tcm="http://www.tridion.com/ContentManager/5.0"></tcm:Trustee>

But when i try to get the attribute value like:

XElement userList = csClient.GetListXml(grpId, members);

foreach (var eachuser in userList.Elements())
       {
            logdetails(eachuser.Attribute("xlink:title").Value.ToString());
       }

I am getting the following error :
error The ':' character, hexadecimal value 0x3A, cannot be included in a name.

  • 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-06-10T18:07:10+00:00Added an answer on June 10, 2026 at 6:07 pm

    Currently, you’re using the string to XName conversion, which takes that string as just the local ID of an element, and that can’t contain a colon.

    You need to create an XName with the full namespace + local ID. Fortunately, LINQ makes that really easy:

    XNamespace xlink = "http://www.w3.org/1999/xlink";
    XElement userList = csClient.GetListXml(grpId, members);
    
    foreach (var user in userList.Elements())
    {
        logdetails(user.Attribute(xlink + "title").Value);
    }
    

    Note that there’s no need to call ToString() after Value – XAttribute.Value already returns a string.

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

Sidebar

Related Questions

I've got an xml output self-generated from a cms (drupal) I need to work
I use xml to get label for my website. the xml generated from database
I have an xml file generated dynamically through a php code section.I need this
I have an XML generated at runtime. I need to embed this XML content
Hey i am unable to figure out why this xml is not being generated
I asked this question before: Generate XML from a class I want to do
I am trying to retrieve content from a dynamic XML generated in Perl proxy.
This is My Xml generated using xstream <Request> <MSISDN>9900624233</MSISDN> <TRANSID>123456</TRANSID> </Request> i want to
I have generated a XML file automatically from the below code. if (isset($_POST[song])&& $_POST['song']
I generated this xml file by marshalling it and then i want to unmarshall

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.