Is it possible to use object binding to bind a windows form control to an object so that whenever the object changes the form control reflects that change.
Here's what I've done so far:
Added a data grid to the form.
Added a binding reference to the class. This added the properties of the class as columns to the datagrid.
set the ...
So in my window onLoad method I am pre-populating a grid with values retrieved from a database. Here is the method below for the window load:
Private Sub winMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
''#Load Grid
Dim dt As New DataTable
With dt
.Columns.A...
Hi All.
First of all I have a datasource in my winforms project where I needed to bind the text in a checkedlistbox to a nested property in this case the "Name"
object[0] --> type of ILink --> Name = "adobe"
object[1 ]--> type of ILink --> Name = "flash"
To accomplish this I found a smarter guy here who led me to a structure like wi...
Hi,
I have created a windows application, which gets a xml file from the URL and save it on my local machine.In this application a Timer control is set for get the updated XML file from the URL and show the update into label. I have created a setup project and Installed it on another system.
Problem is that, The installed application i...
What is the equivalent for Datamodule in Delphi Prism XE? How data binding is supported in Winform applications using Delphi Prism XE?
...
hey guys, a simple question but i dont know to do it.
When I exit my app I want to call my save method to check if the user wants to save any changes.
How to i call the save click event method? This is what I came up with:
if (isDirty == true)
{
saveToolStripMenuItem();
}
this.Close();
But...
hii
I am using devexpress xtrascheduler.in that am having a scheduler which is having the default look(having time in the left side verticaly)but i have to get some labels on the left side ie,in addition to the existing scheduler control look...
In simple i want to add some label on the existing scheduler control verticaly.is it possi...
I have a button click event handler with the following pseudo code:
private void btnSave_Click(object sender, EventArgs e)
{
if(txt.Text.length == 0)
this.Close();
else
// Do something else
// Some other code...
}
This is just some simple code, but the point is, when the text length equals zero, I want to close the fo...
Hello Guys,
I've been tasked with finding out if it's possible to have a WCF service that can be hooked into by a Windows .Net 1.1 application, as well as newer web applications and one mobile app.
I've done a fair bit of reading on the subject but I've got next to no experience on winforms or the .net framework prior to 2.0.
Any help...
Is there a simple way to indent a multiline selection by pressing the tab-key or shift-tab to remove tabs at the beginning of each selected line in a c# textbox control (VS2008)?
...
When the user clicks save, and there is nothing in the listbox, i want to raise an error.
I figure I use a try catch block like so:
try
{
//when you go to save, and the list box is empty, you should get an error message
if (dataListBox.Items.Equals(null))
throw new Exception();
...
I have a longstanding C# .NET 3.5 application 'freeze' which I am at a loss with. There are two C# executables. One has a full UI, the other runs as a tray app. They both communicate via WCF to a third service app, also running in the tray.
Randomly the UI thread of main Winforms app will deadlock. Mysteriously if I quit the tray app t...
I plan to create a datagridview that will only have about 10 rows max.
It will get updated at regular intervals and I want for it to have nice effects where
each row will have it's opacity increased to full, the first row being the first and the last row becoming fully opaque at the end.
Do you know how to edit the opacity of a datagrid...
hey guy, have onather problem.
I am trying to raise an exception if a user clicks the delete button but doesnt select a item in the listbox.
This is what i have:
try
{
if (dataListBox.SelectedIndex == null)
throw new Exception;
//deletes selected items
dataListBox.It...
I have a button btnOK on my form, with a DialogResult property of OK. The form's AcceptButton property is set to btnOK. So if I click the button, the form closes automatically.
Now, inside the btnOK_Click() method, I want to ability to cancel out of the close action, e.g. if there was an error I want to show a message box and not clos...
I try to minimize my form to system tray but when I do, the form disappears and the notification icon doesnt work :(
What am I doing wrong?
Private Sub Form1_Resize(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Resize
If Me.WindowState = FormWindowState.Minimized Then
Me.Visible = False
...
I'm working on a modular project consisting of multiple sensors, each inheriting from an abstract Sensor class. To configure each sensor, I have started to add a user control panel for each sensor (inherits from UserControl), which is loaded at runtime and displayed in a panel by the calling application.
But then I realised that to chan...
Following code works in debug mode, but in release mode there are only blank rows shown, with only an icon per file. The file list is correct, since in another mainmenu item the files show correctly ??
private void FillFileLinks()
{
dataGridView1.AutoGenerateColumns = false;
string[] files = GetFileList();
...
How can I add the the sleek On/Off control to a Windows Forms application?
Or do I need to use WPF?
Example
Ignore the red highlighted area, look at the on/off controls (screenshot lifted from Visual Studio Power Productivity Tools).
...
I have an ImageList that is populated with, well you guessed it, images.
These images are loaded into memory in a dataset as a Bitmap. Until I loaded them into the ImageList the rise of memory is not worry. But when they are added to the ImageList the memory usage sky rockets.
But the biggest problem is when I have to reload the list o...