.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Not able to read all column in XML

Posted By:      Posted Date: September 09, 2010    Points: 0   Category :ASP.Net
Hi all, i have xml format as below.  but when i read through data set, some of the column, which ever specied as p2:type areare not binding with the grid, can any one suggest how to read those columns. i am reading xml as follows, XmlDocument dc = new XmlDocument(); DataSet ds = new DataSet(); StringReader strRdXml = new StringReader(dc.InnerXml); ds.ReadXml(strRdXml);     <element p2:type="MediaMarketResearch_PRODModel.GetSearchResultWithComplextype_Result" xmlns:p2="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">   <StudyTypeID p2:type="Edm.Int32">102</StudyTypeID>   <StudyTypeName>TV Spot</StudyTypeName>   <LocalTitle>127 Hours</LocalTitle>   <LocalTitle_30>127 Hours</LocalTitle_30>   <TitleReleaseID p2:type="Edm.Int32">14818</TitleReleaseID>   <WideReleaseDate p2:type="Edm.DateTime">2010-11-05T00:00:00</WideReleaseDate>   <StudyDate p2:type="Edm.DateTime">2010-08-27T07:50:46</StudyDate>   <StudyDateFT>08/27/2010</StudyDateFT>   <StudyID p2:type="Edm.Int32">106086</StudyID>   <StudyNumber>us10083032</StudyNumber>   <StudyName>127 HOURS</StudyName>  

View Complete Post

More Related Resource Links

DataGridView>Edit Columns> Column Read Only property is unwilling to change

Hello, I am facing the following mystery: When changing the read only property of a column to false and reopening the "edit columns" window, it mysteriously turns back to true. Even when closing the designer and changing it in the designer code, the resulting execution does not allow edit, as well as when re-opening the designer you see true again.             this.numberDataGridViewTextBoxColumn1.DataPropertyName = "Number";             this.numberDataGridViewTextBoxColumn1.HeaderText = "Number";             this.numberDataGridViewTextBoxColumn1.Name = "numberDataGridViewTextBoxColumn1";             this.numberDataGridViewTextBoxColumn1.ReadOnly = true;//False is required We thought it might be related to data binding. rebinding the grid did not help as well. The is no other place in the code where it changes. Please advice, Thanks

How to read a column of a sharepoint list to a text string field of infopath form?

My infopath form used to read these email addresses from a web service and web.config file. Now i would like to get these user email addresses from a contact list in a sharepoint server. I am trying to do this without writing any codes. Here is what i have done so far: 1. Adding a new "data connection to receive data from SharePoint library or List" where i selected Email Address column of the contact list. 2. I added a new Text Field and define a new rule with "Query using a data connection" defined above. When i try to access the newly created Text field above it always return empty as if the Query attached to it did not executed at all. What did i do wrong? Is there a better way? Thank you in advance for your help.

How to read a complete column from the dataset

I want to read complete column from the dataset using select command or whatever without looping the rows of the table.Because in table i got 35000 records i only want to read a one complete column from the top to the end using dataset.Eg: select column_name from table.lly, dataset.tables[0].select["Column='Product'"]I have tried with this but throwing exception.I was trying to get it but not able to find an answer.Please do the needful.Its very urgent.Suchitra.

read excel column value

Hi All,             i am uploading excel file data to database.Excel column value is combination of text and time,i need to extract only time.Each column will have different value. One column value is   _immediate 17:00 - 9:00 another column value is EMAIL 09:30 - 18:00,another column value is CKA 09:30 - 18:30 ans so on. i need to extract only time and store it 2 different variables like this. string Intime - 17:00 string OutTime - 9:00   Please send me code to acheive this task.            

Read Only Managed Metadata column in DataSheet View


i am unable to edit managed metadata columns in the DataSheetView, i have other columns which are number, text field type which i am able to edit. So the view is not readonly, it is only when i click cell with the managed metadata column i get the readyonly prompt.

Evironment : Sharepoint 2010, Office 2007 and a pissed off customer

Appreciate any help

I am what i am

on XML column


Hi all,

we have a XML column with an associated schema.

There are cases when opening the table we see "<Unable to read data>" in some rows. If we disable the schema and reopen the table, then we can see the XML values.

It's very strange, because if we paste the XML value in XMLSpy, we see it's well formed, and it acomplish the schema. And when the record is inserted, there's no message error, it looks the insertion is well-performed.



How to read value of Column under list using Sharepoint 2007



I am new to Sharepoint so please bear with me even if i ask for small clarifications.

I want to read the List using Powershell from Sharepoint Site.

Output i want to display is all columns that are under the Sharepoint List.


I have created a Sharepoint Web Application, Then i created the Sharepoint site Collection, then i created a new List named Employee List under Site Collection.

The Columns under that List are:

Empno,Empname and Salary.

I want to display the value of all the columns using the Powershell Script.

