+ Reply to Thread
Results 1 to 12 of 12

Invoice to PDF - Dropdown List selection automatically.

  1. #1
    Registered User
    Join Date
    02-21-2015
    Location
    London
    MS-Off Ver
    2010
    Posts
    64

    Invoice to PDF - Dropdown List selection automatically.

    Hi All,

    I need a VBA code where it select customers from dropdown list one after another till the data in "Invoice Master Data" and save as PDF in particular folder.
    Process:
    I will update "Invoice Master Data" sheet.
    I have create dropdown list in Cell B1 ("Invoice Format")
    "Invoice Format" F7 cell has a link from "Invoice Master Data" sheet
    Whenever I select "Invoice Format" C2 values amount will change
    VBA would choose customer's name from C2 cell one after another automatically and save as PDF in "C:\sales data\".
    in the above example
    Three invoice will generate automatically and saved in above path
    Invoice_to_PDF.xlsx

    Thanks

  2. #2
    Forum Expert
    Join Date
    08-16-2015
    Location
    Antwerpen, Belgium
    MS-Off Ver
    2007-2016
    Posts
    2,380

    Re: Invoice to PDF - Dropdown List selection automatically.

    Try something like this

    Please Login or Register  to view this content.
    Kind regards
    Leo
    Attached Files Attached Files

  3. #3
    Forum Expert
    Join Date
    08-16-2015
    Location
    Antwerpen, Belgium
    MS-Off Ver
    2007-2016
    Posts
    2,380

    Re: Invoice to PDF - Dropdown List selection automatically.

    I think you need more in the name of PDF such as date or invoice number

  4. #4
    Registered User
    Join Date
    02-21-2015
    Location
    London
    MS-Off Ver
    2010
    Posts
    64

    Re: Invoice to PDF - Dropdown List selection automatically.

    Hi LeoTaxi,

    I need PDF file name as "Invoice Format" C2 values (Example: 201602 FEB Customer #1, 201602 FEB Customer #2). Year and Month would pick from "Invoice Master Data" Cell A1. In future If I needed for March I will mention here.

    I have noticed in the PDF file all are having same Customer #1 1 of 3, Customer #1 2 of 3 and Customer #1 3 of 3. Macro should pick all customer number with respect to their values. In the above macro it is picking up only one customer data three times. Could you remove "1 of 3" , "2 of 3", "3 of 3" after the file name.

    Macro would pick up three customers data one after another from the dropdown list.

    Thanks for all your help once again.

  5. #5
    Registered User
    Join Date
    02-21-2015
    Location
    London
    MS-Off Ver
    2010
    Posts
    64

    Re: Invoice to PDF - Dropdown List selection automatically.

    Macro would pick up three customers data one after another from the dropdown list and save as PDF.

    I have taken only three customers as example. There may be cases it runs to morethan 100...

  6. #6
    Forum Expert
    Join Date
    08-16-2015
    Location
    Antwerpen, Belgium
    MS-Off Ver
    2007-2016
    Posts
    2,380

    Re: Invoice to PDF - Dropdown List selection automatically.

    more like this

    Please Login or Register  to view this content.

    Kind regards
    Leo
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    02-21-2015
    Location
    London
    MS-Off Ver
    2010
    Posts
    64

    Re: Invoice to PDF - Dropdown List selection automatically.

    Hi Leo,

    Could you write VBA for attached one more requirement for salary format.

    Thanks in advance
    Salary format.xlsm
    Attached Files Attached Files

  8. #8
    Forum Expert
    Join Date
    08-16-2015
    Location
    Antwerpen, Belgium
    MS-Off Ver
    2007-2016
    Posts
    2,380

    Re: Invoice to PDF - Dropdown List selection automatically.

    Hi Excel_Pa

    i made a dynamic namedrange for the names, you can see this in the name manager,
    this way the validation list is always up to date.

    For the formula in A31 you have to change this, you refer to column 25
    and only 24 columns are available in the matrix C:Z

    Please Login or Register  to view this content.


    Kind regards
    Leo
    Attached Files Attached Files

  9. #9
    Registered User
    Join Date
    02-21-2015
    Location
    London
    MS-Off Ver
    2010
    Posts
    64

    Re: Invoice to PDF - Dropdown List selection automatically.

    You are Superb!. Every time your giving me exactly the way I think. And also some suggestion and advises. Thanks a lot for your help....

  10. #10
    Registered User
    Join Date
    02-21-2015
    Location
    London
    MS-Off Ver
    2010
    Posts
    64

    Re: Invoice to PDF - Dropdown List selection automatically.

    Hi Leo,

    I need one more suggestion. Need modification in VBA code. In "Master Employee details" certain employee we will not issue salary slip due to they are no more working with us. So I do use "Filter" option in excel to hide their details.
    For example Name 1 is not working with us. I will uncheck his name in "Filter" option. So VBA will not print his salary slip.

    Thanks in advance.

  11. #11
    Forum Expert
    Join Date
    08-16-2015
    Location
    Antwerpen, Belgium
    MS-Off Ver
    2007-2016
    Posts
    2,380

    Re: Invoice to PDF - Dropdown List selection automatically.

    Hello Excel_Pa

    this will take only vissible rows

    Please Login or Register  to view this content.
    Kind regards
    Leo

  12. #12
    Registered User
    Join Date
    02-21-2015
    Location
    London
    MS-Off Ver
    2010
    Posts
    64

    Re: Invoice to PDF - Dropdown List selection automatically.

    Thanks a lot Leo. Can I have your email id......

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Creating a dynamic dropdown list of a selection of a master list
    By RooMar in forum Excel Formulas & Functions
    Replies: 20
    Last Post: 05-15-2015, 05:27 AM
  2. Limit dropdown list based on selection from another list
    By msmetal in forum Access Tables & Databases
    Replies: 5
    Last Post: 01-23-2015, 11:22 PM
  3. Make same selection for multiple drop down list and clear all for all dropdown list
    By salomip13 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-30-2014, 01:34 PM
  4. Automatically Hide Rows Based On Dropdown Box Selection
    By tstram in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-21-2014, 06:13 PM
  5. Cull dropdown list options based on selection in another dropdown
    By Kiffar in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-20-2012, 01:53 AM
  6. Replies: 2
    Last Post: 09-21-2011, 09:21 AM
  7. enter data automatically in userform depending on dropdown selection
    By ImboJones in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-18-2010, 12:38 AM

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