Crash on RUN() against a dll

xxxcapxxx

New Member
Hi !
I have posted recently about the work I had to do on IBANKernel, as you helped me out very well i am back again with any other question about it.

Here's the code
Code:
[SIZE=2][COLOR=#3f7f5f]
[LEFT]/*---------------------------------------------------------------------------[/LEFT]
[/COLOR][/SIZE][SIZE=2]
[/SIZE][SIZE=2][COLOR=#3f7f5f][LEFT]Fichier : iban3.W

Description : Utilitaires - outil IBAN

Création : CC 10.08.2007 

Modification : 

----------------------------------------------------------------------------*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][COLOR=#8b7e66][LEFT]&scoped-define IBANKERNEL_DLL IBANKernel.dll [/LEFT]
[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055][LEFT]DEFINE[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VAR[/COLOR][/SIZE][SIZE=2] pszKonto [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]CHAR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.
DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VAR[/COLOR][/SIZE][SIZE=2] pszBCPC [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]CHAR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.
DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VAR[/COLOR][/SIZE][SIZE=2] pszIBAN [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]MEMPTR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.
DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VAR[/COLOR][/SIZE][SIZE=2] iIBANLen [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]INT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.
DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VAR[/COLOR][/SIZE][SIZE=2] pszBC [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]MEMPTR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.
DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VAR[/COLOR][/SIZE][SIZE=2] iBCLen [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]INT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.
DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VAR[/COLOR][/SIZE][SIZE=2] pszPC [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]MEMPTR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.
DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VAR[/COLOR][/SIZE][SIZE=2] iPCLen [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]INT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.
DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VAR[/COLOR][/SIZE][SIZE=2] pszBIC [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]MEMPTR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.
DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VAR[/COLOR][/SIZE][SIZE=2] iBICLen [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]INT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.
DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VAR[/COLOR][/SIZE][SIZE=2] iResult [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]INT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.[/LEFT]
[/COLOR][/SIZE][SIZE=2]
[/SIZE][SIZE=2][COLOR=#3f7f5f][LEFT]/*Initialisation*/[/LEFT]
[/COLOR][/SIZE][SIZE=2]

[/SIZE][SIZE=2][COLOR=#3f7f5f][LEFT]/*set-size(pszKonto) = 64.
set-size(pszBCPC) = 10.*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT]pszKonto = [/SIZE][SIZE=2][COLOR=#2a00ff]"415811.00032"[/COLOR][/SIZE][SIZE=2]. [/SIZE][SIZE=2][COLOR=#3f7f5f]/* for testing purpose*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT]pszBCPC = [/SIZE][SIZE=2][COLOR=#2a00ff]"100"[/COLOR][/SIZE][SIZE=2]. [/SIZE][SIZE=2][COLOR=#3f7f5f]/*for testing purpose*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT]iIBANLen = [/SIZE][SIZE=2][COLOR=#2a00ff]32[/COLOR][/SIZE][SIZE=2].
iBCLen = [/SIZE][SIZE=2][COLOR=#2a00ff]16[/COLOR][/SIZE][SIZE=2].
iPCLen =[/SIZE][SIZE=2][COLOR=#2a00ff]16[/COLOR][/SIZE][SIZE=2].
iBICLen=[/SIZE][SIZE=2][COLOR=#2a00ff]16[/COLOR][/SIZE][SIZE=2].[/LEFT]


[/SIZE][SIZE=2][COLOR=#7f0055][LEFT]set-size[/COLOR][/SIZE][SIZE=2](pszIBAN) = iIBANLen + [/SIZE][SIZE=2][COLOR=#2a00ff]1[/COLOR][/SIZE][SIZE=2].[/LEFT]
[/SIZE][SIZE=2][COLOR=#7f0055][LEFT]set-size[/COLOR][/SIZE][SIZE=2](pszBC) = iBCLen + [/SIZE][SIZE=2][COLOR=#2a00ff]1[/COLOR][/SIZE][SIZE=2].[/LEFT]
[/SIZE][SIZE=2][COLOR=#7f0055][LEFT]set-size[/COLOR][/SIZE][SIZE=2](pszPC) = iPCLen + [/SIZE][SIZE=2][COLOR=#2a00ff]1[/COLOR][/SIZE][SIZE=2].[/LEFT]
[/SIZE][SIZE=2][COLOR=#7f0055][LEFT]SET-SIZE[/COLOR][/SIZE][SIZE=2](pszBIC)= iBICLen + [/SIZE][SIZE=2][COLOR=#2a00ff]1[/COLOR][/SIZE][SIZE=2].[/LEFT]
[/SIZE][SIZE=2][COLOR=#3f7f5f][LEFT]/*Execution de la procedure*/
/*crash client -> parametres incorrects ? -> ...*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055][LEFT]RUN[/COLOR][/SIZE][SIZE=2] IT_IBANConvert([/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2] pszKonto,
[/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2] pszBCPC,
[/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2] pszIBAN,
[/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2] iIBANLen,
[/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2] pszBC,
[/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2] iBCLen,
[/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2] pszPC,
[/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2] iPCLen,
[/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2] pszBIC,
[/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2] iBICLen,
[/SIZE][SIZE=2][COLOR=#7f0055]OUTPUT[/COLOR][/SIZE][SIZE=2] iResult).[/LEFT]


[/SIZE][SIZE=2][COLOR=#7f0055][LEFT]IF[/COLOR][/SIZE][SIZE=2] iResult <> [/SIZE][SIZE=2][COLOR=#2a00ff]0[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]THEN[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]DO[/COLOR][/SIZE][SIZE=2]:
[/SIZE][SIZE=2][COLOR=#7f0055]MESSAGE[/COLOR][/SIZE][SIZE=2][COLOR=#2a00ff]"on avance"[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]VIEW-AS[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]ALERT-BOX[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]INFO[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]BUTTONS[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]OK.
END.[/LEFT]
[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f][LEFT]/*si erreur*/[/COLOR][/SIZE][SIZE=2] [/LEFT]
[/SIZE][SIZE=2][COLOR=#7f0055][LEFT]ELSE[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]DO[/COLOR][/SIZE][SIZE=2]:
[/SIZE][SIZE=2][COLOR=#7f0055]MESSAGE[/COLOR][/SIZE][SIZE=2][COLOR=#2a00ff]"ERROR:"[/COLOR][/SIZE][SIZE=2] + [/SIZE][SIZE=2][COLOR=#7f0055]STRING[/COLOR][/SIZE][SIZE=2](iResult)+ [/SIZE][SIZE=2][COLOR=#2a00ff]"Referez-vous au manuel."[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT][/SIZE][SIZE=2][COLOR=#7f0055]VIEW-AS[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]ALERT-BOX[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]ERROR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]BUTTON[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]OK.
END.[/LEFT]
[/COLOR][/SIZE][SIZE=2]

[/SIZE][SIZE=2][COLOR=#3f7f5f][LEFT]/*à la fin release external DLL*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055][LEFT]RELEASE[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]EXTERNAL[/COLOR][/SIZE][SIZE=2][COLOR=#2a00ff]"{&IBANKERNEL_DLL}"[/COLOR][/SIZE][SIZE=2]:U.[/LEFT]
[/SIZE][SIZE=2][COLOR=#7f0055][LEFT]RETURN.[/LEFT]
[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f][LEFT]/*Declaration de la procedure*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055][LEFT]PROCEDURE[/COLOR][/SIZE][SIZE=2] IT_IBANConvert [/SIZE][SIZE=2][COLOR=#7f0055]EXTERNAL[/COLOR][/SIZE][SIZE=2][COLOR=#2a00ff]"{&IBANKERNEL_DLL}"[/COLOR][/SIZE][SIZE=2]:U [/SIZE][SIZE=2][COLOR=#7f0055]CDECL[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PERSISTENT[/COLOR][/SIZE][SIZE=2]:
[/SIZE][SIZE=2][COLOR=#7f0055]DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PARAM[/COLOR][/SIZE][SIZE=2] szKonto [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]MEMPTR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f]/* pointeur compte terminé par 0*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT][/SIZE][SIZE=2][COLOR=#7f0055]DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PARAM[/COLOR][/SIZE][SIZE=2] szBCPC [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]MEMPTR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f]/*pointeur n° clearing terminé par 0*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT][/SIZE][SIZE=2][COLOR=#7f0055]DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]INPUT-OUTPUT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PARAM[/COLOR][/SIZE][SIZE=2] szIBAN [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]MEMPTR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f]/*pointeur sortie iban converti*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT][/SIZE][SIZE=2][COLOR=#7f0055]DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]OUTPUT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PARAM[/COLOR][/SIZE][SIZE=2] nIBANLen [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]LONG[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f]/*taille du pointeur de sortie iban*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT][/SIZE][SIZE=2][COLOR=#7f0055]DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]INPUT-OUTPUT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PARAM[/COLOR][/SIZE][SIZE=2] szBC [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]MEMPTR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f]/*pointeur sortie n° CB*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT][/SIZE][SIZE=2][COLOR=#7f0055]DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]OUTPUT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PARAM[/COLOR][/SIZE][SIZE=2] nBCLen [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]LONG[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f]/*taille du pointeur sortie n° CB*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT][/SIZE][SIZE=2][COLOR=#7f0055]DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]INPUT-OUTPUT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PARAM[/COLOR][/SIZE][SIZE=2] szPC [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]MEMPTR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f]/*pointeur sortie n° PC*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT][/SIZE][SIZE=2][COLOR=#7f0055]DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]OUTPUT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PARAM[/COLOR][/SIZE][SIZE=2] nPCLen [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]LONG[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f]/*taille du pointeur sortie n°PC*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT][/SIZE][SIZE=2][COLOR=#7f0055]DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]INPUT-OUTPUT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PARAM[/COLOR][/SIZE][SIZE=2] szBIC [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#cd3a3a]MEMPTR[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f]/*reservé pour usage ulterieur*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT][/SIZE][SIZE=2][COLOR=#7f0055]DEF[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]INPUT[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PARAM[/COLOR][/SIZE][SIZE=2] nBICLen [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]LONG[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]NO-UNDO.[/COLOR][/SIZE][SIZE=2][COLOR=#3f7f5f]/*reservé pour usage ulterieur*/[/LEFT]
[/COLOR][/SIZE][SIZE=2][LEFT][/SIZE][SIZE=2][COLOR=#7f0055]DEFINE[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]RETURN[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PARAMETER[/COLOR][/SIZE][SIZE=2] infoResult [/SIZE][SIZE=2][COLOR=#7f0055]AS[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]LONG.[/LEFT]
END[/COLOR][/SIZE][SIZE=2][COLOR=#7f0055]PROCEDURE.
[/COLOR][/SIZE]

when it steps into the RUN the runtime crashes.
I just cant understand why it doesnt behave as it did with the version part.
 

xxxcapxxx

New Member
Just to let know that i found what was wrong.
I didnt had the administrator rights onto the dll. As soon we fixed that i could make it work.
 
Top