Groups | Blog | Home


Archived Months
November 2003
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
May 2008
June 2008


all groups > dotnet windows forms controls > july 2007

Filter by week: 1 2 3 4 5

Need help in Rich text box control
Posted by Tushar at 7/31/2007 12:00:00 AM
Hello, I am placing few controls in Rich text box, Like normal text box, picture box etc. But when i am savgin the content of rich text box....it is onlt stroing the text which i have wriiten into it. It is not saving the tex of the control whih are placed inside it. it is not saving the ...more >>

Datagridview readonly property changes the readonly property of its columns?
Posted by roland de meester at 7/30/2007 6:11:38 PM
I noticed some strange behaviour of the datagridview: toggling the readonly property of the datagridview impacts the readonly property of its columns. This is not according to the documentation as I found it in MSDN. You can reproduce this behaviour as follows: Create a form with a datagridvi...more >>

Seeking advice for DataGridView with several Unbound Columns
Posted by Joseph Geretz at 7/30/2007 5:32:21 PM
Hi, I'm looking for advice or samples regarding the implementation of what is essentially a bound grid, most columns are bound, however there are a couple of unbound columns which are basically calculated totals (read-only) of data in the bound columns (which are read/write). I've implem...more >>

Set Default Values in DataGridView - Repost
Posted by JD at 7/30/2007 10:36:22 AM
This is a re-post, I have not found anything that works - yet. I would like to set the default value of a dataviewgrid column (I have combobox columns and checkbox columns) to the previous value in the row above, I don't want all column values set to a default value. The value would stay th...more >>

Lightweight visual control
Posted by Mike D Sutton at 7/29/2007 7:44:49 PM
I'm developing some simple user-drawn graphical controls and looking for the most efficient way of going about it. Initially I had the default VS control project which derrived from 'UserControl' with all it's baggage. Having a look up the inheritance tree it looks to me that this is designed to...more >>

How to determine the active form
Posted by John Brown at 7/26/2007 9:32:05 PM
Hi there, Does anyone know how to (generically) determine the currently active = form for an application using a "static" function (so I can call it from = anywhere). There is no offiical way I've been able to find so I've = written the following for starters: public static Form GetActiveFo...more >>

DataGridView pencil and row editing
Posted by imran.a at 7/26/2007 1:36:03 AM
Hi, The datagridview control is rather confusing when it comes to editing rows. I have a datagridview control bound to a dataset (exposed through a bindingsource). The edit mode is set to edit on key stroke. The problem is that when you begin editing a cell for a given row the pencil glyph wi...more >>

remove row in datagridview
Posted by Pascal Cloup at 7/26/2007 12:00:00 AM
Hello, How to remove a Row in a DataGridView? My DataGridView is readonly and there is no binding (Cells are build programmaticaly). I tried the following myDataGRidView.Rows.RemoveAt( rowIndex ) and myDataGRidView.Rows.Remove( row ) but an exception is always generated: "Impossible de...more >>



Cell.ErrorText combined with e.cancel during validation of a cell in a Datagridview
Posted by Patrik at 7/24/2007 4:26:48 PM
Hi, I have a datagridview where I perform cell validation. I do not want the user to be able to leave edit mode if the value is incorrect. The reason is that i use CellEndEdit to write the value to my hardware. I validate the value and set the cancel flag if the value is invalid. The proble...more >>

cross thread operation and invoke
Posted by at 7/24/2007 3:59:01 PM
there is a line of code Form.VisibleChanged += Form.Invoke(new EventHandler(abc)); it says that right hand side returns an object and left side expects System.eventhandler and if i remove the invoke line while running i get the exception that cross thread operation is invalid how do i hand...more >>

DataGridView with a TabPage Lossing Formating Detail
Posted by CraigDevel at 7/24/2007 10:18:05 AM
Hello All, I am have a strange problem. I have an application which creates a set of TabPages with DataGridViews in it. The data is binding fine but I am losing all of the formating I have added to the DataGridView. Below is a snipit of the code I am using to generate the tabpages. Also...more >>

