path

  1. J

    VBA code to attach a Single file to different Cells on Multiple Sheets

    Hi all, I am a complete novice with VBA but I am loving the learning curve. I have been searching for ever for a solution to my post but I have been unable to find one. At the moment I have put together the code below that works but the issue with it is that you need to keep selecting the folder...
  2. J

    VBA: how to create new txt file name?

    The code below demonstrates how I wanted to create a new txt file name. But apparently, GetOpenFilename works only for existing files. (That is, when I enter a non-existing file name, I get the error "File not found".) How can I get an API like GetOpenFilename, but for entering non-existing...
  3. J

    Extract File Name from a Full Path in a Cell

    I need to see how to extract on the file name from a columns that contains the full path using Power Query. C:\Users\Desktop\Test\PMOD-0001.doc Thanks,
  4. VBE313

    What is wrong with my code? The line that is not responding is underlined and bolded.

    Dim path1 As String Dim Filename1 As String Application.ScreenUpdating = False path1 = Range("I7").Text Range("A1:f40").Select Selection.Copy Sheets("Laser").Select Sheets.Add After:=ActiveSheet Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone...
  5. VBE313

    File Name and Path refer to cells

    Is there a way to change the path name depending on what the user types in? I know you can do that with the file name.
  6. J

    build source file path through multiple parameters?

    Hi all, I'm trying to learn how i might be able to use parameters to build my source file paths for a variety of queries using Power Query... I think i'm most of the way there, but getting tripped up on the last one, which is a query type parameter that i want to generate a list of values...
  7. M

    Auto save problems with a Excel Dashboard over a mounted share directory.

    I hope somebody can be of assistance as i am rather lost. My issue is the following. The company is deploying a custom excel dashboard to access file shares and incorporate several quote forms that the user can fill and save the information. The xlsx dashboard and fileshare directory is...
  8. C

    VLOOKUP asking for path update, where is the error?

    Range("F26").Select ActiveCell.FormulaR1C1 = _ "=VLOOKUP(RC[-1],'F:\infestor profiles\UK Holdings BP\[Things things things.xlsx]Sheet1'!C3:C5,2,FALSE)" Range("G26").Select ActiveCell.FormulaR1C1 = _ "=VLOOKUP(RC[-2],F:\infestor profiles\UK Holdings BP\[Things things...
  9. T

    Saving Workbook as .pdf with specific path and filename

    I have a workbook template that saves to a specific path and filename when the save button is activated. I'd like it to also save it as a .pdf to a different path with the same filename when the save button is activated. I hope that makes sense and I've posted this correctly... The existing...
  10. N

    How to avoid #value when some files don't exist yet?

    Hi all. I have the following formula in a sheet I update each month: =IFS(TEXT(NUMBERVALUE(P2);"00")="01";'K:\MD\_data\Fim do Mês\Data\2019\2019-01\[Orders On Hand 2019-01.XLSX]Sheet1'!$N$2/1000;TEXT(NUMBERVALUE(P2);"00")="02";'[Orders On Hand...
  11. E

    vba and vbs file name import

    Dear All, I have an issue with the following I have a code that saves a file under a name from one of the cells: Sub zapisintemp() ' ' zapisintemp Macro ' Dim Path As String Dim filename As String ' Range("A1:H1").Select Range(Selection, Selection.End(xlDown)).Select Selection.Copy...
  12. V

    File Path from cell value

    Hello All I am trying to modify this piece of code to point to a cell value for the file path instead of hard coding the path which I would have to change for different users. Sub Merger() Dim bookList As Workbook Dim mergeObj As Object, dirObj As Object, filesObj As Object, everyObj As...
  13. tyija1995

    Worksheet Selection Change Event

    Hi, I have a worksheet with cell A5 displaying "CLICK ME TO SEE FILE PATH" Then with the following code in the worksheet: Private Sub Worksheet_SelectionChange(ByVal Target As Range) On Error Resume Next If Target.Address = "$A$5" And Target.Value = "CLICK ME TO SEE FILE PATH" Then...
  14. A

    OleObject - File path for upload document

    Hi Everyone, I have one code which will browse document from provide path: Code: Sub Button1_Click() Worksheets("Sheet1").OLEObjects.Add Filename:="XXX", Link:=False, DisplayAsIcon:=False, Left:=40, Top:=40, Width:=150, Height:=10 End Sub My expectation: 1. Filename should be based on the...
  15. T

    Trouble with Dir()

    Hello everyone, I am having trouble with the Dir function. This is the first time I have used it, and I don't think I understand where it searches. When I type: Dim Path As String Path = Application.ActiveWorkbook.Path MsgBox Path The Messagebox returns a path. However adding Dir: Dim...
  16. M

    Converting file path on Excel for Mac

    I have written a Macro-Enabled Workbook on Windows, and am now trying to get it to work on Mac, on Excel 2011, 2016 & 2019. I'm new to Mac, so it's been a bit of a struggle, to say the least. For this question, I'm asking about Excel 2019, because I haven't tested this part yet on Excel 2016...
  17. P

    run time error 1004

    This is the same formular I saw work however it continualy gives me run time error. Can anyone help?? Private Sub CommandButton1_Click() Dim path As String Dim filename1 As String path = "C:\driver demo" filename1 = Range("D2").Text Application.DisplayAlerts = False ActiveWorkbook.SaveAs...
  18. R

    Remove rows in a single cell when matching text found in the row

    This is a duplicate from ExcelForum as well: appreciate your guidance for this. https://www.excelforum.com/excel-programming-vba-macros/1260449-remove-rows-in-a-single-cell-when-matching-text-found-in-the-row.html#post5045631 I have scenario like below: For example a sample cell will be like...
  19. A

    VB CODE to save file unique name

    I am using following vb code to save file with cell range; I need to amend it that if file already save with this name, it should save the file with extension for example, if file name ABC.xlsb already there, it saves as ABC (1)
  20. M

    positioning image by using VBA

    Hello everyone, I am writing a VBA code in order to insert an image in a specific cell. everything works properly except the horizontal position; no matter what cell I define in the code, it always appear a bit to the left. can someone please tell me what's wrong? Thank you in advance! here is...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top