Solved

Need to remove a column being displayed in the datagrid.

Posted on 2008-06-25
2
219 Views
Last Modified: 2013-12-16
If you look at the image attached with the added in new list datagrid

I would first like to remove the GRADE_CODE_DTL_ID
and then rename GRADE_NAME to Grade Name
and then rename STRGHT_PRICE_AMT to Straight Price Amount
============================================================
System.Data.DataSet DataSetDelete = new System.Data.DataSet();
            System.Data.DataSet DataSetChange = new System.Data.DataSet();
            System.Data.DataSet DataSetAdded = new System.Data.DataSet();
            string Status = null;
            InitialPriceReporting.InitialPriceReportingServiceWS.InitialPriceReportingService WS = new InitialPriceReporting.InitialPriceReportingServiceWS.InitialPriceReportingService();

            DataSetAdded = WS.ComparePriceListAdded(previousID, dr["PRICE_LIST_HDR_ID"].ToString(), ref Status);

          AddedDataGridView.DataSource = DataSetAdded.Tables[0];

I call a webservice to return a dataset called DataSetAdded. How can I modify the names added in the datasetadded.



0
Comment
Question by:mathieu_cupryk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 16

Accepted Solution

by:
burakiewicz earned 500 total points
ID: 21868021
DataSetAdded.Tables[0].Columns.Remove("GRADE_CODE_DTL_ID ");
DataSetAdded.Tables[0].Columns["GRADE_NAME"].ColumnName = "Grade Name";
DataSetAdded.Tables[0].Columns["STRGHT_PRICE_AMT"].ColumnName = "Straight Price Amount";
0
 

Author Comment

by:mathieu_cupryk
ID: 21868412
smart guy!!!

Thanks.
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

756 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question