Re: Probelm with Process and shortcut

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



I tried with almost all famous format like MP3, images, videos, exe, etc...
it seems to work on all other systems, and it works perfectly at work, I
tested to see...
so it's obviously a problem on my computer but I just expected that someone
would have encountered such a problem and could tell me how to resolve.

But it's ok, I straped the problem writing a basic .lnk parser which get the
executable filename, then at starting, I first try the execution via Process
method into a try/catch bloc, if it fails, I set a flag telling that the
program have to work with the lnk parsing, and if it doesn't, the program
works with Process method. That works pretty fine, just first time is slow in
my case because of the exception throwing.


"José Manuel Agüero" wrote:

> Hello,
>
> It works fine on my system. Have you tried it with different links or documents other than Acrobat Reader?
>
> Regards.
>
>
> "sebseb" <sebseb@xxxxxxxxxxxxxxxxxxxxxxxxx> escribió en el mensaje news:3FBFF7A7-B9DA-4272-8C48-7262D6ACAE75@xxxxxxxxxxxxxxxx
> | Thank you for answering, but the result is same... still not work, and still
> | the same exception with the same message
> |
> | The French version of this message could be a help, maybe, since it's bit
> | different from the English message, it says : "Aucune application n'est
> | associée au fichier spécifié pour cette opération" which means "There is no
> | application associated to this file for this operation"
> |
> | The English equivalent was : "The specified executable is not a valid Win32
> | application"
> |
> | I still need help, my whole project will be affected if I can't resolve it,
> | I can bypass by changing strategy, but it will but much much less useful for
> | end-users :S
> |
> |
> | "José Manuel Agüero" wrote:
> |
> | > Hello sebseb,
> | >
> | > Try the following:
> | >
> | > Process p;
> | > p.StartInfo.FileName = "path\\of\\my\\shortcut\\file.lnk";
> | > p.StartInfo.Verb="open";
> | > p.Start();
> | >
> | >
> | > Regards.
> | >
> | >
> | > "sebseb" <sebseb@xxxxxxxxxxxxxxxxxxxxxxxxx> escribió en el mensaje news:ABD158B7-AF8A-4368-AC6A-392A3AEC3D06@xxxxxxxxxxxxxxxx
> | > | Hello
> | > |
> | > | I directly go to the problem, I create a Process, I set the Filename to the
> | > | full path and filename of a shortcut file (.lnk) and then I start my process,
> | > | like this :
> | > |
> | > | Process p;
> | > | p.StartInfo.FileName = "path\\of\\my\\shortcut\\file.lnk";
> | > | p.Start();
> | > |
> | > | My problem is that I always get a Win32Exception, with this message :
> | > | "The specified executable is not a valid Win32 application"
> | > |
> | > | My shortcut is valid, it links to a PDF file and when I double-click on my
> | > | shortcut, I get my PDF document open in Acrobat, properly
> | > |
> | > | Thank you in advance for any help
>
>
.



Relevant Pages

  • Re: first exception pause
    ... Anyway, the problem is that when an exception occurs for the first time, ... >> What can I do in order to avoid first exception pause? ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: SqlceException.SqlceException
    ... public static void checkDB() ... SqlCeConnection conn = null; ... Other than the exception question, i want your opinion concerning this ... it is the first time i am doing mobile applications and the first time ...
    (microsoft.public.sqlserver.ce)
  • Re: Delphi 4 Pro vs Standard
    ... However, when I ran the program, it threw an exception, but it was only a misread of data from the serial port and otherwise the program seemed to run normally. ... Another weird thing is that the first time through, the debugger showed the contents of the received file, but on the second pass, where it failed, the debugger seemed not to work. ... Of course, I could just install my D4 Pro on their computer and I'm sure the Borland cops won't suddenly appear with search warrants and Uzis, but it would be nice to have the ability to maintain this application, using their computer and software. ...
    (comp.lang.pascal.delphi.misc)
  • Re: URGENT: Application_Start - doesnt fire
    ... EITHER Application_Start to fire NOR my custom exception handler (in the ... HTTP Module) that sends the e-mail to fire. ... > It's as if the Web site simply ignores ANY ... >> changes I make once the exception is encountered for the first time. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Tamper-resistant screw
    ... This isn't the first time they've used this type of screw-it ... first appeared in the mid-2009 MacBook Pro to prevent you from replacing ... Best Regards ... Lady friend wants to put a bigger hard drive in her macbook. ...
    (rec.crafts.metalworking)