I am using the below Script.

 $list=$OpenWeb1.Lists["Employee List"]
 if($test -eq $null)
 Write-Host Site does not exist
 for($l=$listItemsTotal-1;$l -ge 0;$l--)
 Write-Host $listItems[$l].name

Internal error. Buffer provided to read column value is too small. Run DBCC CHECKDB to check for any



I'm using Asp.NET 4 to perform a simple query on database.
But when navigating to page that needs data (i'm using SqlDataSource) i receive this internal error.
I already ran DBCC without error and i still have the issue.

Windows 2003 Standard with latest updates 32-bit
Sql Server Standard 2005 SP4

The same query, executed from SSMS works fine.

Il saggio è quello che sa di non sapere

Tooltip for GridView Column Headers (ASP.Net)

I just wanted to add auto tooltips for my GridView headers. There are couple of ways but I don't want to use javascript and wanted to use simple 'title' attribute. It took couple of hours to get the working code supporting sortable columns. I thought it will be very useful for others. Here's the code and logic behind it.

Multiple Column Dropdownlist for the ASP.NET DataGrid

Based on my previous control "Multiple Column DropDownList for ASP.NET", I received many emails asking for the same control to be used in the DataGrid for web applications. Here we go.. This control can be used as the regular MS DropDownList in the DataGrid and also as a regular dropdownlist. It has all the properties, like DataTextField, DataValueField, DataSource, SelectedIndex etc. The download file contains the samples both in VB.NET and C#. In this sample, I have used the Northwind database of SQL Server.

Serial Port Communication Read and Write using C#.net

In this simple article you will learn that how you can Open and read COM port data using System.IO.Ports Namespace.
Simply just create New Project of windows application in C#.

Import ServiceProcess APIs
using System.IO.Ports

Imports System.IO.Ports

Write Parsing functions which parse port data according to attached device

Alternating row background for first column of a report


is there a way to make the first column of a report use the an alternating background color? 

I have the background color set for the entire row however it does not work for the first column if the color is set to an expression.  If I just set it to a color i.e. red it works just fine. If I insert a dummy column to the left it works just fine (but the dummy column does not work, presumably because it is first??).

In the file below only the textbox for part number does not show an alternating background.  All others work correctly.

                    <Textbox Name="PartNumber">

Use a column as parameter for a sds in another column; gridview


Hola, I have a gridview which is bound to a sds which returns 7 columns and I added two columns from the GUI.  What I want is to fill up the 9th column with DDLs and these  DDLS will get their data from a different sds which is using a stored procedure with a single parameter.  I created the 9th row, used template field, made the sds for 9th row, the stored_procedure, threw a DDL in Item template and all  I need now is to pass a parameter in the first column to the sds in the 9th column.  I can code this but i'm getting tired of aspx.cs :) and would like to do it from the GUI.

Scripts not read when in head tag


I just upgraded to VS2010 if that matters.  I'm learning JQuery and noticed that scripts don't work if they're in the head tag.  Also, I need the script tag with type="text/javascript" in the head (with nothing else) in order for the JQuery scripts in the body to work.

Very bizzare, any suggestions?

With a separate script tag in the <body> with my JQuery script, this works

<head runat="server">
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" />
<script type="text/javascript">

This doesn't:

<head runat="server">
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" />

Pass a grid column value to a Modal


Hi, I have a requirement to hide a field called details on a gridview and show it in a jQuery modal dialog when users click on the Customer ID hyperlink. This grid is created programmatically. I will be hiding the details column via the CSS display:none property. Does some one know how can I pass the grid's selected hidden column value to the modal? Here is some of the code I started:

            GridView mygrid = new GridView();
            //.....................................More columns code for the grid

            //Here is where I need to pass the Details column value associated with the customer ID field selected to the Modal and open the Modal dialog.            
            HyperLinkField linkField = new HyperLinkField();
            string[] dataNavigateUrlFields = { "CustomerID" };
            linkField.DataTextField = "CustomerID";

Bug: Does not change column type from nvarchar to ntext


Scenario: If you create a table with a column of type nvarchar, populate it with some content and try to modify it using the WebMatrix editor, from nvarchar to ntext, it does not display any error message or warning that this is not possible. It silently saves and reverts the change, back to nvarchar. Wasted some hours on this issue as I thought my column was ntext, but in fact was still nvarchar.

Expected behavior: It should change to ntext, or if SQL CE doesn't support that, it should notify the user that no change was applied.

Display column from child table. Possible ?



I'am using dnamic entity with EF4. On a list page of a table, I would like to display a column containing information from a child table of the current element. Sample :

Order List :

Order Data | Required Date | Shipped Date | etc... | ... | Customer Name (foreign key with tostring() method override) | Customer Postal Code (Column that I want to add) |

I don't known how to do that. Is it possible ? Maybe I have to to create my own Metadata proxy that will add dynamicly a column on the MetaColumn list of the table.

Does someone have an easier or better idea ?

Thank you for any help.

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend