Hi, All,
The datagridview auto-select first column first row data and the slected
cell background color is blue, so how to turn off the select? or how to
change selected cell backcolor to white?
Thanks 2 9423
Hi,
Try this
DataGridView1.D ataSource = bsOrderDetails
DataGridView1.I tem(0, 0).Selected = False
Ken
-----------------------
"martin1" <ma*****@discus sions.microsoft .comwrote in message
news:BA******** *************** ***********@mic rosoft.com...
Hi, All,
The datagridview auto-select first column first row data and the slected
cell background color is blue, so how to turn off the select? or how to
change selected cell backcolor to white?
Thanks
Thank you, Ken,
yes it is turn off first column first row selection, but when click it, it
is re-selected, so how to set up dataGridView selection false so that user
cannot select since the app start?
"Ken Tucker [MVP]" wrote:
Hi,
Try this
DataGridView1.D ataSource = bsOrderDetails
DataGridView1.I tem(0, 0).Selected = False
Ken
-----------------------
"martin1" <ma*****@discus sions.microsoft .comwrote in message
news:BA******** *************** ***********@mic rosoft.com...
Hi, All,
The datagridview auto-select first column first row data and the slected
cell background color is blue, so how to turn off the select? or how to
change selected cell backcolor to white?
Thanks
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Steve |
last post by:
I am looking for an example of a custom user control ( 2 labels and 2
datetime pickers ) in a datagridview cell. Every example I have come across
handles only once control such as a datetimepicker or a value list, etc. Can
anyone point me in the right direction? Thanks!
|
by: dgk |
last post by:
Is there a way to change the foreground or background color of a
single cell in an unbound datagridview?
|
by: Rich |
last post by:
Hello,
If I want to update data displayed in a datagrideview/datagridview cell, how
can I determine what cell I am updating? I am looking at the click event
below, for example. Can I get information from the sender object or the
EventArgs? How?
Private Sub DataGridView1_Click(ByVal sender As Object, ByVal e As
System.EventArgs) Handles DataGridView1.Click
Console.WriteLine("row number of cell is ?")
|
by: steve |
last post by:
Hi All
I would like to be able to change the cell borders on certain cells to none
at runtime to make a group of cells appear to be merged
I have tried the following in the cellformatting event..., to no avail
Any ideas
Regards
|
by: galletg |
last post by:
please; how to write by code in a datagrid view cell a text in a textbox.
thank you for your help.
georges gallet
| |
by: cj |
last post by:
When viewing a datatable in a datagridview one of the columns in it is a
"note" field which can be quite long. I would like to have the note
field of the currently selected row of the datagrid display in a textbox
below the datgridview. I currently have it fixed so if you click on a
row the note field from that row is put in the textbox. I'd like this
to be automatic as they move through rows.
Also the note field is one of two fields...
|
by: varunk2 |
last post by:
Hi
How to autocomplete a datagridview cell in c# windows forms.
Please anybody help me...
Thanks in advance
Regards,
|
by: hydro123 |
last post by:
I am using VC++2008 and am trying to read data enetered in unbound datagridview to implement in function. Under button_click event I entered the following:
// initialize varaibles from dataGridView
double C1;
double INF1;
double T1;
//Read String values from each dataGridView Cell
String^C1s = safe_cast<String^>(dataGridView1->Value);
String^INF1s = safe_cast<String^>(dataGridView1->Value);
|
by: ziketo |
last post by:
Hi,
I searched a lot about changing the DataGridView cell borders. BYTES helped me so I will write down the solution:
1. You should override the class DataGridViewTextBoxCell, and the new class should have a property of type DataGridViewAdvancedBorderStyle, this property you will change from the outside:
2. You will override also the PaintBorder, and Paint methods in a way that they will get the new property instead of the default one....
|
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: 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...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
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: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
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
| |