voici mon code en Powershell:
<<
$Dll ="F:\Jay\test\Zpacq.dll"
$Signature = @" [DllImport(@"$Dll",CharSet = CharSet.Unicode, SetLastError = true)]public static extern bool Run(int Count, string arg1); "@ $ShowWindowAsync = Add-Type -memberDefinition $Signature -Name "Test" -PassThru -IgnoreWarnings
$ShowWindowAsync::Run(1,"-xxcc")
Ma DLL exporte une fonction avec ce profil elle est développée sous Visual studio 2019
BOOL Root::Run(int argc, LPCTSTR argw)
au runtime j'obtiens suivant
lors de l'appel de « Run » avec « 2 » argument(s) : « Tentative de chargement d’un programme de format incorrect. (Exception de HRESULT : 0x8007000B) » Au caractère Ligne:12 : 1
je ne comprends pas j'ai respecté ce que j'ai trouvé sur net
#
#
Pouvez-vous m'aider
D'avance merci.
User contributions licensed under CC BY-SA 3.0