|
Remove the selected one, and re-insert it one position higher (don't forget to account for being at the top or bottom of the listbox). Also, you can avoid flickering if you turn off updates, remove/insert, and then turn updates back on.
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
John Simmons / outlaw programmer wrote: Remove the selected one, and re-insert it one position higher (don't forget to account for being at the top or bottom of the listbox
Fair idea. Thanks John
John Simmons / outlaw programmer wrote: if you turn off updates, remove/insert, and then turn updates back on.
I can't find how to turn off updates. Do you mean to calling SuspendLayout() and ResumeLayout() ?
|
|
|
|
|
It's actually BeginUpdate() and EndUpdate() ...
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
Thanks. I will take a look at that
|
|
|
|
|
Hi,
i'm Trying to Implement the Ctrl+S (save)
Do i need to Monitor the KeyPress Events and check The Last Two Keys Pressed
or there is an easer way ( a Buit -In )
Have Fun
Never forget it
|
|
|
|
|
private void form_KeyDown(object sender, KeyEventArgs e)
{
if (e.Control && e.KeyCode == Keys.S)
|
|
|
|
|
Thanks a Lot
Have Fun
Never forget it
|
|
|
|
|
KeyUp's (or KeyDown's) KeyEventArgs has a Control property, then just check KeyCode for S.
|
|
|
|
|
If you have a menu on the form, just set the shortcut to Ctrl+S on your Save item.
|
|
|
|
|
Wow, Thanks A lot
i Never Knew this Feature Exsits
Thanks Agian
Have Fun
Never forget it
|
|
|
|
|
I What some UserControl
each with a Menu
the Funny thing is that it always selects the last and perform the Action on it
any IDEA
Have Fun
Never forget it
|
|
|
|
|
You can't have the same shortcut assigned to different actions. You need to supply a different shortcut.
|
|
|
|
|
Thanks
Have Fun
Never forget it
|
|
|
|
|
Hi,
i'm trying to Lock The Form so that the user would'nt be able to Move it
How can i Do It, i'd tried a variaty of properties, non helped
any Suggestions
Have Fun
Never forget it
|
|
|
|
|
Set the FormBorderStyle property to FormBorderStyle.None
Giorgi Dalakishvili
#region signature
my articles
#endregion
|
|
|
|
|
Thanks A Lot
I Never Thought to Try This Thanks Again
Have Fun
Never forget it
|
|
|
|
|
Or if you want to keep the titlebar and other stuff:
class Form1
{
Point pos;
public Form1()
{
InitializeComponent();
this.Pos=new Point(this.Left,this.Top);
this.Move+=Form1_Move;
}
void Form1_Move(object sender, EventArgs e)
{
this.Left=pos.X;
this.Top=pos.Y;
}
}
|
|
|
|
|
Thanks
Have Fun
Never forget it
|
|
|
|
|
I want to define the object type in the ArrayList to be string - i dont want to leave is as Object.
How to do it ?
|
|
|
|
|
You can't do this in ArrayList. Use List<string> instead
|
|
|
|
|
You could just use a string[] array, or use List<string>...
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
I want to create ActiveX Control for my windows application....
how can i do that..Bcoz i'm the new one for ActiveX.......
|
|
|
|
|
Check the following link:
http://www.c-sharpcorner.com/UploadFile/dsandor/ActiveXInNet11102005040748AM/ActiveXInNet.aspx
~Dave
Dave Traister
Software Engineer
ComponentOne LLC
www.ComponentOne.com
|
|
|
|
|
hi Dave
Thank u for ur reply..Here the example is simply good i can understand....
But i want to post my ActiveX application to Internet is this example is correct for that one or not........
|
|
|
|
|
Hi Guys. I have read in a few post about this but for the life of me I can't find any of them and have tried searching the posts about this but don't get any results returned.
I have an application that reads data and writes that data to an Excel sheet. Problem I have is that when I change to another application while the process is running and return to the form it just shows a blank white form with just the progressbar and percentage updating.
Now, I know I can put the other process into a sepperate Thread but that means me chasnging the whole layout of my application as the work is done in a button even.
Is there any other way I can get the form to refresh and to show me the form properly?
Thanks in advance.
Excellence is doing ordinary things extraordinarily well.
|
|
|
|