Do not know how to add bold to a label in winforms powershell

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

How to refresh the tab that are not displayed

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

Format the time value

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

Periodically change the wallpaper

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

Is it possible to trap start and end events?

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

How to organize MVP with an IoC container?

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

Using ref with 2 shapes ..?

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

Prevent Designer from removing attributes on control members

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

WinForm link radio button

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

The Winforms .Net application does not start

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

Secure ConnectionString in WinForm Applications

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

Deploy / install Windows Form App

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

Does anyone know of a very good Treeview Part 3 control for C #

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

Time reduction in C # forms Function Control.set_Text (string)

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 the parent form when a child form is active?

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.

Can not access the Winforms control in a class

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

How do you include a cursor (cursor) in a custom control?

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

GDI + generic error

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