Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

VB.net Windows Forms change default event generated when double clicking a panel

Posted on 2013-01-08
5
Medium Priority
?
299 Views
Last Modified: 2013-01-10
Hi

I have several forms where I need to add code behind the click event of a panel
When I cretae  a fresh Windows form and add a few panels to it then double click ecah one
it generates the Paint event. Is it possible to changea setting so that the click event is generated. I have a few hundred panels to do this to.
Thanks
0
Comment
Question by:Murray Brown
5 Comments
 
LVL 2

Expert Comment

by:Mohamed_allabakash
ID: 38757984
You can create the User Defined Froms and panels and you can utilize it.
0
 
LVL 2

Expert Comment

by:Mohamed_allabakash
ID: 38757985
You can create the User Defined Forms and panels and you can utilize it
0
 
LVL 143

Assisted Solution

by:Guy Hengel [angelIII / a3]
Guy Hengel [angelIII / a3] earned 1000 total points
ID: 38758000
you would have to override the panels class to specify the defaultevent:
http://www.vb-helper.com/howto_net_default_event.html
0
 
LVL 83

Accepted Solution

by:
CodeCruiser earned 1000 total points
ID: 38759436
Work around is to not double click the panel. Just select the panel, then in properties window, double click the Click event and a stub handler will be created for Click event.
0
 

Author Closing Comment

by:Murray Brown
ID: 38762038
Thanks for the advice
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Want to learn how to record your desktop screen without having to use an outside camera. Click on this video and learn how to use the cool google extension called "Screencastify"! Step 1: Open a new google tab Step 2: Go to the left hand upper corn…
Screencast - Getting to Know the Pipeline

877 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question