|
I checked that before, and it will come up with the following errors:
Error 1 The best overloaded method match for 'System.Array.Sort(System.Array)' has some invalid arguments
Error 2 Argument '1': cannot convert from 'System.Collections.ArrayList' to 'System.Array'
|
|
|
|
|
|
Thanks,
I'm going to look at this approach.
ESTAN
|
|
|
|
|
hi all !
it's my first post here so let me welcome myself
ok let me explain my problem : i hawe a windows form in which i have a bound DGV (datagridview) and a bindingnavigator associated to sql server database.
in that DGV i'm using some handler events CellValidating, RowValidating... and DGV_DataError so the problem i'm facing is whenever there's a mistaken row in the datagridview i can't remove it with the bindingnavigator Delete button. indeed when i click on the delete button, the row in question, losts the focus and proceed on the validation process and it results in the final to the DataError event, in which i assign e.Cancel = True and that's logic because the entry in the row can't be reflected to the dataset in this case. so the process terminates with the dataError event without processing in removing the row, even when i handle the clik event of the bindingnavigator's Delete button nothing happens it doesn't process.
can anyone help me please
thks
C# is the future
|
|
|
|
|
My mouse ( and probably yours ) scrolls when you move the wheel left and right. Does anyone know how to capture this event on a window that doesn't have a scrollbar ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Hello
For what I know WM_MOUSEWHEEL is sent to any window, whether having a scrollbar or not. Use Spy++ to monitor the window you want to catch the event in, then see if the message is sent to it or not. If so, you can easily filter it out.
Regards
|
|
|
|
|
Thanks, but that's not what I want. I am catching the wheel message. I want the message when the wheel is clicked left or right.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Christian Graus wrote: when the wheel is clicked left or right.
Whel is clicked?!! You mean rolled? and my wheel rolls up/down not left right!! For all I know you can check the lParam for that. HiWord contains WHEEL_DELTA which is the destination of rotaion. +ve for up, and -ve for down. The LoWord contains if other buttons are pressed. Was that what you want? I guess you already know that!!
Explain what you mean by "Clicked left or right"?
Regards
|
|
|
|
|
I appreciate that people sometimes ask dumb questions here, but when I ask something, I mean what I say. My mouse wheel rolls, the wheel can be pressed ( middle button ) and it also can tilt to the left or right, which seems to send WM_HSCROLL in windows with a scrollbar. I want to use that in my program.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Christian Graus wrote: I appreciate that people sometimes ask dumb questions here
Somtimes?!! Man you spent a lot of time in the C++ forum. Don't take offence, I don't expect anything dumb from you.
About your wheel tilting, it's kind of special. I didn't see it before. Yet, since you are asking in the C# forum, that means that your are using .Net controls, which should have built-in abilities to handle such events. Anyway, all I can think of -if you want special handling of the event- is to use Spy++ to get what message is sent, and filter it out. Or maybe use inline assembly in a C++ dll to monitor PS2/use mouse port!;P
Regards
|
|
|
|
|
Yeah, I did Spy++, that's how I know WM_HSCROLL is occuring, nothing else that I can see.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
So, is there a problem in using it?
Regards
|
|
|
|
|
Yes - it does not fire a click event, and I don't want to use it for scrolling.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Sorry! Out of ideas. For all I care: "If it fires when you click that thing, use it!".
Good luck!
-- modified at 18:28 Thursday 28th September, 2006
Wait a minute!! I think I got you. Yo want to use it in a custom control of some sort, like a game?? Maybe want to make a fourth/fifth mouse click event? So what? Use the WM_HSCROLL message for what you need. Doesn't necessarily implies that you must scroll!!
Otherwise, like I said when I was joking, you got to listen to the port of the mouse somehow and see what bits stream is sent in the clicking.
Regards
|
|
|
|
|
Hi
Could anyone please tell me how to deal with a for the content pages??
I had a page named test.aspx, and it has two local resourses files (.resx) , and it work fine, but when I decide to insert a master page, the localization process didn't work any more, why ??
Note : iam don't assign the master page for the test.aspx at runtime
what i have to do ??
thank you all
Tamimi - Code
|
|
|
|
|
Hi,
I'm using the code from this article to detect if another instance of my program is running and raise the other instance if it is, closing down the seccond instance of my program.
However, I would like to parse the command line parameters given to the seccond instance towards the first instance of my program, prefferably by invoking some kind of method on it. Is there any way of doing this?
|
|
|
|
|
Hello
sjembek wrote: I would like to parse the command line parameters given to the seccond instance towards the first
You can always check the Process.StartInfo.Arguments of the second process.
Regards
|
|
|
|
|
Hello,
In a window application, i open forms from my main window. When i open a form from an other form, the second is always under the other, how can i do to put it on the top?
Thank you for the answers.
|
|
|
|
|
use method ShowDialog() to display focused form.
|
|
|
|
|
Thank you for the answer but i don't want a modal form
|
|
|
|
|
in my app i use childs, so i also have diff forms in my main form, i simply tell the childs were to stand:
databchild.Show(); // show form3
databchild.Top = 10;
databchild.Left = 10;
databchild.Height = 550;
databchild.Width =560;
grz
|
|
|
|
|
hi,
i want to change the color of rows with wrong info when i load my form,
the info comes from a database, it is checked on error earlier and replaced the value of the cell with "wrong info",
now in my load i check all the cells of my datagrid on "wrong info" values if ther is one i want that entire row to color red.
i have tried it for one column where there is wrong info, the breakpoint shows me that he does the color changing, but nothing has changed in the view.
is it changed back so quickly that i couldnt see it in red? if yes , where woud that code be written? in the defaultview maybe? and how do i sort it then?
this is what i wrote in the load from function:
lastrow = dataGridView1.Rows.GetLastRow(DataGridViewElementStates.Visible);
for (int x = 0; x < lastrow + 1; x++)
{
string fout = dataGridView1.Rows[x].Cells[3].Value.ToString();
if (fout == "wrong info")//check on wrong info
{
dataGridView1.Rows[x].Cells[3].Style.BackColor = Color.Red;// color red
dataGridView1.Rows[x].Cells[3].Value = "error";// change value to error
}
}
thx
|
|
|
|
|
dataGridView1.Rows[x].Cells[3].Style.BackColor = Color.Red;// color red
dataGridView1.Rows[x].DefaultCellStyle.BackColor = System.Drawing.Color.Red
good luck
Where there is a will,there is a way.
|
|
|
|
|
thx, i also found something in the meentime
private void dataGridView1_RowsAdded(object sender, DataGridViewRowsAddedEventArgs e)
{
index = dataGridView1.Rows.GetLastRow(DataGridViewElementStates.Visible);
for (int x = 0; x < index + 1; x++)
{
for (int y = 0; y < colamount; y++)
{
string fout = dataGridView1.Rows[x].Cells[y].Value.ToString();
if (fout == "foute input!")
{
dataGridView1.Rows[x].Cells[y].Style.BackColor = Color.Red;
}
}
}
}
instead of using the load im using addrows, so i dont have to write this when the form loads and when im adding a row
grz
|
|
|
|
|
hi everybody!!
iam using the create user wizard and login control provided in the Login tab of the toolbox in VS2005. iam using them for authentication in my application.
the problem is, i need to know how the password is encrypted and stored in the aspnetdb database when a new user is created. Also i need to know how the Login control authenticates a user, i.e., how does it verify the password entered while authenticating.
i would be grateful to anybody who can help me in this regard as my entire application depends on this. The reason why i want to know this is i need to encrypt a password using the same method and verify it with the encrypted password in the aspnetdb. This would give correct results only if both methods of encrypting are same.
thanks in advance to anybody and everybody who replies to this query. plz help me guys!!!!!!!
Sonu
|
|
|
|