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 8014737
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T20:02:02+00:00 2026-06-04T20:02:02+00:00

I have 400+ records of data in this format inside : <rs:data> <z:row ows_ID=’360′

  • 0

I have 400+ records of data in this format inside :

<rs:data>
   <z:row ows_ID='360' ows_LinkTitle='GEI Survey data to Sharepoint' ows_Project_x0020_Priority='0' ows_AssignedTo='615;#Jeremy, Ron' ows_Status='In Progress' ows_Priority='(2) Normal' ows_DueDate='2012-04-27 00:00:00' ows_PercentComplete='0.700000000000000' ows_Modified='2012-04-30 10:44:15' ows_Alignment='TSS Delivery Mgmt' ows_SME='44;#Lewis, Clark' />

   <z:row ows_ID='378' ows_LinkTitle='Create back end and environment to support User demographic reporting' ows_Project_x0020_Priority='0' ows_AssignedTo='615;#Sam, Johns' ows_Status='In Progress' ows_Priority='(2) Normal' ows_DueDate='2012-05-11 00:00:00' ows_PercentComplete='0.800000000000000' ows_Modified='2012-05-09 13:50:17' ows_Alignment='Team Internal' ows_SME='7;#CORP\sscer;#9;#CORP\vreer' />

   <z:row ows_ID='249' ows_LinkTitle='Training Material to Muti Media' ows_AssignedTo='620;#Jenkins, Kristen' ows_Status='Not Started' ows_Priority='(2) Normal' ows_DueDate='2012-08-10 00:00:00' ows_PercentComplete='0' ows_Modified='2012-05-16 11:20:29' ows_Alignment='Diver Support' ows_SME='1;#CORP\vsswer;#7;#CORP\adder' />

</rs:data>

how do I create indivisual array to store the values of ows_ID, ows_LinkTitle annd so on?

foreach (System.Xml.XmlNode node in activeItemData)

        {
            if (node.Name == "rs:data")
            {
                for (int i = 0; i < node.ChildNodes.Count; i++)
                {
                    if (node.ChildNodes[i].Name == "z:row")
                    {
                        string [] resultTitle;
     resultTitle = (node.ChildNodes[i].Attributes["ows_Title"].Value).ToArray();
                        Console.ReadLine(); 
                    } 
                } 
          } 
      }

Its throwing error Error Cannot implicitly convert type ‘char[]’ to ‘string[]’ at resultTitle. How do I correct it? Thanks.

I did

char[] resultTitle;
resultTitle = (node.ChildNodes[i].Attributes ["ows_Title"].Value).ToArray();
string s = new string(resultTitle);
Console.ReadLine();

how do I do it for all the values of [“ows_Title”]. ? Thanks.

  • 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-04T20:02:03+00:00Added an answer on June 4, 2026 at 8:02 pm

    This code

    char[] resultTitle;
    resultTitle = (node.ChildNodes[i].Attributes ["ows_Title"].Value).ToArray(); 
    string s = new string(resultTitle);
    Console.ReadLine();
    

    Takes a string value turns into a character array. ).ToArray() and then immediately converts the character array back into a string.

    This is the same thing without the extra memory allocation

    string s = node.ChildNodes[i].Attributes ["ows_Title"].Value;
    

    If I were you however I would just use linq to xml. I’d also want to end up with a List<string>

    XNamespace z = "#RowsetSchema";
    List<string> list = (from row in xdoc.Descendants(z + "row")
                         select (string)row.Attribute("ows_LinkTitle")
                        ).ToList();
    

    Complete sample

        static void Main(string[] args)
        {
            string xstring = @"<xml xmlns:rs='urn:schemas-microsoft-com:rowset'
                             xmlns:z='#RowsetSchema'>
                                <rs:data>
                                    <z:row ows_ID='360' ows_LinkTitle='GEI Survey data to Sharepoint' ows_Project_x0020_Priority='0' ows_AssignedTo='615;#Jeremy, Ron' ows_Status='In Progress' ows_Priority='(2) Normal' ows_DueDate='2012-04-27 00:00:00' ows_PercentComplete='0.700000000000000' ows_Modified='2012-04-30 10:44:15' ows_Alignment='TSS Delivery Mgmt' ows_SME='44;#Lewis, Clark' />
                                   <z:row ows_ID='378' ows_LinkTitle='Create back end and environment to support User demographic reporting' ows_Project_x0020_Priority='0' ows_AssignedTo='615;#Sam, Johns' ows_Status='In Progress' ows_Priority='(2) Normal' ows_DueDate='2012-05-11 00:00:00' ows_PercentComplete='0.800000000000000' ows_Modified='2012-05-09 13:50:17' ows_Alignment='Team Internal' ows_SME='7;#CORP\sscer;#9;#CORP\vreer' />
                                   <z:row ows_ID='249' ows_LinkTitle='Training Material to Muti Media' ows_AssignedTo='620;#Jenkins, Kristen' ows_Status='Not Started' ows_Priority='(2) Normal' ows_DueDate='2012-08-10 00:00:00' ows_PercentComplete='0' ows_Modified='2012-05-16 11:20:29' ows_Alignment='Diver Support' ows_SME='1;#CORP\vsswer;#7;#CORP\adder' />
                              </rs:data> 
                              </xml>";
    
    
    
            XDocument xdoc = XDocument.Parse(xstring); // there are other ways to construct your xdoc
            XNamespace z = "#RowsetSchema";
            List<string> list = (from row in xdoc.Descendants(z + "row")
                                select  (string)row.Attribute("ows_LinkTitle")
                                ).ToList();
    
            foreach (var item in list)
                Console.WriteLine(item);
    
        }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have like 400 records on my database, suppose this is the first version
I have an application with like 400 records in the database, I have splash
I have read this article about 400% boost of your website . This is
I have this running software that is currently being used by about 400 people.
I have the following jQuery: $(this).closest('div.mcoup').find('div.delcoup').slideToggle(400) .siblings().children('div.delcoup').slideUp(400); What I'm trying to do is get
I have an Oracle database (roughly 1.2 billion records) of data with a web
I have 400 records to process and they are in the following formats (string):
I have a table which contains around 400 000 records and which gets called
I have a data set of a 1m+ records. I need to output the
I have around 400 GB Live mysql Databases on one server and I like

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.