From: "Lennart Borgman (gmail)" <lennart.borgman@gmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: Bug: can not start a w32 GUI program from Emacs
Date: Wed, 27 Dec 2006 11:52:30 +0100 [thread overview]
Message-ID: <4592506E.8050905@gmail.com> (raw)
In-Reply-To: <uslf121bk.fsf@gnu.org>
Eli Zaretskii wrote:
>> Date: Wed, 27 Dec 2006 01:38:13 +0100
>> From: "Lennart Borgman (gmail)" <lennart.borgman@gmail.com>
>>
>> I have been trying different ways to start explorer.exe from Emacs on
>> w32. I can not find any way that works. It is a quite annoying bug.
>
> Did you try w32-shell-execute?
Thanks, I thought I did, but I should have tried more. For example
(w32-shell-execute "open" ".")
just gives "ShellExecute failed: No application is associated with the
specified file for this operation". But trying again I see that
(w32-shell-execute "open" default-directory)
actually starts explorer.exe.
So now I can define these to integrate more with w32:
(defun w32-explorer(dir)
"Open Windows Explorer in directory DIR."
(interactive "DStart in directory: ")
(setq dir (expand-file-name dir))
(w32-shell-execute "open" dir))
(defun w32-cmd(dir)
"Open a Windows command prompt in directory DIR."
(interactive "DStart in directory: ")
(let ((default-directory (expand-file-name dir)))
(call-process "cmd.exe" nil 0 nil "/c" "start")))
next prev parent reply other threads:[~2006-12-27 10:52 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-27 0:38 Bug: can not start a w32 GUI program from Emacs Lennart Borgman (gmail)
2006-12-27 2:30 ` Lennart Borgman (gmail)
2006-12-27 8:24 ` Eli Zaretskii
2006-12-27 10:52 ` Lennart Borgman (gmail) [this message]
2006-12-27 12:00 ` Mathias Dahl
2006-12-27 12:19 ` Eli Zaretskii
2006-12-27 12:50 ` Lennart Borgman (gmail)
2006-12-27 14:19 ` Eli Zaretskii
2006-12-27 14:33 ` Lennart Borgman (gmail)
2006-12-27 19:21 ` Eli Zaretskii
2006-12-27 12:36 ` Lennart Borgman (gmail)
2006-12-28 9:26 ` Jason Rumney
2006-12-28 9:32 ` Lennart Borgman (gmail)
2006-12-30 1:09 ` Lennart Borgman (gmail)
2006-12-30 15:49 ` Eli Zaretskii
2006-12-30 16:04 ` Lennart Borgman (gmail)
2006-12-30 17:00 ` Eli Zaretskii
2006-12-30 17:28 ` Lennart Borgman (gmail)
2006-12-30 18:01 ` Eli Zaretskii
2006-12-30 18:22 ` Lennart Borgman (gmail)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4592506E.8050905@gmail.com \
--to=lennart.borgman@gmail.com \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).