windows-forms-designer

WANT TO host Visual Studio Form Designer in my own application [closed]

江枫思渺然 提交于 2019-12-05 05:35:40
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 4 years ago . I'm writing an application that lets the end use design a Form just the way Visual Studio lets you design a windows forms. I looked into visual studio forms designer articles in msdn and also studied open-source SharpDevelop editor. Both the examples host visual studio's windows forms designer to provide form

Visual Studio 2017 - can't find Visual C++ Windows Forms

孤人 提交于 2019-12-05 02:34:22
So, I'm in awkward situation - I wanted to create Windows Form App using Visual Studio, but I can't find any place to create Visual C++ Windows Form template. I tried even to reinstall Visual C++, add other libraries and search answer online - no results. I can of course create new Winforms in C#: But not in C++: Also, all possible modules in Visual Studio Update was checked: I tried even add template from Online list: What should I do next? I use Visual Studio 2017 Community Edition. Ok, I found a working way to creating Windows Forms in Visual Studio 2017. Create new CLR Empty Project: Add

Can I change the default modifier from Friend to Private in the Windows Forms designer in VS 2008?

和自甴很熟 提交于 2019-12-04 19:53:06
问题 When I develop a Windows Forms app in Visual Studio using C#, every control that I add to my form is by default marked as private , which is what I want. When using VB.NET, every control is by default marked as Friend (the equivalent of internal in C#), which is not what I want. Can I just change this default? It seems like surely it's a setting somewhere. 回答1: Annoying, isn't it. What I usually do is when the form is stable, I replace Friend WithEvents to Private then add WithEvents to the

Datagridview Updating

与世无争的帅哥 提交于 2019-12-04 19:37:16
How to update the DataGridView so that it will effect the changes in database too? The code which I am trying is: foreach (DataGridViewRow myDgrow in dataGridView2.Rows) { myCmd = "Update Details set ProjectName='" + myDgrow.Cells["ProjectName"].Value + "', Description = '" + myDgrow.Cells["Description"].Value + "', DateStarted='" + myDgrow.Cells["DateStarted"].Value + "',TeamSize='" + myDgrow.Cells["TeamSize"].Value + "',Manager='" + myDgrow.Cells["Manager"].Value + "'"; myCmd = "Update Details set Description = '" + myDgrow.Cells["Description"].Value + "', DateStarted='" + myDgrow.Cells[

How to get WinForms custom control's default value to be respected when first dropped on a form

故事扮演 提交于 2019-12-04 19:35:13
I have a class library with a custom control in it: using System.ComponentModel; using System.Windows.Forms; namespace ClassLibrary1 { public sealed class CustomLabel : Label { [DefaultValue(false), Browsable(false), EditorBrowsable(EditorBrowsableState.Never), DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)] public override bool AutoSize { get => base.AutoSize; set => base.AutoSize = value; } public CustomLabel() { AutoSize = false; } } } Notice that AutoSize is set to false in both the constructor and the designer attribute on the overridden method. I have a winforms

Visual Studio 2012 winform designer is VERY slow

主宰稳场 提交于 2019-12-04 18:23:58
问题 We've recently migrated one of our Winforms projects to Visual Studio 2012 from Visual Studio 2008. The transition has went remarkably smoothly and everything builds just fine, however we're now struggling with the winforms designer, which is running incredibly slow. To give an example, if we open a small form (the form contains two text boxes, a numeric updown and two buttons - all standard built-in controls, nothing 3rd party), it will take approximately 40-45 seconds in 2012, however on

UserControl does not auto resize with the Form

99封情书 提交于 2019-12-04 14:39:12
I am having troubles with setting my user control to automatically resize with the panel where it is created. When user is resizing a main form that contains the user control, the size of this user control does not change at all making for some poor user experience. So far I tried following: Ensure MinimumSize and MaximumSize properties on the user control are set to 0. Set AutoSize property on both (1) the user control and (2) the panel where it resides to True Set Anchor property on the panel to Top , Bottom , Left , Right Set Dock property to Fill for the user control (I did this with the

Seeking a Winforms System.ComponentModel.Design Design Surface BeginDrag/EndDrag Event Hook

瘦欲@ 提交于 2019-12-04 13:02:01
I am using C#, Winforms, VS 2017 Enterprise, and the full .NET Framework 4.7.2. [TLDR section at end!] I have been working extensively with the System.ComponentModel.Design namespace to create working Visual Studio-like Winforms designer. Setting up the environment for such an end-user forms designer requires deep understanding of objects and interfaces in the aforementioned namespace (and how to wire-up them all) along with toolbox and property grid components. Therefore, it's not possible for me to post a sample of the code. This question requires knowledge of the DesignSurface class ( https

Error when opening designer on inherited form

戏子无情 提交于 2019-12-04 12:27:42
问题 I am having trouble opening an inherited form in a Windows CE application. This is a project that I am taking over from a ex-employee, but there is compiled versions running on some mobile devices so I would assume that it should be able to open. I have the correct VS version (2008) and have tried cleaning the solution and rebuilding the solution. When deploying the solution it works like a charm. As soon as I try to go into the designer of the inherited forms, I get the following error: To

How to temporarily disable Visual studio auto generated events?

此生再无相见时 提交于 2019-12-04 06:20:51
All, I have finished the GUI design phase... Now I've started to add meaningful names to all the controls in my application. Visual Studio is driving me nuts auto generating the events each time I click on the control to change its name (ok so it only happens when I mess up and double click... but still annoying). Is there a way to temporarily disable this feature? I still want it because it is a great short cut when I'm coding. Thanks! You can't disable double clicking AFAIK but you can open document outline (Menu View > Other Windows > Document Outline), and rename the controls via F2 in