I have a main window form (not MDI form) and when i do some process, until this process finishes, i want to show another form (a waiting form) If i do that regular way like that ProgressForm = new FrmProgress(); ProgressForm.StartPosition = FormStart
i tried several things from different post, but i just cant seem to make it bold Does anybody knows how to accomplish this? $LabelComputer = New-Object System.Windows.Forms.Label $LabelComputer.Text = "Computer Settings" $LabelComputer.AutoSize
I want to display a ToolTip message below a TextBox, but also want them to be right aligned. I was able to position the ToolTip message at the right edge of the textbox, so I tried to move the message left by message length. So I tried to get the str
I'm new to here. Recently I was ordered by my boss to make a SQL Server database from a Winforms app. I'm trying to create database programmatically. But every time I'm getting an error message. Is it possible to create a SQL Server database file (.m
How do I make an if statement that asks if multiple listBoxes are empty or not? This is what I have so far...is it possible to combine it into one single if statement? if (listBoxEmails.Items.Count < 1) { //Perform action } if (listBoxWebsites.Items.
I am making Winform dekstop application. I am giving an option in my application that user can select database or set database path. when user select database or database path then connection string should be changed at runtime in APP.config.Even if
I don't even know if I can do what I'm attempting but I've imported forms from several projects and added references to those projects. Each project has a different set of connection strings and I'm trying to get them to coexist in App.config where I
I have 3 tabPages on tabControl and each tabPage have a pictureBox. When i select a row in gridview it load images from files, and on selection i want refresh the 3 tabs with images. The problem is that pictureBox refresh only when i switch tabPage n
I have a DataGridView with 9 columns. I have added the same ContextMenuStrip for all the column headers. dataGridView.Columns[i].HeaderCell.ContextMenuStrip = myContextMenuStrip; myContextMenuStrip contains a single item named Hide Column. Now, I hav
I want to format a ms value to a "minutes:seconds" value of two digits, by two digits I mean "00:00" but what I get is "0:0". This is an example: I want to show "02:04" instead "2:4" This is my code: Label
I have a problem setting the desktop wallpaper using the following code. The SystemParametersInfo returns true but it doesn't change the wallpaper. It is the same as before without any changes. But I want the code to change wallpaper periodically fro
I've inherited a reasonably large visual studio WinForms project in C# and VB.Net While I'm working with it, I get messages in the Debug window like this: The thread '<No Name>' (0x1194) has exited with code 0 (0x0). The thread '<No Name>' (0x
I'm trying to get the IoC concept down with a winforms app. Say I have a presenter whose constructor takes its view and a service as constructor arguments. So in the form code I have something that amounts to this: mnPresenter = new Presenter(this, n
I have 2 forms.. from first form i call 2nd form... in second form i do some calculations and i want to get the result in first form after closing second form. First Form Code public partial class XtraForm1 : DevExpress.XtraEditors.XtraForm { String
I want to mark certain controls on my Windows Form with Attributes. So I added the Attribute in my TestAttributes.Designer.cs: [AmbientValue(true)] private System.Windows.Forms.Label label1; But whenever I change the Modifiers-property of label1 usin
I use VS2010 and then drag and drop Member datagridview to design view. After that I drag and drop name member textfield to design view and then try to edit and save. It's work properly. And then I drag and drop sex radio button to design view. But b
I have a standard winforms application that runs on most machines. On a 2003 server with .Net 4 (full) installed it doesn't run. The event viewer shows: Event Type: Error Event Source: .NET Runtime Event Category: None Event ID: 1026 Date: 4/01/2012
How Can I Secure my ConnectionString in WinForm Application?You can't. Although you can encrypt the connection string in the app.config file, the application needs to be able to decrypt it and it is therefore always possible to retrieve the unencrypt
I've added parent node at runtime as TreeListNode parentNode1 = treeList1.AppendNode(new object[] { "BuiltIn Groups"}, null); But now i want to insert child node under particular parent node. In my application when user right click on particular
I have a image for a button. I've used flat button for the image. By default in standard button when you click or hold the mouse over the button the background image of the windows button changes. But I want to change the background image in mouse ho
I have a Windows form app that I've published but the end result is not what I've expected. After the wizard finishes, I click on the setup.exe and the application installs and launches, but I don't see any shortcuts in the All Programs. The applicat
I am involved in a project where I have the need for a really rich treeview control. The application is written using WinForms in C#. The treeview control in .net seems to be fairly limited. It is lacking in several ways: multiselection, can't select
Hoping for a quick answer (which SO seems to be pretty good for)... I just ran a performance analysis with VS2010 on my app, and it turns out that I'm spending about 20% of my time in the Control.set_Text(string) function, as I'm updating labels in q
How to disable a parent form when child form is active using c#?Have you tried using Form.ShowDialog() instead of Form.Show()? ShowDialog shows your window as modal, which means you cannot interact with the parent form until it closes.
I am currently working in a small windows forms project in C# using Visual studio 2008. I have added a custom class to the project, but in this class I am unable to access the forms controls (like listbox, textbox, buttons ) in order to programmatica
I've been assigned to make a custom grid control in C# with windows forms. One thing I'm unsure of is how to handle showing a blinking cursor (caret) to indicate where cell editing is taking place and the next character will be shown. Does anyone kno
How can I make my window not have a title bar but appear in the task bar with some descriptive text? If you set the Form's .Text property then .net gives it a title bar, which I don't want. this.ControlBox = false; this.FormBorderStyle = System.Windo
I have a Form being launched from another form on a different thread. Most of the time it works perfectly, but I get the below error from time to time. Can anyone help? at System.Drawing.Bitmap..ctor(Int32 width, Int32 height, PixelFormat format) at
I'm using Windows Vista and C#.net 3.5, but I had my friend run the program on XP and has the same problem. So I have a C# program that I have running in the background with an icon in the SystemTray. I have a low level keyboard hook so when I press
I want to recreate the stickiness and snapping of windows, like it is implemented in Winamp. The basic premise is, when you drag a window and it comes close to another one, it will snap to it and will stick. When you move it the two will move togethe