+ Reply to Thread
Results 1 to 10 of 10

CONST range macro run functions based on range

  1. #1
    Registered User
    Join Date
    08-28-2011
    Location
    Australia
    MS-Off Ver
    2010
    Posts
    11

    CONST range macro run functions based on range

    Hi Guys,

    The idea of the macros below is this.

    Macro1:
    when you click on any of these cells place user info in a cell

    Macro2:
    When you click on this other range of cells change the value of this cell to something else

    The problem is making both work in one sheet, if you can think of a way to do this I would appreciate your help.

    Regards, Jaems


    Macro 1:


    Please Login or Register  to view this content.
    FYI esigncell is just a public function to pick up some user info as follows
    Please Login or Register  to view this content.
    Macro2

    This code also works but I want the two combined for one range do the below, for the other range of cells do the one above.
    Please Login or Register  to view this content.

  2. #2
    Forum Expert pike's Avatar
    Join Date
    12-11-2005
    Location
    Alstonville, Australia
    MS-Off Ver
    2016
    Posts
    5,342

    Re: CONST range macro run functions based on range

    Hi jdeverich
    Try something like....
    Please Login or Register  to view this content.
    Last edited by pike; 12-22-2011 at 03:28 AM. Reason: WS_RANGETwo missed one
    If the solution helped please donate to RSPCA

    Site worth visiting: Rabbitohs

  3. #3
    Registered User
    Join Date
    08-28-2011
    Location
    Australia
    MS-Off Ver
    2010
    Posts
    11

    Re: CONST range macro run functions based on range

    Access form Template - upload.xlsm

    I think we are getting closer however somewhere the code is missing the priciple only to look at the target cells, this is where I got stuck also. The function starts looking at every cell not just the ones selected in the range.

    If anyone has an idea appreciate the help.

    Regards, James.

  4. #4
    Forum Expert pike's Avatar
    Join Date
    12-11-2005
    Location
    Alstonville, Australia
    MS-Off Ver
    2016
    Posts
    5,342

    Re: CONST range macro run functions based on range

    Ho Ho Ho

    tested this one

    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    08-28-2011
    Location
    Australia
    MS-Off Ver
    2010
    Posts
    11

    Re: CONST range macro run functions based on range

    Access form Template - upload.xlsm
    Hi Pike,

    Still having trouble think when I take out the "const as string" expression the function stops continuing to watch those cells waiting for someone to click on the cell. So when applying the set caommand as your alternative nothing happens when you click on the cell, the cell is no longer working like a button.

    Tricky one!

    Regards, James.
    Attached Files Attached Files

  6. #6
    Forum Expert pike's Avatar
    Join Date
    12-11-2005
    Location
    Alstonville, Australia
    MS-Off Ver
    2016
    Posts
    5,342

    Re: CONST range macro run functions based on range

    which cell?

    Please Login or Register  to view this content.

  7. #7
    Forum Expert pike's Avatar
    Join Date
    12-11-2005
    Location
    Alstonville, Australia
    MS-Off Ver
    2016
    Posts
    5,342

    Re: CONST range macro run functions based on range

    It works for me in the cells in the intersections

  8. #8
    Registered User
    Join Date
    08-28-2011
    Location
    Australia
    MS-Off Ver
    2010
    Posts
    11

    Re: CONST range macro run functions based on range

    Really? In my sheet it seems to run both functions regardless which cell I click. If its not too much trouble would you mind to upload the file you tested on?

    Thanks Heaps!

    James.

  9. #9
    Forum Expert pike's Avatar
    Join Date
    12-11-2005
    Location
    Alstonville, Australia
    MS-Off Ver
    2016
    Posts
    5,342

    Re: CONST range macro run functions based on range

    Try this the attaachment .. If it dosent work I dont know what you are doing so can you expand on the explination
    Please Login or Register  to view this content.
    Access form Template - upload2 Test.zip
    Attached Files Attached Files

  10. #10
    Forum Expert pike's Avatar
    Join Date
    12-11-2005
    Location
    Alstonville, Australia
    MS-Off Ver
    2016
    Posts
    5,342

    Re: CONST range macro run functions based on range

    are your named ranges in esign correct?

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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