473,561 Members | 3,876 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how to know the user press the left button and the right button at the same time?

i use

arg.button==( MouseButtons.Le ft+MouseButtons .Right)

but the system promote the the type cant +

who can help me ~
Nov 15 '05 #1
1 1468
Hi there,
have you tried using the "bitwise or" operator (|) instead?

According to MSDN (look for "MouseButto ns Enumeration"):

"Specifies constants that define which mouse button was pressed.
This enumeration has a FlagsAttribute attribute that allows a bitwise
combination of its member values."
Good luck!


Reply-To: "vulgate" <vu*******@hotm ail.com>
From: "vulgate" <vu*******@hotm ail.com>
Subject: how to know the user press the left button and the right button at the same time?Date: Sat, 15 Nov 2003 22:42:50 +0800
i use

arg.button== ( MouseButtons.Le ft+MouseButtons .Right)

but the system promote the the type cant +

who can help me ~

Nov 15 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

by: |-|erc | last post by:
when a user clicks back to get to my site, I want it to run a javascript function. can you detect when the FORWARD button is greyed out? Herc -- I call3d this fugly and I'm proud www.supernerd.com.au/~gray77/kath1.jpg
by: Chris Millar | last post by:
I have a user control that i wish to extend to change the date when the user selects the numeric up down button. The code explains itself, hope someone can help. any ideas appreaciated.. Chris. code :
by: DotNetMania | last post by:
panel has not Key press event... that's why.. if i have to figure invoking any event out when panel clicked it is so difficult...what button is clicked .... button of Mouse like .. Left, Middle, and Right... how can i distiguish...
by: teddysnips | last post by:
I have to write an application to do some data cleansing. It's a Contact database, but over a number of years there are multiple companies which are all essentially the same entity. For each company there are also multiple contacts, some of which may be congruent. It's a very simple app. with only two forms. The first form shows two...
by: planetthoughtful | last post by:
Hi All, I have a relatively simple web user control I've included in a page that simply presents 3 drop down lists and a submit button, that I use as a date picker (ie one list for day, one for month, one for year). I have the control registered on the page and it displays fine, but I haven't managed to work out how to get the value(s)...
by: Garry Jones | last post by:
I asked this earlier and received a tip of going to Joomla. Problem is according to the gurus in their forums I need to rewrite the entire site so that Joomla becomes the core. As I am on 700+ pages its not practical as I only need to open up two pages for user editing. I have a website consisting of pages made up of php segments using the...
by: Danny | last post by:
Hi I want to be able from my csharp button to start an application ( which I can do) and then somehow send a message to the win32 application that says "press the button" The win32 application ( borland app) has a button on it that I need to click in order for it to start correctly. Is this possible from csharp?? thanks
by: Max2006 | last post by:
Hi, I have a simple form with a button on it. After a button click postback, anytime user press F5 (browser page refresh), the button's OnClick event handler is called again without the button actually be pressed! Is this a bug in ASP.NET? Is there any technique to prevent that? I know that a Response.Redirect to the same page solves...
by: arpitwcc | last post by:
i am making u user login page where there are few buttons at the top of the page like Home, Services, About Us etc and below it i hav Username -- textbox Password --textbox Login --image button... now after a user hav filled the password box and when he press the enter key then the 'Login' should fire..... but this button is not...
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.