473,659 Members | 2,662 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

add a button column to a datagrid

Sam
Hi,
I would like to add a column that contains a button in each row. The
problem is that the datagrid is bound to a datasource, and since the
button column is not part of my dataset, the program complains about
this.
How can I solve this problem ?

Thx

Nov 21 '05 #1
3 1834
Sam
ok i solved this problem... just need to add a dummy column to my
dataset

Nov 21 '05 #2
Sam
Actually it's not quite solved. My button only appears if the cell that
contains it is selected. Kinda like the property editor in Visual
Studio. How can I make the buttons being visible all the time ?

Nov 21 '05 #3
Have a look at
http://www.syncfusion.com/FAQ/Window...44c.aspx#q888q

--
HTH

Éric Moreau, MCSD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Concept S2i inc. (www.s2i.com)

"Sam" <sa************ **@voila.fr> wrote in message
news:11******** **************@ o13g2000cwo.goo glegroups.com.. .
Hi,
I would like to add a column that contains a button in each row. The
problem is that the datagrid is bound to a datasource, and since the
button column is not part of my dataset, the program complains about
this.
How can I solve this problem ?

Thx

Nov 21 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
1738
by: Chris | last post by:
I think I must be going crazy. All I want to do is add a button to the bottom of a datagrid which will later run some code for a web based project. I've created a custom control that inherits from the datagrid and have added just a single line of code thus; protected override void Render(HtmlTextWriter output) { output.Write(new System.Web.UI.WebControls.Button());
3
1913
by: JL | last post by:
Hi all, I created a datagrid for information display, the layout as following, Button column:sales_no Datatextfield: sales_no CommandName: sales_no How can i get the clicked cell of "button column" contained sales no value?
1
2570
by: Mark | last post by:
Hello, I have a need to add a button column to a datagtrid, below is my code and although it does not produce an error, it also does not work, any help? I'm hoping that I can capture the button click in the datagrid itemcommand event but figure having the button show first would be a good thing. I can get a hyperlink column to show with no problem but it causes the page to refresh which is what I'm trying to avoid. Thanks for any help....
3
2783
by: vcornjamb | last post by:
Hello, I am developing a web form that contains some buttons and a data grid which has as its last column link buttons that will delete the data associated with that row. Everything works fine, but users have requested a confirmation message pop up so the user can confirm the delete. I can not quite get this to work. Here are the facts: I am working in the Microsoft Development Environment 2003 (Version
2
2431
by: Bob Hollness | last post by:
Hi group. I am a newbie to ASP.NET as you will see from some of the questions I may ask! I have a datagrid which I have populated from a database. It works great! I have added a column, via the Columns dialog box from the properties of the datagrid, on the left that contains a select button. So now, when you press the button the whole row is highlighted. Now, what I want to do is have the user highlight as many rows as they wish...
1
3406
by: MattB | last post by:
I have a button column in a datagrid that is the delete button. Right now it is just a text link. When I go into the Property Builder My button choices are only LinkButton or PushButton. I'd like it to be an ImageButton so I tried converting the column to a Template Column. Then I edited the template to change the LinkButton to an ImageButton and replaced the text property with ans ImageURL property. The Datagrid looks how I wanted it...
2
1272
by: Chris | last post by:
I need to add a button column to my datagrid. I need to be able to do this at runtime. I can not have the tag <columns></columns> in my aspx page. This is where I am at Private Function CreateProjectDataSource(ByVal projectds As DataSet, ByVal dg As DataGrid) As ICollection Try Dim btn As System.Web.UI.WebControls.Button Dim dt As DataTable
5
2049
by: Tina | last post by:
the Edit, Update, Cancel, and Delete buttons in my datagrid are causing validation elsewhere on the page. I want to specify that these buttons should not cause validation but they have no design time property of causevalidation. How can I keep them from causing validation? Thanks, T
2
10038
by: pradeep_TP | last post by:
Hello world, I have a simple datagrid on asp.net web form , in which I am showing a single button column called EDIT. The code in the .aspx files for the same is as below. <asp:ButtonColumn HeaderText="" ButtonType="LinkButton" Text="Edit" CommandName="EditRec">
0
2029
by: herman404 | last post by:
Hi everyone, I'm trying to dynamically add 3 button columns to a DataGrid object that I have on an ASP.net webpage, but I don't see any documentation on how to do it. I've seen plenty of examples on how to add regular columns, but how do you declare a button column? My code is posted below, I have a placeholder on a webform, and the datagrid will be added on the placeholder once it is initalised. Thanks! System.Web.UI.WebControls.Label...
0
8330
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8850
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8523
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8626
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6178
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5649
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
2749
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1975
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1737
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.