I have an UserControl and would like to hide the resizing handles in design-time, just like the TextBoxControl, that has only two handles (left and right ones)... the height of the textbox is fixed, unless you say it is multiline. In that case, the textbox shows all nine resizing handles.
...
I have a base class for all my textboxes and I want to set the default font in that class. So I started with this:
public partial class MyTextBox : TextBox
{
public WmlTextBox()
{
InitializeComponent();
//Font for the whole application can be altered in the Appearance class
Font = new Appearance().TextBoxFo...
Hi,
can you recommend a Visual C# Form Designer tutorial that is targeted at experienced programmers who have at least a basic knowledge of C# but are new to the VS C# Form Designer. At least it shouldn't be targeted at programming newbs, like Introduction to Visual C# 2008 Express Edition (it explains how a comment looks like in C#).
S...
We implemented new coding standards, which call for our private members to have a leading underscore. Like so:
private System.Windows.Forms.Label _label;
Unfortunately VS will put out the default below when you drag a new label onto your form:
private System.Windows.Forms.Label label1;
Is there a way to change the default to:
pri...
I am trying to update a single motor control application into a program that controls an unknown number of motors(adding motor controls at runtime). The old application was written very statically and relied on windows form designer to generate its views. I am trying to refactor the designer code to basically just display multiple occu...
With several forms of mine, I occasionally run into the following issue: I edit the form using the designer (Visual Studio 2008, Windows Forms, .NET 2.0, VB.NET) to add components, only to find out later that some minor adjustments were made (e.g. the form's size is suddenly changed by a few pixels), and controls get deleted. This happen...
In my Windows Designer host implementation,
The top Control's
Control.Controls does have all the child controls
but for Child control's
Control.Parent is set to
{System.Windows.Forms.Design.DesignerFrame+OverlayControl}
Edit: This is happening in ComponentAdded Event of IComponentChangeService.
Am I doing something wrong?
H...
I have a Windows Forms project in Visual Studio 2008, which references a library that provides some custom user controls.
Is there any way for me to drag instances of the controls in this library onto forms that I am creating in the visual design view?
Thanks.
...
My C# project contains a form. There are some controls across the top of the form and some controls across the bottom of the form, as well as a FlowLayoutPanel in the center, all of which have been placed with the Visual Studio Form Designer.
During runtime, controls are dynamically added to and removed from the FlowLayoutPanel, and b...
Extremely basic question.
Are there common actions I can perform using keyboard shortcuts in the Windows Forms designer in Visual Studio (2008)?
Alternately, could I add my own keyboard shortcuts (either through settings or macros)?
It'd really be nice if I could, for example, set a control to dock/undock in its parent container by ty...
The ability to host your own Windows Forms designer is well documented now, and is a great technique that we will be shipping with our application. However, we'd like to gain some control over editing a form from Visual Studio itself. We'd like to insert our own DesignerLoader derived class into Visual Studio's form editing mechanisms,...
.Net: Why we can't access to some properties of a control programmatically in winforms? For example, "Locked" property of a groupbox is not accessible via code. So What Possibly can I do when I want to locked it programmatically ? Using Enabled = False will greyed out all controls within it and this is not what I wanna to be.
Any Sugge...
I have created a windows form using (vs.net 2008 and vb.net as programming lanugage).
Functionality part is working fine as expected.
My issues is that, when i run my application in different machines, the form display is not proper accross the monitory screen.
In some machines i noticed extra space on leftside of the container. In som...
Hi,
I use VS2008 C# + Windows Forms. I can't understand why comboBox does not behave the way it should.
In Design mode, I added a comboBox to my form, and edit Items to add "A" and "B". Double-clicking brings me to SelectedIndexChanged event, which I edit to display the selected text with MessageBox.
private void comboBoxImageSet_Sele...
Hello
I'm using C#.Net and have a base form that is inherited by several forms.
Until yesterday, when the child (derived) form was opened in the designer the base forms controls would be displayed and shown as locked.
Now, however the form is simply blank. None of the base forms controls are visible in the designer. Everything compile...
Possible Duplicate:
purpose of form1.designer.cs and form1.resx
I Understand about *.designer file grouped with a windows form/control file. But not sure what is the relevance and use of *.resx file attached.
Can i not create a form/control with this file attached to it?
...
I have a panel which contains a TableLayoutPanel which itself contains a number of ListViews and Labels.
What I'd like is for each list view to resize to fit all of it's contents in vertically (i.e. so that every row is visible). The TableLayoutPanel should handle any vertical scrolling but I can't work out how to get the ListView to re...
Hi all,
I have barely any experience with WinForms, but I'm fairly sure that this is a simple task. I just need to enable and disable the Enabled property of a textbox based on the SelectedIndex of a ComboBox.
Can this be done in the designer using DataBindings, or am I required to write a handler of some kind?
...
how to add the checkbox to the datagridview from coding in windows form.
i have a datatable with one column as 'value'=true;
and in another datatable i had settings for that column as value='Checkbox'
so if my value is true and 'checkbox ' is there the default datatable 'value' cell has to be replaced with checkbox selected true. in th...
I want to show a new form in the same window from where it was invoked.
I know a way to show this form on PrimaryScreen or Virtual Screen by code similar to as below:
MyForm.Location = Screen.PrimaryScreen.Bounds.Location;
But i want to show it on current screen.
Is there a way to find out and show it on current screen?
...