+ Reply to Thread
Results 1 to 16 of 16

Dynamic Name Ranges and transferring data to new sheet

  1. #1
    Registered User
    Join Date
    07-17-2014
    Location
    New Hampshire
    MS-Off Ver
    2013
    Posts
    10

    Dynamic Name Ranges and transferring data to new sheet

    Good Evening Everyone,

    I am still learning all I can of Excel but I am still running into problems and need some programming help.

    I have an Orders database that documents several items that are sold. Upon hitting a create order button the data is transferred to a datasheet with a running total of all sales. I am using a dynamic name range to capture all lines of data to transfer to the total sheet. The problem I am having is that I need to generate a production report from this same date but not necessarily in the same order as on the order sheet.

    I understand that column names should be the same when transferring (or am I wrong) but the production report has additional data that is not a part of the main product input area on the order form. Any ideas on how I should tackle this?

    Thanks,

    Jeff

  2. #2
    Forum Expert p24leclerc's Avatar
    Join Date
    07-05-2010
    Location
    Québec
    MS-Off Ver
    Excel 2021
    Posts
    2,081

    Re: Dynamic Name Ranges and transferring data to new sheet

    a sample workbook would be really appreciated here. Try to attach one, please.
    Pierre Leclerc
    _______________________________________________________

    If you like the help you got,
    Click on the STAR "Add reputation" icon at the bottom.

  3. #3
    Registered User
    Join Date
    07-17-2014
    Location
    New Hampshire
    MS-Off Ver
    2013
    Posts
    10

    Re: Dynamic Name Ranges and transferring data to new sheet

    Template-Order_Matic 6 with Production Report_2.xlsm

    Here is what I have. I need to populate the production report with the data from the orders sheet.

    Jeff

  4. #4
    Forum Expert p24leclerc's Avatar
    Join Date
    07-05-2010
    Location
    Québec
    MS-Off Ver
    Excel 2021
    Posts
    2,081

    Re: Dynamic Name Ranges and transferring data to new sheet

    All your sheets are protected and you didn't give the password.
    You want to populate the production report but you probably have some specific parameters for this report:
    Month or date?
    Customer?
    Items?
    Are all the columns required for the production report in the All orders sheet?
    If not, where do you find them?
    Please, try to explain a bit more about this report.
    Thanks

  5. #5
    Registered User
    Join Date
    07-17-2014
    Location
    New Hampshire
    MS-Off Ver
    2013
    Posts
    10

    Re: Dynamic Name Ranges and transferring data to new sheet

    No password. Go into VBA editor, protect_unprotect module, and run the unprotect macro. I will log on later to address your other questions. What you see on the production report is what I need from the orders form. I will explain it in greater detail when I get home.

  6. #6
    Registered User
    Join Date
    07-17-2014
    Location
    New Hampshire
    MS-Off Ver
    2013
    Posts
    10

    Re: Dynamic Name Ranges and transferring data to new sheet

    On the Orders sheet there is 4 hidden columns (C thru F) that are transferred to the All Orders sheet.

    OK, all the data needed for the Production Report is NOT on the All Orders sheet. As seen on the Orders form I have a date ordered with our Order # as well as a Due Date and the Customer's PO #.
    These last two items are not saved to the All Orders sheet and is not needed for our order tracking.

    To go over each column on the Production Report
    Due = Due Date from Order Sheet
    Customer = Company (column F) from Order Sheet
    Contract/Order = PO Order # from Order sheet
    NSN/Code = Code from Order sheet
    Part Number = Description from Order Sheet
    Machine Shop = just a check block that can be set on the Production Sheet
    Quantity Ordered = Quantity from Order Sheet
    Quantity Shipped = May come from Invoice workbook in future but for now will be filled out on Production Report itself.
    Quantity Open = Formula based on ordered and shipped.
    Unit Cost = Unit price from Order Sheet
    Value = Total from Order Sheet
    Inspect and notes are filled out on the Production Report

    Something I was thinking about. What if I added two more hidden cells to pull the due date and customer po # like i am doing with the company and order date then then transfer that to the all orders sheet. would it then be easier to populate the production report with each item ordered?

    I do appreciate the help. Please let me know if you have any other questions. The VBA code protects the sheet after each order is processed. For now I just go into the Protect_Unprotect module and run the unprotect macro to unlock everything.

    Jeff

  7. #7
    Registered User
    Join Date
    07-17-2014
    Location
    New Hampshire
    MS-Off Ver
    2013
    Posts
    10

    Re: Dynamic Name Ranges and transferring data to new sheet

    Just an update. I was able to add the due date and customer po # to the all orders sheet by adding two more hidden columns to capture the data like i am the customer and date. Now do I copy the data to the production report when i copy the data to the all orders sheet or do I have to do it separately?

    Jeff

  8. #8
    Forum Expert p24leclerc's Avatar
    Join Date
    07-05-2010
    Location
    Québec
    MS-Off Ver
    Excel 2021
    Posts
    2,081

    Re: Dynamic Name Ranges and transferring data to new sheet

    Jeff, is the production report a summary of some sort or just a copy of all data?
    If it is a summary, what are the parameters?

  9. #9
    Registered User
    Join Date
    07-17-2014
    Location
    New Hampshire
    MS-Off Ver
    2013
    Posts
    10

    Re: Dynamic Name Ranges and transferring data to new sheet

    It is just a copy of the data. We print out the report to have a paper copy to plan our production and schedule our deliveries. All the manipulation of the data is done elsewhere in the workbook.

    Jeff

  10. #10
    Forum Expert p24leclerc's Avatar
    Join Date
    07-05-2010
    Location
    Québec
    MS-Off Ver
    Excel 2021
    Posts
    2,081

    Re: Dynamic Name Ranges and transferring data to new sheet

    If it is just a copy of the data, why don't you keep your production report up to date each time an order is placed like you do with the AllOrders sheet?
    You just have to modify the CopyCells macro to copy the cells you want into the production report.
    As the disposition of the columns are not the same as the Order sheet, you'll have to copy cell by cell to the right place.

  11. #11
    Registered User
    Join Date
    07-17-2014
    Location
    New Hampshire
    MS-Off Ver
    2013
    Posts
    10

    Re: Dynamic Name Ranges and transferring data to new sheet

    OK, so how do I set up the name range to grab the data in the order I need to place it on the production report? As you can see I use Orders to select all the data in the row from the Orders sheet to place on All Orders. As the Production Report is slightly different how do I grab the data in the correct order?

    Jeff

  12. #12
    Forum Expert p24leclerc's Avatar
    Join Date
    07-05-2010
    Location
    Québec
    MS-Off Ver
    Excel 2021
    Posts
    2,081

    Re: Dynamic Name Ranges and transferring data to new sheet

    try the following modified "CopyCells" macro
    You'll see a new section after the comment "Production report sheet
    It copies the data from the Order sheet to the production report.
    Please Login or Register  to view this content.
    Hope this helps

  13. #13
    Registered User
    Join Date
    07-17-2014
    Location
    New Hampshire
    MS-Off Ver
    2013
    Posts
    10

    Re: Dynamic Name Ranges and transferring data to new sheet

    Thank you for your help. It seems to be working well.

    Jeff

  14. #14
    Registered User
    Join Date
    07-17-2014
    Location
    New Hampshire
    MS-Off Ver
    2013
    Posts
    10

    Re: Dynamic Name Ranges and transferring data to new sheet

    Thank you for your help. It seems to be working well.

    Jeff

  15. #15
    Registered User
    Join Date
    07-17-2014
    Location
    New Hampshire
    MS-Off Ver
    2013
    Posts
    10

    Re: Dynamic Name Ranges and transferring data to new sheet

    Online-PC-Learning-Invoice-Generator Tutorial 6 test to pull data from orders.xlsm

    I have been trying to figure out how to pull the Order data back into the Invoice program to finish this project.

    On the Invoice sheet in the Invoice Program I want to pull the ordered data from the AllOrders sheet in the Orders Program when the Order No. in placed on the Invoice Sheet. I want to pull the customer name(the address information is being pulled via lookup from the Orders Program), as well as Quantity through Total from the AllOrders sheet to populate the Invoice sheet.

    I am trying not to have to duplicate data between both databases. I plan on deleting Products and Customers from the Invoice program and just have it in the Orders program. I really wanted to merge both programs together but that proved troublesome so I am trying to just link them together. I have read several articles on this type of data lookup but it just keeps confusing me. If you have any questions please let me know.

    Jeff

  16. #16
    Forum Expert p24leclerc's Avatar
    Join Date
    07-05-2010
    Location
    Québec
    MS-Off Ver
    Excel 2021
    Posts
    2,081

    Re: Dynamic Name Ranges and transferring data to new sheet

    Hi Jeff,
    here is a modification I did on your Invoice macro. I'm not sure it is the way you want it to work though.
    I thought the invoice was always done relative to an order. So all data are gathered from the AllOrders sheet and copied to the invoice sheet.
    All you need is the Order number and the macro gets the data.
    But if you want to manually invoice, the modification I did will not work for you.
    Anyway here it is.
    One thing I realized is that when you copy data from Invoice to InvoiceSummary, you don't copy the Order number so you are losing there relation. Is it important for you. I think it is but I don't know much about that.

    You have so many places in your code that reactivate the ScreenUpdating parameter to TRUE that I can't get it to FALSE so no one would see the openeing of the Order workbook. Maybe there is a way to do so, but I don't it know yet.
    Hope this helps

+ 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. Replies: 1
    Last Post: 07-25-2013, 05:09 PM
  2. Replies: 2
    Last Post: 07-17-2012, 09:18 PM
  3. VBA: Transferring Dynamic Array with data between functions
    By Sugarray in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-10-2012, 10:35 AM
  4. Summarizing/Copying dynamic ranges of data to new sheet?
    By Tomkat in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-08-2010, 01:53 PM
  5. Dynamic Sum from two ranges on another sheet.
    By grossly outnumbered in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-02-2009, 11:02 PM

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