473,745 Members | 2,100 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Question regarding dock property of datagrid

Hi all,

I am having problem at a time of using datagrid in c#.net.

On currentcell change event of datagrid i am displaying one combobox
and setting location of combobox depending on location of current cell
selected.

When i set dock property of datagrid to top it is working properly. But
when i check it to dock bottom it is not displaying combobox at proper
place.

So i don't know why this is happening. Is there anything i am missing.
I am posting code which i am writing on currentcellchan ged event :-

comboBox1.Width = 0 ;
comboBox1.Left = dataGrid1.GetCu rrentCellBounds ().Left ;
comboBox1.Top = dataGrid1.GetCu rrentCellBounds ().Top ;
comboBox1.Width = dataGrid1.GetCu rrentCellBounds ().Width ;
comboBox1.Heigh t = dataGrid1.GetCu rrentCellBounds ().Height ;

This code is working properly when dock style of datagrid is top but
not when dock style is bottom.

Can someone tell me why this is happening.

Any help will be truely aprpreciated.

Thanks in advnace.

Jan 24 '06 #1
0 1444

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

Similar topics

2
8074
by: James | last post by:
I have a forms application which has many controls such as buttons,labels,listviews,text boxes etc. If you set the window size to maximum size so that it would expand to the size of the screen the controls tend to move without any proposion. So then I used anchor and the dock property. I could get some or most of them to appear correctly, but say you have to list boxes in the middle of the screen one after the other vertically how could...
3
2991
by: Marcelo | last post by:
Hello, I am trying to create a postback event, and it is working, just not calling the sub. I have a datagrid which has <asp:DataGrid id="Mensajes" ... <Columns> <asp:HyperLinkColumn ....
12
1404
by: Joe | last post by:
Hello All: I'm sure that one of you can quickly spot the error in my script. I am using a small javascript function to retrieve the text of a hyperlink in a datagrid column. Here is my script: function parseHyperlinkId(o) { alert(o.text);
4
3639
by: jvb | last post by:
Hey all, I am using a floating toolbar control on a thick app i am writing and i am having a slight issue. When i set the datagrid on the form to a dock of TOP, then specify the toolbars to be docked on top, the toolbars are added beneath the grid as opposed to on top of it. When I execute do this same thing in C#, it works fine. Any suggestions? Is there a way to force the Toolbar to be docked first, then the datagrid?
3
1257
by: John Wright | last post by:
How can I set the property of a loaded Assembly using reflection. My Shell program will log in a person and retrieve a list of all programs the person can use. When the shell program launches a program I use the following code: Dim extAssembly As System.Reflection.Assembly = System.Reflection.Assembly.LoadFrom("D:\testload\TestLoad\TestLoad\bin\Debug\testload.exe") Dim extForm As Form = extAssembly.CreateInstance("TestLoad.form1",...
7
1105
by: Anil Gupte | last post by:
As in "Who am I?" or better "Who am Me?" When I use: Dim X0 As Integer = ActiveForm.Location.X Dim Y0 As Integer = ActiveForm.Location.Y Dim strTest As String = ActiveForm.Name Dim SIX0 = X0 + 560
2
2953
by: DBC User | last post by:
I am trying to dock a datagrid in a form and it does dock to fill but I want to extend all the columns I have to fit on the whole screen. But it is showing the columns and then leaving bunch of space empty and it look bad. Could someone help me?
3
3995
by: DBC User | last post by:
I am trying to put 2 controls in a page where I want the first control to have 80% of the screen and the second control 20%. How can I do that? I used control property to set the first one to Top and the second one to Bottom and is not working properly. I am loosing the first controls bottom portion. Any help please?
7
5225
by: Zytan | last post by:
I just wanted a little practice with the WebBrowser control, so I did the VB guided tour example here in C#: http://msdn2.microsoft.com/en-us/library/a08t4ke7(VS.80).aspx The tutorial asks to put a Panel with a Button and TextBox in it, and a WebBrowser below it. Then, it sets the Panel's Dock property to be Top. It sets the WebBroswer's Dock property to be Fill. But, the WebBrowser then fills the entire form! Even though the Panel's...
0
9486
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...
0
9214
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...
0
8219
agi2029
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...
1
6763
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
6057
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();...
0
4573
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...
0
4827
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
2759
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2195
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.