Solved

How to make an imageButton fire both CommandEventsArgs and ImageClickEventArgs?

Posted on 2006-07-18
2
1,267 Views
Last Modified: 2012-06-27
I have an imageButton control on my page.  When it is clicked I need to retrieve the following things:

  1. x coordinate
  2. y coordinate
  3. commandArgument

The first 2 are found in ImageClickEventArgs, but the 3rd is in CommandEventArgs.  Is it possible to retrieve all three?

I'm working in VB by the way...

Thanks in advance.
0
Comment
Question by:Rouchie
2 Comments
 
LVL 14

Accepted Solution

by:
Ramuncikas earned 500 total points
ID: 17128617
Command argument is the one that is assigned to imageButton itself. So you can do like this in your imagebutton's Click event:

Dim CommandArg as String
CommandArg = imageButton.CommandArgument

Dim _X As Integer
_X = e.X

Dim _Y As Integer
_Y = e.Y
0
 
LVL 25

Author Comment

by:Rouchie
ID: 17128830
Thank you very much!
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Just a quick little trick I learned recently.  Now that I'm using jQuery with abandon in my asp.net applications, I have grown tired of the following syntax:      (CODE) I suppose it just offends my sense of decency to put inline VBScript on a…
IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
This video discusses moving either the default database or any database to a new volume.
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

707 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now