For example, I've got a business object Person:
class Person : INotifyPropertyChanged
{
string Name { get; set; }
DateTime DateOfBirth { get; set; }
}
// ^ abbreviated for better legibility; implementation would be trivial
And I've got some Winforms UI controls data-bound to an object of this class:
Person somePerson = ...;
n...
I'm writing an application which creates a potentially large number of forms to display widgets on the desktop. Every instance of that form shows up in the task manager's Applications list, despite ShowInTaskbar = false; and indeed they do not show in taskbar.
The behavior I want is that only the application's main form shows up in the ...
I have been messing with this for quite some time now and it's getting less and less fun; I followed the MSDN guide for deleting a row from a datagrid. And it works for any row however I am not able to specify the row... essentially I can delete random rows by using the CurrentIndex parameter anything I try to be more specific gets me a ...
I'm using ListView in VirtualMode and Details View with small icons.
This ListView have like 100,000 items inside.
The problem is that drawing this listview is much slower in Windows 7 compared to XP.
You can fill the slow drawing while scrolling the ListView or while multi-selecting items.
Additionally, i noticed that drawing become...
Hello,
I'm relatively new to C# and I'm trying to use a tab control which has 5 tab pages within it. These tab pages are displayed and hidden when required and I am able to re-add pages to the required position e.g. tabPage 2 should be re-added between tabPage1 and tabPage3 by passing in a number relating to the position I want it to a...
I'm trying to add a control(Label) inside of a panel.
Please see the code:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace AddControlProgramatically
{
public partial class Form1 : Form
...
Hello,
I'm developing C# .NET windows Forms application. In which I've a main window and few other window form classes (which are used as dialogs). I've a computationally intensive task(takes 3-4min). When user selects this task from the menu, a new dialog (window) pops up and takes parameters required from the user and it has a progres...
What is the standard convention to save data in textboxes and other form data to be loaded the next time the program is opened?
...
I want to 'grab' the image of a control on my winforms dialog. I can access the 'graphics' context for the control using:
MyControl.CreateGraphics()
But how do i copy a rectangle from that graphics context to an image, or a bitmap, or call getpixel on it?
Thanks a lot.
...
I have Form1 that has a textbox and a button. When user clicks the button in Form1, Form2 opens up with a label control that carries the value of textbox in Form1.
What i did is set the textbox modifier of Form1 to Public, but when i call the textbox name of Form1 in Form2, i get an error that says "The name "txtbx1" doesn't exist in th...
In a C# .NET GUI Application. I also need the console in the background for some tasks. Basically, I'm using a Thrid Party library for some processing (takes lot of time) which writes its intermediate results to console. This processing is a computationally time taking task. So, I'm assigning this task to backgroundworker. I mean backgro...
I have a big application with many textbox controls (about 300-400).
I need to forbid an unicode input for all the textboxes. Is there any easy way to do that ?
C#, VS 2008, .NET 2.0
Maybe there's some global application handler or something else ?
Edit: I want to allow an input of latin alphabet symbols and digits. Chinese, japane...
I have a comboBox that displays different Municipalities (these Municipalities belongs to a particular Province) in our country. Since there are Municipalities having the same name, I binded the "MunicipalityName" (a table column from 'MUNICIPALITY' table in my database) to DisplayMember property of the comboBox and "Municipality_ID" to ...
Hi All,
I have created a 'CustomTextBox' class to nevigate focus by 'Enter' and 'Up' key in the .Net Winform development.
I am using given below code to do so.
public class CustomTextBox : System.Windows.Forms.TextBox
{
protected override void OnKeyDown(KeyEventArgs e)
{
switch (e.KeyCode)
{...
hi
i have this code for fast search
Tmp = "";
MAK = "";
DES = "";
Cmd.CommandType = CommandType.TableDirect;
Cmd.CommandText = "Ham";
Cmd.IndexName = "B";
Cmd.SetRange(DbRangeOptions.Match , new object[] { txtMa.Text }, null);
SqlCeDataReader read = Cmd...
We have a mapping form in our application that needs a Google Earth background image, and as you can't use the Google Earth plugin in a browser that is under a panel, we use a second form to show the background image. We have a transparent panel on the mapping form that the drawing is done on while Google Earth is drawn on a form held in...
how can i put and use progress bar in my web browser in windowes application project with c# language?
...
Hi,
does anybody know a tool for examining the structure of a windows forms application? I want to get information about every control on the form like buttons, labels etc.
I tried Spy++ but it tells me only some information about the window structure, but nothing about the internal controls.
Thanks!
Mark
...
I have a different requirement in one of my projects, when I run my exe and make it idle
(i.e. without click, min, max), after a period of time (timer) it should be automatically closed. If anyone clicked before the particular time, the timer must reset for the same period.
How can I find out whether the exe is idle or not?
...
hi
i need to get data from .csv file to access
it works excellent but i have one problem.
when i try to get : IS-43"39"36"24
i receive: "IS-43""39""36""24"
some code:
while (SW.Peek() != -1)
{
TEMP = (SW.ReadLine());
TEMP = TEMP.Replace("'", " ");
char[] B...