I am new to Mr. Excel, but I have found some helpful things in the past via google searching. I am hoping I can get some help directly associated with my dilemma for a personal project I am working on. I'll try to be as accurate & thorough as possible.
Currently in my excel workbook I have two tabs. Tab one is strictly for a database table that information can be pulled from via the "Vlookup" function. Column "A" is a list of part numbers, "B" is the part description for the part number from "A", "C" has a formulated file path from columns "D, A, & F" (D holds the folder path G:\\SAMPLE FOR TESTING\, A holds the file name (which is the part number), & F holds the file extension = .docx). Currently these paths references only WORD documents, but will at some point hold information for other documents (Excel, PDF, and not sure how many others).
So, tab two I am using to look up information on tab one at random that will extract the information and insert it to the respective cells. However, the information in column "B" has been coupled with the hyperlink reference from "C" from tab one using the hyperlinks function. This was achieved by using the following formula where "ITEM HYPERLINKS" is reference to tab one........ The formula ties the hyperlink to the displayed text from column "B" allowing for the exact path to be masked/hidden by the text (part description) displayed in the cell(s) of column "B".
=HYPERLINK(VLOOKUP(A2,'ITEM HYPERLINKS'!A:C,3,FALSE),VLOOKUP(A2,'ITEM HYPERLINKS'!A:C,2,FALSE))
I can click on the link and it follows the path & opens the file in Word without any problems.
The problem:
I have set up a Control Button and have tried to set it up with a Macro that will allow for the path to be followed, the document to open, then the document print, the document close, the program close, then the next cell and continues until all documents have printed in order.
However, the process keeps telling me to debug.
Any ideas on coding that will allow for the macro to follow the formulated hyperlink and perform the functions to completion?
Thanks in advance for your any help! I've been stuck on this one for a while.
Currently in my excel workbook I have two tabs. Tab one is strictly for a database table that information can be pulled from via the "Vlookup" function. Column "A" is a list of part numbers, "B" is the part description for the part number from "A", "C" has a formulated file path from columns "D, A, & F" (D holds the folder path G:\\SAMPLE FOR TESTING\, A holds the file name (which is the part number), & F holds the file extension = .docx). Currently these paths references only WORD documents, but will at some point hold information for other documents (Excel, PDF, and not sure how many others).
So, tab two I am using to look up information on tab one at random that will extract the information and insert it to the respective cells. However, the information in column "B" has been coupled with the hyperlink reference from "C" from tab one using the hyperlinks function. This was achieved by using the following formula where "ITEM HYPERLINKS" is reference to tab one........ The formula ties the hyperlink to the displayed text from column "B" allowing for the exact path to be masked/hidden by the text (part description) displayed in the cell(s) of column "B".
=HYPERLINK(VLOOKUP(A2,'ITEM HYPERLINKS'!A:C,3,FALSE),VLOOKUP(A2,'ITEM HYPERLINKS'!A:C,2,FALSE))
I can click on the link and it follows the path & opens the file in Word without any problems.
The problem:
I have set up a Control Button and have tried to set it up with a Macro that will allow for the path to be followed, the document to open, then the document print, the document close, the program close, then the next cell and continues until all documents have printed in order.
However, the process keeps telling me to debug.
Any ideas on coding that will allow for the macro to follow the formulated hyperlink and perform the functions to completion?
Thanks in advance for your any help! I've been stuck on this one for a while.