+ Reply to Thread
Results 1 to 2 of 2

import pdf file

  1. #1
    Registered User
    Join Date
    09-28-2016
    Location
    Stuttgart
    MS-Off Ver
    2013
    Posts
    1

    import pdf file

    hi all,
    I have following code to import a pdf as a picture in my excel sheet. All is working but I would like when I import the pdf that it open me directly the same folder where my excel file is saved (ThisWorkbook.path). Even if I move the later the excel file. Also I want to open any pdf file in this folder, that why I use How can I do it?

    Sub pdf_aufmachen()

    ' pdf_aufmachen Makro
    '

    ActiveSheet.OLEObjects.Add(ClassType:="AcroExch.Document.7", Link:=False, _
    DisplayAsIcon:=False).Select
    End Sub

  2. #2
    Forum Expert Kenneth Hobson's Avatar
    Join Date
    02-05-2007
    Location
    Tecumseh, OK
    MS-Off Ver
    Office 365, Win10Home
    Posts
    2,573

    Re: import pdf file

    Welcome to the forum! I am not sure if you want a path from the pdf file or the workbook. If the former, then one can parse the SourceName if the file is linked. e.g.
    Please Login or Register  to view this content.
    Otherwise, browsing to a folder and picking a file in a dialog can just navigate to ThisWorkbook.path first.

+ 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. Macro - Open File Explorer, Select File, Import certain information from file
    By Drayde in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-25-2015, 08:58 AM
  2. Replies: 0
    Last Post: 05-28-2014, 02:45 AM
  3. [SOLVED] MACRO: Store name of selected file as string w/ import data file dialog box
    By AnnieMcken in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-13-2013, 02:13 PM
  4. [SOLVED] Macro - Master file to import data from another open file with variable file name
    By jdodz in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 12-10-2012, 10:56 PM
  5. [Ask] Import Text file And Call reference path file with Value Range.
    By dha_indra in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-29-2012, 11:09 PM
  6. File import - select file and import sheet(1) from closed workbook
    By Armitage2k in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-22-2011, 03:15 AM
  7. How do I import text file, analyze data, export results, open next file
    By Geoffro in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-06-2005, 04:06 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