+ Reply to Thread
Results 1 to 5 of 5

How cal i populate the Dialog Box when the Right Click mouse Button

  1. #1
    Registered User
    Join Date
    12-20-2011
    Location
    cheenai
    MS-Off Ver
    Excel 2007
    Posts
    68

    How cal i populate the Dialog Box when the Right Click mouse Button

    Hi All

    I am new to excel Vba .In My project When i right click in the sheet the Dialog Box Should display.

    How can i do it

    Thanks in advance

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: How cal i populate the Dialog Box when the Right Click mouse Button

    Which dialog box? The sheet module has before right click event

    Please Login or Register  to view this content.
    Workbook Event code should be added to the workbook code module:

    Copy the Excel VBA code that you want to use
    Select the workbook in which you want to store the code
    Hold the Alt key, and press the F11 key, to open the Visual Basic Editor
    In the Project Explorer, find your workbook, and open the list of Microsoft Excel Objects
    Right-click on the ThisWorkbook object, and choose View Code
    Where the cursor is flashing, choose Edit | Paste
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Registered User
    Join Date
    12-20-2011
    Location
    cheenai
    MS-Off Ver
    Excel 2007
    Posts
    68

    How cal i populate the Dialog Box when the Right Click mouse Button

    Thanks Roy UK your coding is working fine and good.

    but i have one problem i have 10 sheets.

    When i click the right button in any 10 sheets

    the user form should appear.

    It only works in single sheet.

    How can i do it.

    Thanks in advance.

  4. #4
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: How cal i populate the Dialog Box when the Right Click mouse Button

    Please Login or Register  to view this content.

    Workbook Event code should be added to the workbook code module:

    Copy the Excel VBA code that you want to use
    Select the workbook in which you want to store the code
    Hold the Alt key, and press the F11 key, to open the Visual Basic Editor
    In the Project Explorer, find your workbook, and open the list of Microsoft Excel Objects
    Right-click on the ThisWorkbook object, and choose View Code
    Where the cursor is flashing, choose Edit | Paste

  5. #5
    Registered User
    Join Date
    12-20-2011
    Location
    cheenai
    MS-Off Ver
    Excel 2007
    Posts
    68

    Re: How cal i populate the Dialog Box when the Right Click mouse Button

    Thanks royuk

    Its worsk fine and good.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1