Click here to Skip to main content
15,917,702 members
Home / Discussions / C#
   

C#

 
GeneralRe: i see why C# SHOULD have required to catch exceptions now Pin
bjoernen13-Sep-04 2:58
bjoernen13-Sep-04 2:58 
GeneralRe: i see why C# SHOULD have required to catch exceptions now Pin
elguaro12-Oct-04 14:36
elguaro12-Oct-04 14:36 
GeneralRe: i see why C# SHOULD have required to catch exceptions now Pin
bjoernen12-Oct-04 20:08
bjoernen12-Oct-04 20:08 
Generalkeypreview problem ( listview and buttons) Pin
BrownJacket12-Sep-04 10:19
BrownJacket12-Sep-04 10:19 
GeneralListView Problem Pin
Tomas Brennan12-Sep-04 8:50
Tomas Brennan12-Sep-04 8:50 
GeneralRe: ListView Problem Pin
VanesaAFESRG12-Sep-04 17:05
VanesaAFESRG12-Sep-04 17:05 
GeneralRe: ListView Problem Pin
Tomas Brennan13-Sep-04 2:07
Tomas Brennan13-Sep-04 2:07 
GeneralRe: ListView Problem Pin
VanesaAFESRG13-Sep-04 14:42
VanesaAFESRG13-Sep-04 14:42 
1) What is the real difference between MouseUp/MouseDown event handler apart from the fact that the button is released and the button is down respectively?
Vanesa: if you click with the mouse and you do it on the wron place... using the MouseUp event you cant move the mouse (without relese the button) to another place and do nothing, while if you use the MouseDown, the event run when you click the mouse. This is the diference that I note.

2) What situations would I use the MouseDown/MouseUp event handler and what would be a good reason to do so?
Vanesa: I use MouseUp for example when I search address for a customer name, if datatable (returned for the sql query) contains more than 1 row, I send it to a especial form with a datagrid, and the user can select the customer to view his address,
private void dataGrid1_MouseUp(object sender,
System.Windows.Forms.MouseEventArgs e)
{
System.Drawing.Point pt = new Point(e.X, e.Y);
DataGrid.HitTestInfo hti = dataGrid1.HitTest(pt);
if(hti.Type == DataGrid.HitTestType.Cell)
{
dataGrid1.CurrentCell = new DataGridCell(hti.Row, hti.Column);
dataGrid1.Select(hti.Row);
// this is a control that "public" the selected id to the others forms
this.textBox1.Text = dataGrid1.CurrentRowIndex.ToString();
this.Close();
}
}
and the program return to the form that call the grid

Bye


Vanesa Rose | [Rose] Addicted To DJ Tiësto's Trance
GeneralRe: ListView Problem Pin
Tomas Brennan17-Sep-04 5:56
Tomas Brennan17-Sep-04 5:56 
GeneralRe: ListView Problem Pin
SandeepN13-Sep-04 13:05
SandeepN13-Sep-04 13:05 
GeneralRe: ListView Problem Pin
Tomas Brennan17-Sep-04 6:00
Tomas Brennan17-Sep-04 6:00 
GeneralPerformance question Pin
BoxenBiene12-Sep-04 4:21
BoxenBiene12-Sep-04 4:21 
Generalswitch question Pin
BoxenBiene12-Sep-04 3:37
BoxenBiene12-Sep-04 3:37 
GeneralRe: switch question Pin
Dennis C. Dietrich12-Sep-04 4:02
Dennis C. Dietrich12-Sep-04 4:02 
GeneralRe: switch question Pin
BoxenBiene12-Sep-04 4:26
BoxenBiene12-Sep-04 4:26 
Generalembeding a NumericUpDown column in a datagrid Pin
BaraaSh12-Sep-04 3:30
BaraaSh12-Sep-04 3:30 
Generalnumericupdown column in datagrid Pin
BaraaSh12-Sep-04 3:18
BaraaSh12-Sep-04 3:18 
GeneralRe: numericupdown column in datagrid Pin
sreejith ss nair12-Sep-04 20:50
sreejith ss nair12-Sep-04 20:50 
GeneralC# send arraylist between forms Pin
Member 119488412-Sep-04 3:15
Member 119488412-Sep-04 3:15 
GeneralRe: C# send arraylist between forms Pin
Nick Parker12-Sep-04 4:35
protectorNick Parker12-Sep-04 4:35 
GeneralRe: C# send arraylist between forms Pin
Member 119488412-Sep-04 5:14
Member 119488412-Sep-04 5:14 
GeneralRe: C# send arraylist between forms Pin
Nick Parker12-Sep-04 6:18
protectorNick Parker12-Sep-04 6:18 
GeneralRe: C# send arraylist between forms Pin
Member 119488412-Sep-04 7:45
Member 119488412-Sep-04 7:45 
GeneralRe: C# send arraylist between forms Pin
Member 119488412-Sep-04 7:50
Member 119488412-Sep-04 7:50 
GeneralHC_SKIP Pin
Hadi Fakhreddine12-Sep-04 1:35
Hadi Fakhreddine12-Sep-04 1:35 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.