+ Reply to Thread
Results 1 to 8 of 8

Autofill text based on drop-down selection in different cells (VBA)

  1. #1
    Registered User
    Join Date
    04-03-2012
    Location
    Canada
    MS-Off Ver
    Excel 2007
    Posts
    7

    Autofill text based on drop-down selection in different cells (VBA)

    I AM A BEGINNER,

    Can someone see why this programing does not work? I would like to have it fill in several cells with different contact information when i select a name...(email, office phone, cell number...).
    Right now i get a Run-time error "Method 'Value' of object 'Range' failed.

    If someone could take a look at this i would really appreciate it.

    Please Login or Register  to view this content.
    Last edited by GarryR; 04-04-2012 at 11:28 AM.

  2. #2
    Registered User
    Join Date
    04-03-2012
    Location
    Canada
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Autofill text based on drop-down selection in different cells (VBA)

    Maybe There is better way all togheter to do this???

  3. #3
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Autofill text based on drop-down selection in different cells (VBA)

    Hi GarryR
    Welcome to the Forum!
    Remove the code from the ThisWorkBook Module and place this code in Sheet1 Module
    Please Login or Register  to view this content.
    John

    If you have issues with Code I've provided, I appreciate your feedback.

    In the event Code provided resolves your issue, please mark your Thread as SOLVED.

    If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.

  4. #4
    Registered User
    Join Date
    04-03-2012
    Location
    Canada
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Autofill text based on drop-down selection in different cells (VBA)

    WOW!! thanks it works!

    And if i want to apply this same kind of programming to cell (J4) is it just a matter of copying the same thing and changinf the cell refereences after the end sub?

  5. #5
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Autofill text based on drop-down selection in different cells (VBA)

    Hi GarryR

    Since you have the lists and Named Ranges created, this is how I'd suggest you approach it
    Please Login or Register  to view this content.

  6. #6
    Registered User
    Join Date
    04-03-2012
    Location
    Canada
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Autofill text based on drop-down selection in different cells (VBA)

    That last code dosent seem to do anything...

  7. #7
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Autofill text based on drop-down selection in different cells (VBA)

    Hi GarryR

    Sorry about that, Events were getting turned off but not back on...try this
    Please Login or Register  to view this content.

  8. #8
    Registered User
    Join Date
    04-03-2012
    Location
    Canada
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Autofill text based on drop-down selection in different cells (VBA)

    Amazing John.

    Works like a charm!

    Thank you very much.

+ 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