Dataviewgrid column or cell default value
Posted by JD at 7/23/2007 4:02:09 PM
I would like to set the default value of a dataviewgrid column (or cell) to the previous value in the row above. I could do it in 2003. How would I do it in 2005 VB? Here is the code I used in 2003: Private Sub dtFishData_tblFishDataRowChanged(ByVal sender As Object, ByVal e As DsFishSurve...more >>

Windows Form PropertyGrid dropdown value
Posted by moni at 7/23/2007 7:07:31 AM
Hi, I am trying to use, public class FileNameConverter : StringConverter for creating a dropdown list within my dynamic property grid. Thus I have the methods GetStandardValuesSupported, GetStandardValues, and GetStandardValuesExclusive. My problem is , that my GetStandardValues, needs to g...more >>

WebBrowser control & ActiveX security popup message
Posted by Bart at 7/20/2007 1:28:44 PM
Hi In our application we load HTML content into a Forms.WebBrowser control. The HTML page contains an ActiveX control. When the page loads the browser pops up a message stating "An ActiveX control on this page might be unsafe.." etc. This message should be suppressed! I guess I somehow have t...more >>

DatagridViewTextBoxEditingControl Autocomplete
Posted by JT at 7/19/2007 12:14:02 PM
Hi, I would like to be able to use the autocomplete capabilities of the 2.0 textbox in a datagridviewtextboxcolumn. Is there a way to do this without creating a custom datagridview column control and celltype? If not, what would I have to override in the base classes to get this limited f...more >>

Return a TypeConverter for a PropertyGrid value
Posted by moni at 7/18/2007 8:32:34 PM
PropertyDescriptor Class has a Converter method, which if overriden, would return a TypeConverter. I was working on dynamic values for a propertygrid, so for each property all the methods of the PropertyDescriptor class were overridden. But for a dropdown list I needed the COnverter method al...more >>

Making a TAB in a Tabcontrol Highlight programatically
Posted by Bob at 7/18/2007 12:00:00 AM
Hi All, I would like to make the Tab of a Tabcontrol highlight .. similar to what happens when the Hotrack property is set and the user runs the mouse over it. Although I'd like the Tab to flash ... or any way of changing the look/color/highlight of the Tab that will catch attention. Es...more >>

gradient panel with shadow effect
Posted by at 7/18/2007 12:00:00 AM
create cool gradient panel with shadow effect. try this link. http://www.openwinforms.com/creating_cool_gradient_panel_gdi.html sa@openwinforms.com http://www.openwinforms.com/ ...more >>

PropertyGrid Discard values
Posted by moni at 7/16/2007 4:16:27 PM
Hi, I changed the text field bcoz of which the PropertyValueChanged event fired up. But I wanted to get back the old value of a text in a property grid, after clicking on a discard button. I already have stored the attribute and the old value in variables. What would I need to do, in orde...more >>

How to change colour of TextBox border
Posted by Notre Poubelle at 7/16/2007 10:08:01 AM
Hello, I'm trying to figure out how to change the border colour of the TextBox control. I can't find a property that does this. I've researched this but couldn't find a complete sample of anyone achieving this. For the Textbox control, the overriden OnPaint method is not called unless ...more >>

Stretching images in .net 2003
Posted by Aviinaash S at 7/16/2007 12:00:00 AM
i am creating a windows form in .net 2003 and using a background picture for the form, the form height is 400 and width is 600,but the image is 1024*768 so the background looks clipped. Is there any way to stretch the image to 600*400 from 1024*768 and use it in the form. i am using .net 2003 ...more >>

listbox and cancel default action on key events
Posted by jmzl666 at 7/13/2007 7:39:22 PM
Hi all, i have a listbox, i want that when an user press Ctrl+C copy the selecteditem object to the clipboard, I'm already doing this, the problem is that when the user press the C key the selecteditem change to next element that begins with the letter 'C', and i want to avoid that. Thanks in a...more >>

Displaying formatted text in a DataGridView
Posted by Craig Banks at 7/12/2007 10:41:17 AM
We've all seen search engines where keywords from the query are bolded in the search results. I'm trying to replicated that in a DataGridView. However, it only supports plain text. Is there any easy way to accomplish this? I did run into some stuff on the web about converting RTF to a BMP bu...more >>

Populate the PropertyGrid dynamically
Posted by moni at 7/11/2007 6:36:19 PM
Hi, I wanted to populate the property grid after getting a set of keys and values from the server onto a hashtable. Basically the name of the property should be the key and the value should be the value. But I dont know how I would iterate through a while loop, to get to do something like t...more >>

TableAdaptor.Fill action
Posted by Arlyn_L at 7/11/2007 5:08:01 PM
Is there a way to determine when a TableAdaptor.Fill(DataSet.Table) method has completed? I have a large database and I would like to inhibit display of the mainForm untill the Fill method completes. Regards; -- Arlyn_L...more >>

Urgent Question: Cannot change property values on control
Posted by fadi at 7/10/2007 1:18:19 PM
Hey guys, we have created a control and added a Toolstrip to it. Everything worked fine and we could access the toolbar buttons fine until we moved the toolstrip onto a Tab control's TabPage. Now the toolstrip buttons visible property are always returning visible = False and we cannot chang...more >>

WebBrowser control
Posted by Nutan at 7/10/2007 12:00:00 AM
Hello, I am facing two problems with WebBrowser control in C#: 1. How to add HTMLElement to WebBrowser.Document.Body at current mouse location. 2. How to avoid/disable alert message when changing DocumentText property of WebBrowser? Alert Mesage that i am getting goes something lik...more >>

Column will not consistently hide in DataGridView when on a TabPage. Bug?
Posted by dbuchanan at 7/7/2007 6:19:43 PM
Hello, I have serveral DataGridViews on several different TabPages on my Windows form. I have set the 'visible' property of the primary key columns to 'false' in the Edit Columns dialog box. In design-time the primary key column is hidden, but in run-time the column is shown. In one of t...more >>

Active TabControl tabPage name
Posted by dbuchanan at 7/7/2007 12:09:56 AM
Hello, How can I get the name of the tabPage that is selected? (C#) I want to have a switch statement control which code is run. Something like this. private void btnSave_Click(object sender, EventArgs e) { switch (tabControl1.TabPageName) <<< What is the c...more >>

Can 2 TreeView controls share a single image collection?
Posted by David Thielen at 7/6/2007 4:02:01 PM
We use the same collection for 3 controls and sometimes the trees come up with no bitmaps for the nodes. -- thanks - dave david_at_windward_dot_net http://www.windwardreports.com Cubicle Wars - http://www.windwardreports.com/film.htm ...more >>

Delegate for control embedded into MFC
Posted by bmelt at 7/6/2007 3:28:01 PM
I create a Windows Forms Control library (in C++) and put it on a form (C#). I can add a control to control library and handle its events: private void Form1_Load(object sender, EventArgs e) { Button btn = new Button(); this.ControlLibrary1.Controls.Add(btn); ...more >>

I can't see events in a controls property sheet. Formats are ok.
Posted by help01 at 7/6/2007 8:04:10 AM
I am able to see the property sheet for a specific textbox on my report, however, when I click the event tab on the property sheet, nothing is shown. When I click the format tab, I see what I expect to see. Any hints as to why I see formats, and not events. ...more >>

Autosize DataGridView
Posted by Ralf Callenberg at 7/4/2007 1:08:44 PM
Hello, in a DataGridView control I set AutoSizeColumnsMode to AllCells. As wanted the columns' widths are adjusted according to the content of the cells. But if a vertical scrollbar appears it is at the border of the display area I determined at design time and therefore is detached from the ...more >>

Container Control
Posted by kris at 7/4/2007 12:00:00 AM
Hi, i want to create a control that will act as a container for other controls like textbox , images ,documents. I need also to have drag and drop to be supported in this control. can any one please help me on this. Regards Kris ...more >>

ListView dose not show ToolTipText
Posted by Krunoslav Ostrouska at 7/3/2007 12:00:00 AM
Hi I have a ListView in a tab. The listView.ShowItemToolTips is true and the items ToolTipText is also set. But, the ListView will not show any ToolTips in any listview visual style. I use VS2005 with C#. Kruno ...more >>

How to disable DataGrid refresh while adding?
Posted by Jeffery Jones at 7/1/2007 11:20:56 PM
Is there any way to disable DataGrid refresh while adding many rows - somewhat like in the old days: http://blogs.msdn.com/oldnewthing/archive/2004/06/10/152612.aspx I'm manually adding rows to an underlying DataTable object via strings. I tried BeginLoad() but it had no effect....more >>

How to change colour of TextBox border
Posted by Notre Poubelle at 7/1/2007 4:00:02 PM
Hello, I'm trying to figure out how to change the border colour of the TextBox control. I can't find a property that does this. I've researched this but couldn't find a complete sample of anyone achieving this. For the Textbox control, the overriden OnPaint method is not called unless ...more >>

WebBrowser control in .Net 3. Is it possible???
Posted by Levan Jgarkava at 7/1/2007 1:25:51 AM
Hi Everybody! I just installed .Net 3 Framework on my computer and created new Windows Application (WPF) in visual studio 2005 sp1. Then tried to find WebBrowser control in Toolbox but couldn't locate it. I tried to add manually shdocvw.dll and tried other ways but I just can't find a way t...more >>


DevelopmentNow Blog