strpath

  1. M

    VBA to create PDF's of two worksheets when a condition is met

    Hi, I hope that you can help me once again.... I have a VBA code which produces a PDF of a worksheet and attaches it to an email (with other details in the email found in the worksheet) when a single condition is met in cell Y32 of the active worksheet. I want to add some additional VBA to...
  2. I

    VBA to open a PDF in another location.

    Hi All I have the following code that searches a network folder for a PDF doc based on the number in a cell and opens it if one exists: Sub OpenPDF_3() Dim strPath As String Dim strFileName As String strPath = "\\172.27.154.13\D$\Excel Dashboard\Inventory" If Right(strPath...
  3. S

    Mkdir on network location causes a debug error

    I have two snippets of code that work just fine locally but seem to have issues when run over the network. When I run the code from within my LAN, it captures a directory location (Path), checks to see if that location exists, and if it doesn't, then make the correct directory tree. The...
  4. M

    Is there a way to trigger a sub from inside another sub?

    I have a commandbutton_click sub that I would like to code so that a folder is created. Is there a way to call on a function/sub and to have it run its code and then go back to the commandbutton_click sub to finish? The function is below... Function MkDir(strDir As String, strPath As String)...
  5. C

    Loop Macro to all sheet

    Hi Team, My below code is running on activesheet how to loop through all sheets except two sheet Sub PDFSheetNoPrompt() Dim wsA As Worksheet Dim wbA As Workbook Dim strName As String Dim strPath As String Dim strFile As String Dim strPathFile As String Dim myFile As Variant On Error GoTo...
  6. J

    Conversion to Mac issue with VBA

    I have a workbook with VBA built in, built in Excel 2016, that is not working on the Mac version of Excel 2016... Public Sub GenerateContact() Dim wsA As Worksheet Dim wbA As Workbook Dim strTime As String Dim strName As String Dim strPath As String Dim strClient As String Dim strFile As...
  7. B

    Signature Time Stamp in Excel cells

    Hi All, I have the code below which converts the activesheet and the sheet called 'total' into pdf. I would like to capture the current username who is logged in and convert that to their full name and capture the date/time stamp that the macro was run while converting to pdf and insert into...
  8. B

    Moved PDFs from one location to another

    Hi. Not a pro coder but this is what I have so far. Sub SaveasPDF() Dim wsA As Worksheet Dim wbA As Workbook Dim strName As String Dim strPath As String Dim strFile As String Dim strPathFile As String Dim myFile As Variant On Error GoTo errHandler Set wbA = ActiveWorkbook Set wsA =...
  9. B

    Excel to PDF Naming convention

    Hi. I have the macro below which upon running converts the active sheet in excel to pdf. Sub SaveasPDF() Dim wsA As Worksheet Dim wbA As Workbook Dim strName As String Dim strPath As String Dim strFile As String Dim strPathFile As String Dim myFile As Variant On Error GoTo errHandler Set wbA...
  10. D

    vba to copy shape and paste it into folder

    Hi, I am struggling with the below vba code. I have a worksheet that has attached shapes which are pdf's and this worksheet belongs to a country which is in cell B1 (there are more worksheets for more countries). The objective of the code is for each shape needs to be copied one by one and...
  11. tyija1995

    Importing CSVs to Access with VBA

    Hey, I have 55 CSV files that I want to export in to Access, I am currently using a macro but it only takes the first file from the directory, I need a loop to take all of the files from the same directory but I am not sure how to implement it, any help would be appreciated. I am using the...
  12. F

    Macro that creates separate .pdfs

    Hi all, I am looking to create a macro that takes each sheet I have selected and turns it into a separate .pdf, and also names the .pdf. For example, if there are five sheets in my workbook, but I only have three sheets selected, I would want those three sheets to be created into three...
  13. B

    pdf mACRO

    Hello, I am attempting to add a specific file (C:\user\bordiway\desktop\dashboards) for this macro to pdf to. I cant seem to get it to work. Can someone help? Thank you in advance. Public Sub Print_to_PDF_Click() Dim wsA As Worksheet Dim wbA As Workbook Dim strTime As String Dim strName As...
  14. tlc53

    Combine VBA Codes together

    Hi there, I currently have VBA code under both Module and the Worksheet which I would like to combine under one macro to run together. Independently, they all work fine. Below are the codes and in the order I would like them to run. All information is located on Sheet81 but the macro will be run...
  15. R

    Upload multiple Object into Excel - Code amendment

    Hi Everyone, I have a code to upload an object into excel. However below code i am able to upload only one document by clicking on button. Please help me in amend the code by which i can upload multiple file. note - other file path would remain same. However name could be sample2.pdf or...
  16. R

    Excel VBA to save file as PDF and email

    I am trying to make a VBA to save a file and email it as an attachment. I have gotten it to save file as pdf. But cant for the life of me get it to send as attachment through outlook Code for save is Sub Save_as_PDF() Dim wsA As Worksheet Dim wbA As Workbook Dim strName As String Dim...
  17. R

    how to set hidden sheet as object

    Hello, The code below works fine for me. Now I just want to get output in PDF of "PDFVersion" Sheet which is now "very hidden". So without activating or opening it I want to get PDF of the said sheet. Note: I don't want user can see the said sheet or able to unhide it so I made it very hidden...
  18. A

    VBA - loop on pivot filter values, save to .pdf

    Hi there I need some help on a VBA loop In PowerPivot, I've created a data model based pivot, which will be used to create .pdf reports for hundreds of items. I want to make a VBA loop so I won't have to filter and save to .pdf for each individual value in the filter. The loop would be...
  19. E

    Save as PDF

    Hello. I have this code wich works fine for every sheet, I'd like to make it to save all sheets with one click only. I need all the sheets in the workbook to be saved separately with the sheet name and the year given in a cell like the code shows. It works like a charm but I have to go on page...
  20. O

    Save sheet as PDF in A specific path (folder)

    Dear all, I copy some VBA code that save the active sheet as pdf, it's great but I want to change the path of the folder ( not in a active folder), Here is the code : Sub PDFActiveSheetNoPromptCheck() Dim wsA As Worksheet Dim wbA As Workbook Dim strName As String Dim strPath As String Dim...

Some videos you may like

This Week's Hot Topics

Top