Archived Months
June 2003
July 2003
August 2003
September 2003
October 2003
November 2003
December 2003
January 2004
February 2004
March 2004
April 2004
May 2004
June 2004
July 2004
August 2004
September 2004
October 2004
November 2004
December 2004
January 2005
February 2005
March 2005
April 2005
May 2005
June 2005
July 2005
August 2005
September 2005
October 2005
November 2005
December 2005
January 2006
February 2006
March 2006
April 2006
May 2006
June 2006
July 2006
August 2006
September 2006
October 2006
November 2006
December 2006
January 2007
February 2007
March 2007
April 2007
May 2007
June 2007
July 2007
August 2007
September 2007
October 2007
November 2007
December 2007
January 2008
February 2008
March 2008
April 2008
all groups > asp.net datagrid control > september 2005

Filter by week: 1 2 3 4 5

DataGrid Won't come back
Posted by Tina at 9/29/2005 2:43:40 PM
(please ignore my earlier post - it apparently had nothing to do with it being in an ascx control) I have, dozens of times, displayed datagrids, datasourced by an .xsd dataset, with textboxes in template columns and always been able to spin through those grids on, say a button click event. ...more >>


AllowSorting = True, BUT Web DataGrid Wont Sort
Posted by tony010409020622 NO[at]SPAM spamthis NO[at]SPAM hotmail.com at 9/29/2005 10:25:44 AM
I'm obviously missing something, suggestions are welcomed. Thanks...more >>

Request: What property will be unique with every post?
Posted by Nathan Sokalski at 9/26/2005 11:28:48 PM
I am looking for a property of the System.Web.HttpRequest class that will always be different. Is there a property that uniquely identifies each Request (at least within the specific Session)? Thanks. -- Nathan Sokalski njsokalski@hotmail.com http://www.nathansokalski.com/ ...more >>

Disable checkbox when field value = null
Posted by SRuby at 9/26/2005 9:22:04 PM
Hi, I try to disable /hide datagrid checkbox when the value of the field is null, I have try to put some code in ItemDataBound to invisible the checkbox when databind() fired Here's the codein ItemDataBound event If e.Item.ItemType = ListItemType.Item Or e.Item.ItemType = ListIte...more >>

Going to a specific page?
Posted by gerry at 9/26/2005 7:44:44 AM
My client would like a alphabetic lookup bar to allow navigation to a specific page of a datagrid - the page which has the first occurance of the "key" field that starts with the clicked on letter. For example, if the user clicks on "E-H" the datagrid will present the page which contains the fir...more >>

Dynamically create datagrid columns
Posted by Terry Holland at 9/26/2005 12:00:00 AM
I am trying to write a user control that is essentially a DataGrid with some custom functionality. My grid is to be bound to a custom collection. I have created an interface called IListData. Part of this interface is a collection of DataGridColumn objects. I have code in my control to add a ...more >>

Checkbox Validation in DataGrid
Posted by arif.mosharraf NO[at]SPAM gmail.com at 9/24/2005 8:31:30 PM
Hi! I have a datagrid containing one checkbox in each row. I have to do a client side validation that atleast one checkbox is checked. I have tried to attach a javacript on the save button but javascript couldn't access the ID of the checkbox! If I throw an alert it says "undefined". It is no...more >>

Datagrid Header on All Printed Pages
Posted by Jay at 9/24/2005 12:00:00 AM
In an asp.net app I need to print a lengthy datagrid. How can this be done and still have the datagrid header appear on all printed pages? I am not using VStudio or Reportin Services.... just an asp.net app written in notepad. Thanks a lot. ...more >>



Datagrid In a webcontrol
Posted by CalSun at 9/22/2005 9:22:30 AM
I have a datagrid with Edit/Delete columns in a webcontrol. I load this control dynamically based on users' selection from a table dropdownlist. The control loads fine and the data is there. However, when I click on Edit to change the current column, the column doesn't change to Update/Cancel....more >>

