2011-05-15 2 views
0

Je suis en train d'exécuter ce code sur VC2005 sur l'émulateur Pocket PC, mais il me donne une exception win32unhandledexception non gérée appelant un fichier .exe sur l'application de l'émulateur pocket pc

private void button1_Click(object sender, EventArgs e) 
{ 
    System.Diagnostics.Process Proc = new System.Diagnostics.Process(); 
    Proc.StartInfo.FileName = @"WM_flowm.exe"; 
    Proc.Start(); 
} 

Le WM_flowm.exe est le Flite tts qui peuvent fonctionner sur Windows Mobile sans problèmes, mais je dois l'appeler dans mon code C#.

la pile d'appel

System.dll!System.Diagnostics.Process.StartWithShellExecuteEx(System.Diagnostics.ProcessStartInfo startInfo = {System.Diagnostics.ProcessStartInfo}) + 0xcb bytes 

System.dll!System.Diagnostics.Process.Start() + 0x3f bytes 

arrêtés ici ===

try_DLL.exe! Try_DLL.Form1.button1_Click (objet expéditeur = {text = "button1"}, System.EventArgs e = {} System.EventArgs) ligne 29 + 0x6 octets C#

System.Windows.Forms.dll!System.Windows.Forms.Control.OnClick(System.EventArgs e = {System.EventArgs}) + 0x15 bytes 

System.Windows.Forms.dll!System.Windows.Forms.Button.OnClick(System.EventArgs e = {System.EventArgs}) + 0x32 bytes 

System.Windows.Forms.dll!System.Windows.Forms.ButtonBase.WnProc(Microsoft.AGL.Forms.WM wm = WM_BUTTON_NOTIFYCLICKED, int wParam = 0, int lParam = 0) + 0x17 bytes 

System.Windows.Forms.dll!System.Windows.Forms.Control._InternalWnProc(Microsoft.AGL.Forms.WM wm = WM_BUTTON_NOTIFYCLICKED, int wParam = 0, int lParam = 0) + 0x9 bytes 

System.Windows.Forms.dll!Microsoft.AGL.Forms.EVL.EnterMainLoop(System.IntPtr hwnMain = 1114117) 

System.Windows.Forms.dll!System.Windows.Forms.Application.Run(System.Windows.Forms.Form fm = {try_DLL.Form1}) + 0x1a bytes 

try_DLL.exe!try_DLL.Program.Main() Line 15 + 0xa bytes C# 
+2

Vous devrez fournir plus d'informations sur l'exception que vous avez reçue avant de pouvoir vous aider. –

+0

Pourriez-vous poster la trace de la pile? –

+0

J'ai ajouté la pile d'appel et il n'y a plus d'infos, juste pour savoir que le fichier .exe ne fonctionne que sur les petits appareils. – emykindman

Répondre

0

Essayez d'utiliser le chemin complet du fichier . Si le fichier est dans \ Progam Files \ WM_Flowm \:

private void button1_Click(object sender, EventArgs e) 
{ 
    System.Diagnostics.Process Proc = new System.Diagnostics.Process(); 
    Proc.StartInfo.FileName = @"\Program Files\WM_flowm\WM_flowm.exe"; 
    Proc.Start(); 
}