can someone explain the main benefits of different types of references in C#, weak references, soft references, phantom references, strong references.
We have an application that is consuming a lot of memory and we are trying to determine if this is an area to focus on.
...
Does anyone know what this means . . getting this in C# winforms applications
...
I'm trying to get better at using MVC/MVP style patterns with my WinForm apps and I'm struggling with something that maybe someone here with more experience can help me with.
Below is my basic project layout:
The class G2.cs handles the running of various threads and includes a Start/Stop and other various methods involved with those ...
I mean a tool that can extract certain contents from old .NET 1.1 WinForm code and put it in .designer file (make it looks like .net 2.0 WinForm code). This also involves an update to the project file (.csproj/.vbproj)..
If no existing tool yet, any tip or pointer on how to do this by programming?
...
Is there any reason to start a GUI program (application for Windows) written in VB.NET in the Sub Main of a module rather than directly in a form?
EDIT: The program won't take any command line parameters and it will be executed as a GUI program always.
...
I'm using Windows Forms and VS2008. I want to store an enum value in my application's settings file.
The settings editor in VS2008 only gives me a limited set of types. Amazingly, enums don't seem to be one of these types that are automatically supported - have I understood this correctly?
From reading up on the subject, it seems lik...
I have a winforms application that is doing the following:
on each query:
Db connect
Db query
Db disconnect
as we are trying to avoid having to keep the db connection open. This suffers from performance as we have to connect / disconnect everytime.
What is the idealized model here to have the fastest performance but without having...
I am using C# and Windows Forms. I have a normal progress bar working fine in the program, but now I have another operation where the duration cannot be easily calculated. I would like to display a progress bar but don't know the best way to start/stop the scrolling marquee. I was hoping for something as simple as setting the marquee spe...
I want to pass an integer value to a form in .Net so that it can load the right data. I'm using this so that when I double click on a record in a list, a form opens with the data from that record loaded so it can be edited. What is the best way to do this? Should I create a property and set it before calling the Show() method, or should ...
Is it possible to migrate a VB.NET Winform solution to a 3.5 WPF solution. If so, any suggestions how to do it?
Thanks in advance!
JFV
...
For a certain inputform, I'd like to make it possible to do input with the keyboard. I know how to read the keys through KeyPressed and KeyUp, but the problem is that when a control has got the focus and the user presses the Enter key, that control receives the a Click event. Is it possible to prevent that behaviour ? Or is it possibl...
How do you modify a propertygrid at runtime in every way? I want to be able to add and remove properties and add "dynamic types", what I mean with that is a type that result in a runtime generated dropdown in the propertygrid using a TypeConverter.
I have actually been able to do both those things (add/remove properties and add dynamic ...
Why doesn't the designer work if you inherit from an own written genericform?
Suppose I've got the following genericform
public class GenericForm<T> : System.Windows.Forms.Form
{
public T Test
{
get;
set;
}
}
When I go to the designer I get errors.
The only workaround I made up is using compiler directive...
I am using Infragistic UltraGrid in window application.
I need a event which is raised on cell value change.
I try many events like AfterCellActivate,AfterCellUpdate but uanble to find right one.
Please suggest me.
...
I'm upgrading an app with many different settings files from XP to Vista and changing location of the files to use the
Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData)
line rather than write to application path. There are values used in mannnny places from property settings. Those values are getting assigned from v...
I am using Infragistic UltraGrid in window application.
I need a event which is raised on check change of checkbox in Infragistic UltraGrid.
...
In my current application I have a form that requires the user to enter TONS of data. There are about 30 Textboxes and it happens that during development new ones get introduced or old ones get kicked out.
One Requirement by my customer is that they are all navigable through pressing Tab, and so I'm currently at the mercy of the TabInde...
The [x] button in the top bar of a window that normally closes the window in standard Windows, appears to do a minimise instead on Windows Compact.
How do it make it close instead? I need to also be able to raise an event when this happens as I want to preform some logic on window close.
...
I filled up a combobox with the values from an Enum.
Now a combobox is text right? So I'm using a getter and a setter. I'm having problems reading the text.
Here's the code:
public BookType type
{
get
{
return (BookType)Enum.Parse(typeof(BookType), this.typeComboBox.Text);
}
set
{
this.typeComboBox...
Is it possible to override the background color of the minimize and maximized buttons in WinForms?
...