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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T15:09:03+00:00 2026-06-11T15:09:03+00:00

I am trying to add data to a row in a dataset but the

  • 0

I am trying to add data to a row in a dataset but the data is always on a new row?

I need the data to populate under its column. I need something like Ds.Tables[0].Rows[1].add("Item")

enter image description here

This is how i am inserting the data:

DataSet ds = new DataSet();
            ds.Tables.Add("Properties");
            //GPS
            ds.Tables[0].Columns.Add(ArrayProperties[0].FormMobiField);
            ds.Tables[0].Rows.Add(ArrayProperties[0].Value);
            //Street Num and Name
            ds.Tables[0].Columns.Add(ArrayProperties[3].FormMobiField);      
            ds.Tables[0].Rows.Add(ArrayProperties[3].Value);
            //Suburb
            ds.Tables[0].Columns.Add(ArrayProperties[6].FormMobiField);
            ds.Tables[0].Rows.Add(ArrayProperties[6].Value);
            //City
            ds.Tables[0].Columns.Add(ArrayProperties[7].FormMobiField);
            ds.Tables[0].Rows.Add(ArrayProperties[7].Value);
            //Province
            ds.Tables[0].Columns.Add(ArrayProperties[8].FormMobiField);
            ds.Tables[0].Rows.Add(ArrayProperties[8].Value);
            //Locality Map
            ds.Tables[0].Columns.Add(ArrayProperties[9].FormMobiField);
            ds.Tables[0].Rows.Add(ArrayProperties[9].Value);
            //Property Type
            ds.Tables[0].Columns.Add(ArrayProperties[10].FormMobiField);
            ds.Tables[0].Rows.Add(ArrayProperties[10].Value);
  • 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-11T15:09:04+00:00Added an answer on June 11, 2026 at 3:09 pm

    Just get a new Row from the DataTable and then add that row to the table, Use DataTable.NewRow method

    DataRow dr = ds.Tables[0].NewRow();
    dr["Column1"] = "value";
    dr["Column2"] = "value";
    dr["Column3"] = "value";
    
    ds.Tables[0].Rows.Add(dr);
    

    You are adding row after adding each column, You may first create your data table’s structure by adding all the columns and then you can get the new row using DataTable.NewRow() and later you can add that row to your data table. After adding all the columns you may also try:

    ds.Tables[0].Rows.Add(ArrayProperties[0].Value,ArrayProperties[1].Value,ArrayProperties[2].Value,ArrayProperties[3].Value);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to add a Row to my data.frame to spit out the average
I'm trying to add a new JDBC Data Source connect to hive in oracle
Im trying to add a div tag dynamically with some data attributes but the
I am trying to add data from a dataset to an access table(.mdb). I
I'm trying to get data from textbox but it says undefined id or something
I am trying to add/edit data into my JQGrid. Currently the first column is
I'm trying add data triggers to the default combobox style so each text item
I am using nhibernate and mvc3 in asp.net I'm trying to add data into
I am trying to add my data into multiple columns ListBox, I did it
I am trying to add Contact data in StructuredName with the following code. The

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.