[Mono-list] shell does not work on Widnwos Vista

Christopher David Howie me at chrishowie.com
Tue Apr 27 11:26:28 EDT 2010


On 04/27/2010 07:10 AM, Stephen Liu wrote:
> On Windows Vista, create a shortcut of IE and rename it as;
> 
> \Users\satimis\iexplore.lnk
> 
> 
> iexplore.lnk works on "Command Prompt" window but didn't work on "mono Command Prompt" nor on my small program.

The command prompt does a bit of trickery so that you can "run"
shortcuts.  The Windows APIs Mono uses to start programs don't do such
magic.

In short, unless the program is in your PATH, you can't run it without
specifying the full path to it.  This is not any different than on Linux.

(To introduce another side-case, note that Start>Run also looks in the
HKEY_CLASSES_ROOT\Applications registry key.  I'm still not sure exactly
how MS sells this kind of overconfigurability a benefit, but meh.)

In short, Process.Start() is not exactly the best place to experiment
with if your goal is to create a truly cross-platform application, since
it has platform-specific semantics.

-- 
Chris Howie
http://www.chrishowie.com
http://en.wikipedia.org/wiki/User:Crazycomputers

PGP key:

pub   2048R/CF8338F5 2010-04-14
      Fingerprint: 2B7A B280 8B12 21CC 260A  DF65 6FCE 505A CF83 38F5


More information about the Mono-list mailing list