Error when databinding
Posted by Nathan Sokalski at 9/22/2005 2:20:58 AM
When I run my application, which uses databinding in a DataList, I = recieve the following error: Server Error in '/' Application.=20 -------------------------------------------------------------------------= ------- Public member 'title' on type 'DataRowView' not found.=20 Description: An...more >>

Detect change to data in an ubound datagrid
Posted by Mark at 9/22/2005 12:00:00 AM
Hi Sorry if this is a bit obvious but I'm new to the datagrid ... :@) I have an unbound grid which contains a hidden column holding the primary key of the row. I would like to detect when the user has finished updating a record in order that I can update the source data. Can someone poi...more >>

Accessing the current DataRow of the DataSource from ItemDataBound
Posted by Nathan Sokalski at 9/21/2005 8:47:07 PM
I want to access the DataRow used in DataBinding from the ItemDataBound event. In my case, the reason for doing this is to determine whether I need to make a word singular or plural. How can I do this? Thanks. -- Nathan Sokalski njsokalski@hotmail.com http://www.nathansokalski.com/ ...more >>

DataGrid Pulldowns- how to access
Posted by Ken Webster at 9/21/2005 8:04:49 PM
Given a pulldown template like: <asp:TemplateColumn HeaderText="PO Line"> <ItemTemplate> <asp:Label id="TX_POLine" runat="server" BorderColor="#E0E0E0" BackColor="White" BorderStyle="Solid"></asp:Label> </ItemTemplate> <EditItemTemplate> <asp:DropDownL...more >>

rowcount
Posted by et at 9/21/2005 7:01:52 PM
How can I get a count of rows in a datagrid? ...more >>

Datagrid Edit event not firing in production
Posted by Ryan Rueckl at 9/21/2005 10:18:44 AM
In am using the datagrid's EditCommand event but rather than edit the row right in the datagtid, the event hides the grid and brings up some drop down lists so the user has to make a valid choice. I got everything working right on my workstation, but when I installed it on the production (CRM...more >>

