Is it possible to use explorer.exe to open a folder from a runshell?
I saw the post to open a PDF from a server or other location, but am hoping to simply open the folder on the server that the PDFs are in...
I am currently using this.
Tried replacing AcroRd32.exe with explorer.exe to no avail and don't understand the syntax enough to correct it, if possible.
RUNSHELLOPEN('explorer.exe','/A page=4\\ \\\\serverName\\folderNM\\subfolderNM')
Thanks in advance!
-Richard
I was actually just using this myself, and found that you only need to put the path to the folder, and explorer will automatically open it.
Try This:RUNSHELLOPEN("\\\\serverName\\folderNM\\subfolderNM")
Oh that is great! Thanks so much!!
on a side note --- you wouldn't happen to have anything that would print a pdf from a server location?
Our practice uses CQIC forms and I am placing the Runshellopen in the TFE for Patient Instructions and Education. CQIC users have to use a syntax like the following...
note the single quotes and the three back slashes.
RUNSHELLOPEN('\\\servername\foldername\subfolder')
Thanks again!!
You are wanting it to automatically print, as opposed to opening the folder? RUNSHELLOPEN will go to network locations (as long as you have all the right access set up), but I have not tried to make it auto-print. I am now curious and will have to investigate.
By the way: I use 4 backslashes for our servers here. I have not seen three. here is my setup:
RUNSHELLOPEN("\\\\serverName\\folder\\subfolder")
I'm wanting both! Opening the folder is just as useful, if we are able to print a PDF or any file located on a server or local client, as well. I did see 2 threads posted on Chug with functions posted, but am having trouble locating them. At the time, I didn't think they would be helpful; but it turns out I should have nabbed them... I hope someone has them somewhere?
and I have no clue why my 3 blackslashes work. The four seem to be working, too. I must have had syntax error(s) elsewhere. I don't know. I'm just a bootstrap coder riding along some other folk's coat tails
Thank you very much for your help and input!
"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /t "D:\File.pdf" "Brother MFC-7820N USB Printer" "Brother MFC-7820N USB Printer" "IP_192.168.10.110"
Defined as:
AcroRd32.exe /t <file.pdf> <printer_name> <printer_driver> <printer_port>
Depending on the directory names, defined path & default printer, could be as simple as:
acrord32.exe /t c:\data\sample.pdf
In DOS land, you need to use " quotes because Windows has the capability for filenames with space characters.
Let me know how it works out.
Hi Joe,
Thanks so much! Any chance you could post that code formatted and in syntax for mel? I am having trouble wrapping my brain around what you're suggesting in your reply.
Something like:
{
RUNSHELLOPEN("acrord32.exe /t c:\data\sample.pdf")
}
Assuming the Acrobat reader is in the PATH for all users.
Change that c:\ to the path and filename specific to you.
so, here is the syntax to open a folder:
{
RUNSHELLOPEN('AcroRd32.exe','\\\\server location\\folderName\\subfolderName')
}
to open a file:
{
RUNSHELLOPEN('AcroRd32.exe','\\\\server location\\folderName\\fileName.pdf')
}
a few current threads have posted syntax to open a file to a specific page:
{
RUNSHELLOPEN('AcroRd32.exe','/A page=4\ \\\serverlocation\\folderName\\fileName.pdf')
}
these are all so great and useful!
I'm going to keep looking for a function that will also print a pdf or other file type from outside Centricity. When I find it or if it finds me, I will post it here.
To print the pdf, I believe that is the /t inside my command example.
You are so right!! I overlooked that.
here is the syntax I am using to print an educational handout, from a server/ from outside of Centricity or CPS, from CQIC's patient instructions and education form.
{
RUNSHELLOPEN('acrord32.exe', '/t \\\\servName\\folderName\\subfolderName\\filename.pdf')
}
What a source of headache this has been for so many people. Now all these sweet commands are right here!
Thank you Joe and everyone else who contributed to this thread!!