I have a picturebox where I change the BackgroundImage frequently. I have a the BackgroundImageLayout set to Zoom.
The problem is that when an image does not have the same scale as the picturebox, the picture is drawn in the middle. That is, the top and the bottom padding of the picturebox is always the same.
I would like for the Bac...
hello,
i need to freeze certain columns in listview so when the user scrolls horizontally the frozen columns will not be affected (like in excel) but there is no frozen(bool) property like that in datagrid. Can this be done in listview control? Thanks
...
i need to animate an object in c# windows application
int l_nCircleXpos = 9, l_nCircleYpos = 0;
private void Form1_Paint(object sender, PaintEventArgs e)
{
Graphics l_objGraphics = this.CreateGraphics();
Pen l_circlePen = new Pen(Color.Blue);
SolidBrush l_circleBrush = new SolidBrush(Color.Blue);
l_objGraphics.DrawEllip...
Hi all,
Im writing an application that needs to get notified when a control in another application is clicked\invoked. How can i catch the click from my application?
Here are some more related questions :
Is UIAutomation can be a solution? is it working on unmanaged applications also?
Is the Spy++ solution works also on managed applic...
Long-delayed update
I'm accepting MUG4N's answer to this question, and I also want to respond to some of the criticisms that were raised against it.
ChrisF said:
...you can't make UI calls directly from background threads.
This is a blanket statement, and is not 100% true. Let me just point out a few facts:
You can actually mak...
Is there a possbility to disable animation of the progress bar?
I need it for some pocess which is paused and not running at the moment. An average user would think the process is running if the progress bar is being blinking.
The advice to create own progress bar control is not what I'm looking for.
...
I got an error when run datagridview.DataSource = dataView;
dataview is correct. I can see data inside it when I debug program.
I got next error "Object reference not set to an instance of an object."
Any Ideas?
code:
this.datagridview = new System.Windows.Forms.DataGridView();
...
DataSet ds = new DataSet();
XmlReaderSetting...
When the user clicks the window title/button in the taskbar, what .NET event (or Windows API message) is sent to the window?
I'm using C#/.NET 2.0/Windows Forms.
Thank you
...
I want to copy two columns from excel and work on them in a c# program. What component is the best to use to mimic an excel column in a win form?
...
Situation:
In A form I have a TableLayoutPanel(Dock= Fill) and a label (which parent is the Form, not the tablelayoutPanel) which anchors are set to Top+Bottom+Left+Right.
Now, when I run this form and rezise it, the label does not center itself in the Form, as I expected.
Workarounds?
...
Hello I have OnLoad eventhandler like this:
private void MainView_Load(object sender, EventArgs e)
{
LayoutMdi(MdiLayout.TileVertical);
}
But nothing happens. How do I make it work?
...
I have a WinForms app that I recently re-wrote in WPF and I need to release to my end users. I'd like to be able to have the users go to the ClickOnce install point for the WPF application and have their WinForm application removed so they don't have both on their machine
What's the best way (read: easiest for users) of accomplishing th...
I am setting my Winforms Button control properties to appear as a hyperlink would on a web page. I've formatted everything fine, except the border in the FlatAppearance object. I have code to act as pseudo-CSS (FormBackColor is a string constant.):
b.FlatStyle = FlatStyle.Flat
b.BackColor = ColorTranslator.FromHtml(FormBackColor)
b.For...
Hi.
I need to create a class Toolbar : Windows.Form.UserControl (Framework 2.0) and to place it into HTML page. This page must work in IE6+.
I found some examples and created my toolbar, but IE doesn't want to display it.
Site with examples:
http://feishunji.blog.51cto.com/237830/45990
Please, help to solve this problem.
...
I need a way for my .Net Winform app to detect if my app is opened on a Laptop or a Workstation.
I have looked at Environment and SystemInformation but to no avail. Would WMI do the trick?
Thanks for the direction....
As requested I have an application that uses Merge Replication to allow our users to work in Members homes. Some...
How do you print a specific page from the activereports report Windows viewer control programatically?
...
Hello, basically my project is an MDI Winform application where a user can customize the interface by adding various controls and changing the layout. I would like to be able to save the state of the application for each user.
I have done quite a bit of searching and found these:
http://stackoverflow.com/questions/2076259/how-to-auto-s...
How can I disable the parent form when I call a child form?
This code doesn't disable the parent form like I thought it would:
frmChild.ShowDialog()
...
As i understand it, when a keyboard button is pressed it should invoke the KeyDown event for the control which has focus. Then, the KeyDown for the parent control, so on and so forth until it reaches main form. UNLESS - along the chain one of the EventHandlers did:
e.SuppressKeyPress = true;
e.Handled = true;
In my case, KeyDown eve...
So I have this utility library that is compiled as a dll under .net 3.5 and it is used by my asp.net 3.5 website. I created a .net 4.0 winforms app to push data onto the website. I want to make use of the functionality in the utilities library from this winforms app.
The problem lies in that when I make reference to the utilities libr...