Using two OleDbDataReaders at the same time
Posted by Nathan Sokalski at 9/20/2005 1:31:52 AM
I have two OleDbDataReaders that I need to use at the same time. One of the DataReadersis used inside a While loop. My code is as follows: While eventreader.Read() Response.Write(ControlChars.NewLine & CStr(eventreader("eventdate")).PadRight(20) & CStr(eventreader("eventname")).PadRight(...more >>

Need to manipulate a column before displaying
Posted by Paul D. Fox at 9/19/2005 11:00:18 AM
I am setting a datagrid's Datasource to a Dataset returned from a Web = Service. However, I need to manipulate one of the columns. The column = being returned is a relative URL, so I need to prefix the column's data = with the first part of the URL to make it an Absolute URL. How can I do = t...more >>

Extracting Data from Datagrid
Posted by Joel Zinn at 9/19/2005 9:15:23 AM
I have a developer that wants to dump data from a datagrid to an external file. I am thinking a .csv file for simplicity sake. I had thought about dumping the data from the dataset, but there is considerable morphing of the data that occurs in the databind portion of the code. I know there ...more >>

Datagrid: How do I allow edits but not new records?
Posted by PaulNaude at 9/19/2005 12:01:02 AM
I would like to allow editing of data displayed in a datagrid but not the adding of new records. How do you set it up?...more >>

Get updated values from DataGrid
Posted by Chris Mahoney at 9/19/2005 12:00:00 AM
Hi I have a DataGrid, with Edit links in each row. The Edit button works, the user can change the values. But I can't get updating to work. <asp:datagrid id="Content" runat="server" OnUpdateCommand="Content_Update" OnCancelCommand="Content_Cancel" OnEditCommand="Content_Edit"> <Column...more >>

File in use error
Posted by Nathan Sokalski at 9/18/2005 6:27:53 PM
I am recieving an error about not being able to use a file because it is already in use. Based on the error, I think it is referring to my DB, but I don't know how to avoid the error or why it is happening. Here is the error: Server Error in '/LVBEP' Application. ------------------------------...more >>

Pivot a datagrid?
Posted by et at 9/17/2005 7:56:53 AM
I seem to remember seeing an article on how to reverse the data in a grid, so that each record creates a column rather than a row? Does anyone know how to do this? Thanks for your help. ...more >>

Scroll grid With fixed header (It this posible?)
Posted by Ivan gil at 9/16/2005 12:00:00 AM
Hi, i explain my question... I have an ascx web user control this one have a datagrid whit some properties i had make a good datagrid user control for me. But now i have the last problem i was looking for a way to put scroll bars if my control width and height are lowers than the datagrid hei...more >>

Create ItemTemplates at runtime
Posted by Gordon at 9/15/2005 4:49:02 AM
Hi, Fairly new to ASP.net. I want to create a Datagrid that will bind to a DataSet created a runtime and which will hence have a variable number of columns. I want to show the data in binded textboxes. I can't create template columns in the designer because I don't know the number and colu...more >>

How to get the number of retrieved columns when doing a SQL Query
Posted by Roman Klimkowicz at 9/15/2005 12:00:00 AM
Hello everyone, i just implement an own search site in MS CRM 1.2, which searches in a MS-SQL database. My question is, how to get the number of retrieved columns by a SQL-query?? Any suggestions for me? Thx... Greets, Roman...more >>

How to the get to number of retrieved columns?
Posted by Roman Klimkowicz at 9/15/2005 12:00:00 AM
Hello everyone, i just implement an own search site in MS CRM 1.2, which searches in a MS-SQL database. My question is, how to get the number of retrieved columns by a SQL-query?? Any suggestions for me? Thx... Greets, Roman...more >>

Formatting String in Datagrid
Posted by xianxian at 9/14/2005 4:02:17 AM
Hi guys, does anyone know how to format strings this way:- i have 1 column(unit_num) in my Datagrid which displays eg. "01-123" i have to display only the floor level of the unit number, the first 2 digits(the number before the '-') how can i do this in the "Data Formatting Expression" of...more >>

How to add dynamic row in a grid
Posted by davef NO[at]SPAM helixpoint.com at 9/12/2005 9:25:07 AM
When I load the page, I need to add a row in the code behind? Dave ...more >>

HELP: Getting row column values in ASP.NET datagrid?
Posted by Usenet User at 9/9/2005 4:07:43 PM
I have a datagrid bound to a dataset table. Unfortunately, the table's primary key consists of not 1, but 3 columns, so I cannot correctly set the DataKeyField property of the grid (it only allows for 1 column), and, therefore, cannot use syntax like below in the event handlers in order to ret...more >>

Can I convet a query from an API into a Datasource to bind to?
Posted by Paul D. Fox at 9/9/2005 9:37:30 AM
I have some sample code that queries through a products API. I'd like = to convert this sample into a Datasource that I can bind to a Datagrid = (instead of using the Console.WriteLine), but not sure as to how. Can = anyone help? Here's the sample: For i =3D 0 To queryResults.GetRow...more >>

Sorting a date column
Posted by klj_mcsd NO[at]SPAM hotmail.com at 9/8/2005 1:08:31 PM
I'm trying to sort a date column but it keeps doing this: 09/08/2005 09/08/2004 09/09/2005 I think it is soorting is as a string instead of a date. How do I fix that? ...more >>

Linkbutton does not look like a linkbutton
Posted by Sathyaish at 9/8/2005 1:19:22 AM
OK, I almost got my problem solved. Zen is almost there! Just that a LinkButton control inside a column in my datagrid doesn't show like a link button. It does not have an underlining. My client side JavaScript is enabled. How do I make the button underlined and appear and act like a linkbutton?...more >>

Datagrid Template Column size control
Posted by Annie at 9/8/2005 12:00:00 AM
Hello guys, I have a datagrid with 2 Template columns. 1 colum which has all the data in the form of a HTML table and other which has an image control and shows the image there. I only show the detail of 1 item there. However, the height of the datagird is much bigger than I want it to be. ...more >>

about displaying data in datalist control
Posted by Yoshitha at 9/8/2005 12:00:00 AM
hi I have datalist control in my ASP.NET application the problem here is i have used a textbox with multiline true propertly when i enter data like "fdjsfhjksdhfjsdfhsdjhfsdfhsdjfhsd jfdsjfksdjfksdjkfjsdfjksdjfsdjfd fdsfhjsdhfjsdhfjf dsjf dsjfhjsdfhjksdh d fdsjf hsdjkfhdjsfhs...more >>

Controls inside EditTemplate cause editing to end
Posted by Nathan Sokalski at 9/7/2005 2:05:48 PM
I have a DataList control with an EditTemplate. Three of the controls in this template include a Calendar, a Button with CommandName="update", and a Button with CommandName="cancel". Whenever I click one of these controls, the DataList replaces the EditTemplate with the ItemTemplate. I think t...more >>

How to get a value from a grid
Posted by eagle at 9/7/2005 12:12:46 PM
without the e and without the source. I am loading a grid in the page_load, then I have to build another grid based on a value in that first grid, which is in column 5, control ??? How do I get that value. I've tried dg.columns(5).... dg.Items(5)..;. ...more >>

How to add client row click funciton on datagrid
Posted by bg at 9/7/2005 12:00:00 AM
is there anyone help me, i want to add rowclick javascrip function on asp.net datagrid what can i do this. bgun ...more >>

Update SQL table based on datagrid changes
Posted by Work at 9/7/2005 12:00:00 AM
Hello all, How would I update the SQL table based on the changes made to the data grid in vb.net. Any help would be greatly appreciated, Thanks, -A ...more >>

derive own controls from BoundField?
Posted by Martin Bischoff at 9/6/2005 11:57:01 PM
[this is question about the ASP.NET 2.0 details view control] When I add a row which is bound to a string field, the details view displays a single-line text box control in edit mode. Often, I would like to have a text area instead. I know that I can achieve this by converting the row to a ...more >>

Is it possible to acheive the following using a DataGrid in ASP.NE
Posted by Ben (Melb, Vic, Aus) at 9/6/2005 5:15:44 PM
I'm hoping that someone might be able to help me with the following challenge. The problems lies in the ability to display rows and columns of data on a datagrid conditionally. I have a list of rows in a data grid with one of the columns being a date. I have a hyperlink column for every ro...more >>

Declaring the name of a grid
Posted by eagle at 9/6/2005 9:51:55 AM
How can I declare the name of a grid, then use it to bind it to the datasource? I have 3 grids, each with different id's. dgOne, dgTwo, dgThree. I want to be able to do things to each grid. So I need to pass the name of the grid to the GetData procedure. What I have done so far: arrG...more >>

Cant reference cell text
Posted by Assimalyst at 9/5/2005 6:59:35 AM
Hi, I'm attempting an update SQl Server using a gatagrid using ADO. I am having trouble getting a changed value to work however. The datagrid is populated as below: sampleNo brush biopsy lavage histology patinetNo Edit 87 True True True Squamous ...more >>

Determining What Control Caused The PostBack
Posted by Nathan Sokalski at 9/5/2005 1:27:34 AM
I have a DataList that I was having trouble getting the events for. After a bit of help, I realized that I needed to put the databinding inside an If Not IsPostBack() condition. Although this fixed the individual problem, it caused problems in other areas. This is because the DataSource that I...more >>

Datagrid Footer!
Posted by Adam Knight at 9/5/2005 12:00:00 AM
Hi all, I am using a datagrid footer as a container for some data entry controls. Above the datagrid is another data entry point which needs to be filled out before prior to entering data in these controls. Q? How can i reference the controls in the datagrid footer so as ...more >>

Damnit, Jim. Where is my data?!
Posted by Scott M at 9/1/2005 2:32:07 AM
I am binding an array of objects to a datagrid and storing an internal ID in a hidden column in my datagrid for updating the database. All is well while I'm testing it out. But, as soon as I turn the column's visible property to "False" the data disappears!! I tried it with a template colum...more >>


DevelopmentNow Blog