I've a legacy application using Asp.Net WebSite (winforms...) and I need run a background thread that collect periodically some files.
But this thread must run just one time!
My problem start when I put a method in Application_Start:
void Application_Start(object sender, EventArgs e) {
SetConnection();
SetNHibernate();
SetN...
I have changed the application Icon in the properties page, tried, then changed my mind,
selected another one, rebuild, file shows the latest icon but soon as i create a shortcut
shows the older icon i wanted to change!!!
Any ideas?
...
I have a VERY simple windows form that the user uses to manage "Stores".
Each store has a name and number, and is kept in a corresponding DB table.
The form has a listbox of stores, an add button that creates a new store, a delete button, and an edit button.
Beside those I have text boxes for the name and number, and save/cancel butto...
I added a menu with short cut keys for copy and past (Control+C & Control+V) on a windows forms application. The application has a single richtextbox control. The events for the menu items call RichTextBox.Copy and RichTextBox.Paste but I can't get the short cut keys to work. Control+c & +v do nothing.
Is there a step I am missing?
...
Can someone tell me how I can binding an Ultratree to a Bindingsource? Binding it to a dataset won't work for me since I need to be able to do filters on the data, something I have in the BindingSource but not in the Dataset.
...
I'm on a thread other than the UI thread and need to display a modal form that's centered on the application's main form. What I usually do is use the width and height of the main form and the modal form to calculate the location, then use the PointToScreen method of the main form to get the location of the modal form. Since I'm on anoth...
Hello, I have some text in a web browser on my form in visual studio, this form is going to be displayed on a big screen and it's content need to be mirrored(flipped) in order to be seen on the other place through mirror. It is not rotation actually. I know it is possible to do it with images, but it is not applicable in my case, becaus...
This object always uses the default on the system, so on an x64 machine, it will use an x64 Internet Explorer object.
Is there any way I can force it to use the x86 IE? The web page element the browser accesses does not work on x64 and is out of my control.
...
Hi,
I have a WinForm application which contains a WPF user control. The WPF UserControl is quite complex and requires several seconds to draw.
Currently my code looks like the following:
// Load event of the WinForm App
private void ucMainScreen_Load(object sender, EventArgs e)
{
ganttChartControl = new ucGanttChart(); // WPF Con...
How do I make a button on a form behave like a button on a toolStrip?
I want a menu-type list to come down. I tried using a toolStripContainer but it is very hard to manipulate to get it to behave as just one button.
Is there an easier way than just putting a toolStrip with one button in a toolStripContainer?
Thanks.
...
I am creating dynamic labels and letting users change attributes of the labes like backcolor and so by sending unicode. However I don't know how to check if the label exists therefore I can't manipulate the dynamicly created label. below is my code:
if ((InputBox.Text.StartsWith("π")) && (InputBox.Text.EndsWith("}")))// only process if ...
This Code triggers selection change event twice. how can I prevent it ?
Currently i m using a flag or focused property to prevent this. But what is the actual way ?
I am using it on winfoms
EDIT
My Mistake in writing Question, here is the correct code that i wanted to ask
private void frmGuestInfo_Load(object sender, EventArgs e)
{
t...
In the program we are working on, the user data is collected in UserControls which is data bound to a business entity using BindingSources.
I need to find all the BindingSources in a UserControl programatically.
Since a BindingSource source is not added to the UserControl's Controls collection, I cannot search in there.
Can this be do...
I have a ComboBox. It is critical that the user cannot scroll by accident and change the selected value.
How can I prevent the ComboBox from changing the value and text when the use scrolls? Thanks.
Visual Studio 2008
...
I'm looking for a free, syntax-highlighting, possibly autocompleting "Programmer's textbox" style control for use in a Visual Studio Windows Forms or WPF project. It should work with C# and self-defined languages, and the licence should permit its use in a closed, in-house development tool.
There are pay-for solutions available - someth...
I'm writing a WinForms app for a place I volunteer at. I'm stuck at one part though. How can I have multiple users running the app, an alarm go off at whatever time but have any given user shut off the alarm? So let's say 11:30 on Tuesday rolls around, an alarm goes off on 4 PC's and one of the users can click a button and the alarm goes...
I need to find a child control in a winforms panel. I was wondering if there is a method similar to Panel.FindControl() of the asp.net webforms panel in the .net winforms version
...
I am working on a 3rd party application that allows plugins to be written in .NET 1.1. I have decided I would like to write my plugin to call a seperate process from the .NET 1.1 plugin (achieved using Process.Start). This is fine- I create a new process that is a WPF app.
When I launch this through MSTSC everything works as expected, h...
I have a borderless form which is always on top and with WS_EX_NOACTIVATE flag set to prevent it for gaining focus.
const int WS_EX_NOACTIVATE = 0x08000000;
protected override CreateParams CreateParams {
get {
CreateParams param = base.CreateParams;
param.ExStyle |= WS_EX_NOACTIVATE;
return param;
}
}
...
What do I have to add to a C# program in order for it to search for and update itself every time it loads up?
...