shell

  1. SkywardPalm

    Calling Python Script from VBA, and waiting for script to finish

    I am attempting to call a python script from VBA and wait for the script to finish before continuing with the macro. However, It doesn't seem to be calling the python script.. any ideas what I may be doing wrong? Code I have so far: Dim objShell As Object Dim PythonExe, PythonScript As String...
  2. A

    Search Files by Tags

    I am very new to VBA and have been learning as I go on a work project. One of the things that was requested was to have a search bar to find other files of a similar problem solving event. What I want to be able to do to have a vba program that opens file explorer and searches by tags. but all...
  3. M

    Print a PDF file with shell command in VBA

    I am using this command in Excel VBA to print an existing PDF file as PDF Shell """" & "C:\Program Files (x86)\Adobe\Acrobat Reader DC\Reader\AcroRd32.exe" _ & """/p /h """ & ActiveWorkbook.Path & "\" & Range("A8") & "invoice.pdf" & """" This works great, however I would like to be...
  4. J

    shell roboCopy 'not recognized as internal or external command, operable program or batch file' error

    I am looping through a connection to sync folders from a network drive onto a google drive and I can't figure out why cmd is giving me: 'robocopy' is not recognized as an internal or external command, operable program or batch file." error Here is my code: 'Here we can run the batch files to...
  5. J

    Shell for non .exe Files

    Hello All, So I currently am trying to open from VBA, an output file of a macro recordercalled tinytask. I am able to sue theshell function to open the macro recorder itself using the below: Sub TinyTaskCallExample() DimstrProgramName As String Dim strArgumentAs String...
  6. wadergirl

    Macro to open another program - shortcut target has a command line switch

    So, in my spreadsheet, I have an existing macro that uses: Shell ("C:\Program Files (x86)\Google\Chrome\Application\chrome.exe") So I'm pretty sure that it is the base of what I need to use for this other program, but the other program I need to use a shortcut which has a command line switch...
  7. M

    Excel - running a cmd line from a cell to cmd/powershell

    Hi, I have a cell with a command on it and would it be possible to be launched to cmd or powershell? I encountered this function, PID = Shell("notepad c:\MyFiles\TextFile.txt", vbNormalFocus) but I am not sure how would this launch to cmd or powershell. How would I incorporate the cell with...
  8. C

    Malicious Macro Detected When Using Shell Command

    I am trying to create a code that could open a .pdf file via Adobe Acrobat by using Shell command method. However, i keep receiving an alert saying "Malicious Macro Detected" and my excel file shuts down itself without saving. After some debugging i realized it is the shell command that...
  9. C

    Use VBA to run/terminate Shell command and save file

    Greetings! I have a shell command that uses curl to capture live audio output from a port on our call server. Sub RecordAudio() Call Shell("cmd.exe /S /K" & "curl 92.68.0.10:8888 > i:\voicetemp\voice.wav", vbMinimizedFocus) End Sub What I would like to know is; 1) how can I stop the...
  10. UniMord

    Suppress Sizing Handles on "Packager Shell Object" icon

    When embedding a file as a “Packager Shell Object”, I’d like users to be able to click the icon without the sizing handles displaying. Is there any way to prevent the handles from appearing?
  11. S

    Search and Replace close matches

    Hi, I'm importing data from our credit card bills. I want to bring the data into our accounting system. We have an issue when the names are not always the same. IE Shell 1234 and Shell 4354. I would like it to load it to the name Shell. Or Amazon charge of Amazon, Amazon Direct or Amazon...
  12. D

    Open windows explorer to a folder

    Hi, I have this hard wired code to open a folder called Comm. It works perfectly. Shell "explorer.exe ""C:\Users\Pas\Comm\", 1 I have this full folder path recorded in cell A1. Just to make it a bit more flexible, I loaded this value to a string variable and execute the same script to open...
  13. M

    Shell command: Error 5

    Long time that I played with the Shell command. I keep getting Error 5. I think that it is related to some space included in the path, but can't find how to resolved that yet. The goal, start and external application when my Excel file is opened. Private Sub Workbook_Open() ' Setting a...
  14. L

    Retrieve Unique Tag Metadata from a folder and its subfolders

    Guys I would like your support on how to retrieve all TAG metadata from files that are saved on some folder including its subfolders. The idea is list all Tag Metadata as unique values in a txt file. Unique because it can be repeatable due the loop will check on different files. Below an example...
  15. M

    Excel 2010 Shell does not close completely

    This has started in the past month or two: I have a workbook open, only one. I close Excel using the X in the upper right hand corner in the outer frame. The open workbook closes but leaves the shell open with no workbook. Some notes: This used to close the shell as well as the workbook. It...
  16. azizrasul

    Using Shell

    I am trying to merge 2 win2pdf files (pdf1.pdf and pdf2.pdf). I have been given the following command line to create the merged file called pdf3.pdf. Is there a way of using Shell to do this? I tried the following which didn't error but didn't do anything either...
  17. M

    Excel VBA - Using Shell to Open a TXT file in Notepad that Begins with the First Part of the Filename?

    I have a macro which uses Shell to open a TXT file in Notepad. I am trying to get this macro to work with opening a TXT file in Notepad beginning with the first part of the filename; I have listed below my two attempts to have this work (MacroAttempt1 and MacroAttempt2): Sub MacroAttempt1() Dim...
  18. B

    Using AppActivate to switch to other software that is open

    I'm trying to get Excel to switch over to a completely different software that has a title that is difficult to capture....and as you may know AppActivate needs the exact title to do that. I need a method that captures the full title name and passes the string to AppActivate.... This part...
  19. D

    Synchronously execute a shell with a winscp command - VBA

    I have currently this code: Call Shell("("C:\Folder\WinSCP\WinSCP.com /ini=nul /script=""C:\Folder\WinSCP\Remote2local.txt"" ", vbHide) Application.Wait (Now + TimeValue("0:00:10")) Rest of the code ... The problem with this code is that if the computer is slow, it will...
  20. C

    Excel VBA Upload with FTP

    Hello every one! Using Excel VBA I am trying to upload files to a server. In order to do so the macro creates a command-file called 'FTP_batch.txt' and when the subroutine finishes, it kills that file again. When I run the command prompt and copy/ paste the commands from the 'FTP_batch.txt'...

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