I have a datagrid, populated via a SQL dataset, and I want the user to select
a row by clicking on it and then using the value in the first cell as my key
for my next query. Using CurrentCellChan ged works unless I want the row which
has a cell selected and I click on that cell, obvious answer click another
cell in that row, but I have to code for stupid users!
I tried the click event but that didn't work, maybe I was doing something
wrong.
Can I open the datagrid with no cell selected?
TIA 2 1991
Graham,
Following the information on this site you should be able to find your
answer http://www.syncfusion.com/FAQ/WinForms/FAQ_c44c.asp
Did you know that there are special programlanguage newsgroups
microsoft.publi c.dotnet.langua ges.vb and csharp and vc
I hope this helps?
Cor
"Graham Y" <Gr*****@discus sions.microsoft .com> I have a datagrid, populated via a SQL dataset, and I want the user to select a row by clicking on it and then using the value in the first cell as my key for my next query. Using CurrentCellChan ged works unless I want the row which has a cell selected and I click on that cell, obvious answer click another cell in that row, but I have to code for stupid users! I tried the click event but that didn't work, maybe I was doing something wrong. Can I open the datagrid with no cell selected?
TIA
Thanks
I was looking for that, I used to use/support the Excel programing newsgroup.
GY
"Cor Ligthert" wrote: Graham,
Following the information on this site you should be able to find your answer http://www.syncfusion.com/FAQ/WinForms/FAQ_c44c.asp
Did you know that there are special programlanguage newsgroups microsoft.publi c.dotnet.langua ges.vb and csharp and vc
I hope this helps?
Cor
"Graham Y" <Gr*****@discus sions.microsoft .com>
I have a datagrid, populated via a SQL dataset, and I want the user to select a row by clicking on it and then using the value in the first cell as my key for my next query. Using CurrentCellChan ged works unless I want the row which has a cell selected and I click on that cell, obvious answer click another cell in that row, but I have to code for stupid users! I tried the click event but that didn't work, maybe I was doing something wrong. Can I open the datagrid with no cell selected?
TIA This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Dav |
last post by:
I have a Winform with a derived datagrid and a button that adds a row to the
datagrid in its Click event. The button has a shortcut text "&New Row".
When I enter a value in a datagrid cell and then mouse click the button
without tabbing out of the edited cell, everything is fine. If I hit Alt+N
instead after editing the cell, the cell values are reset to the previous
value of the cell before the button_click code is executed. I have...
|
by: Blake Versiga |
last post by:
When editing a datagrid (C#)
I need to know if the user changed the value of cell AND what the previous
value was.
Is this possible? If so how do I get the previous value or at least if the
cell has changed?
TIA
Blake
|
by: Jason |
last post by:
I've been trying to figure out a good way to do this but haven't had much
luck, any input would be greatly appreciated.
Basically, after a datagrid is sorted, how can I get the primary key value
of the item selected by the user? That is, not the datagrid index
'location' of the item the user selected, but the value inside a column of
this item the user clicked on.
I would use the CurrencyManager in a windows application but I'm not...
|
by: niceguy |
last post by:
Hi
I was wondering if its possible to get the exact displayed text from a cell
in a datagrid.
I need to get the displayed text and not any 'real' database value or
anything that the cell might contain in the background.
I've tried getting to get the text through the datagrid's control
|
by: gugu |
last post by:
Hi
I have a datagrid which has 20 rows and 20 columns, 15 of 20 columns
are checkboxs and their headertexts, datafields are dynamic. I need to
loop through the whole page to see if the specific check box cell is
checked or not. The code is as follows:
For rowindex = 0 To myDataGrid.Items.Count - 1
Dim item As DataGridItem = myDataGrid.Items.Item(rowindex)
For colindex = 0 To myDataGrid.Columns.Count - 1
| |
by: Graham Y |
last post by:
I have a datagrid, populated via a SQL dataset, and I want the user to select
a row by clicking on it and then using the value in the first cell as my key
for my next query. Using CurrentCellChanged works unless I want the row which
has a cell selected and I click on that cell, obvious answer click another
cell in that row, but I have to code for stupid users!
I tried the click event but that didn't work, maybe I was doing something
wrong....
|
by: Jeff |
last post by:
Help..
I have been using:
string sId =
((System.Web.UI.WebControls.TextBox)e.Item.Cells.Controls).Text;
To get the value of a cell in my datagrid.
When I set the cell to read only, I get an error message.
I need to retrieve this value so I can use it in my query to update the
|
by: Matt |
last post by:
I derived my own custom class from the datagrid class.
I overrode the ProcessCmdKey Function, like this, to catch the up and down
arrow keys:
======
Protected Overrides Function ProcessCmdKey(ByRef msg As Message, ByVal
keyData As Keys) As Boolean
Const WM_KEYDOWN As Integer = &H100
|
by: Greg |
last post by:
My problem is that values in the bool column of a datagrid are only
being updated to the database once the focus of the bool cell is lost.
This is completely counter-intuitative. When a user clicks on a bool
type cell in a datagrid and sees a check mark put in / removed, then
he/she would expect this to be reflected in the databsae immediately.
I've even overriden the paint, commit and edit methods of the bool
column class (which...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
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,...
| |
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...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
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,...
|
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...
|
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();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
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
| |