Lorsque je génère avec Moebius une userlib, le résultat escompté n'est pas le résultat fourni.
Ainsi j'attends
Code : Tout sélectionner
PureBasic_Compilation0
Code : Tout sélectionner
C:\Documents and Settings\flefevre\Local Settings\Temp\PureBasic_Compilation0.exePureBasic_Compilation0
Code : Tout sélectionner
ProcedureDLL.s GetFilePartWE(file.s) ; Return only file part without extension
file.s=ReverseString(GetFilePart(file))
file=Right(file,Len(file)-FindString(file,".",1))
file=ReverseString(file)
ProcedureReturn file
EndProcedure
Code : Tout sélectionner
Debug GetFilePartWE(ProgramFilename())
Code : Tout sélectionner
format MS COFF
public PB_GetFilePartWE
extrn _PB_FindString2@12
extrn _PB_GetFilePart@8
extrn _PB_Len@4
extrn _PB_ReverseString@8
extrn _PB_Right@12
extrn _PB_StringBasePosition
extrn _S1
extrn _SYS_AllocateString4@8
extrn _SYS_CopyString@0
extrn _SYS_FreeString@4
extrn PB_StringBase
extrn SYS_FastAllocateString
_Procedure0:
PB_GetFilePartWE:
PUSH ebx
PS0=12
XOR eax,eax
PUSH eax
MOV edx,dword [esp+PS0+0]
LEA ecx,[esp+0]
CALL SYS_FastAllocateString
MOV eax,[_PB_StringBasePosition]
PUSH eax
PUSH eax
MOV eax,[_PB_StringBasePosition]
PUSH eax
PUSH eax
PUSH dword [esp+16]
CALL _PB_GetFilePart@8
MOV edx,[PB_StringBase]
ADD [esp+0],edx
CALL _PB_ReverseString@8
LEA eax,[esp+4]
PUSH eax
CALL _SYS_AllocateString4@8
MOV eax,[_PB_StringBasePosition]
PUSH eax
PUSH eax
PUSH dword [esp+8]
CALL _PB_Len@4
MOV ebx,eax
PUSH dword 1
PUSH dword _S1
PUSH dword [esp+16]
CALL _PB_FindString2@12
SUB ebx,eax
PUSH ebx
PUSH dword [esp+12]
CALL _PB_Right@12
LEA eax,[esp+4]
PUSH eax
CALL _SYS_AllocateString4@8
MOV eax,[_PB_StringBasePosition]
PUSH eax
PUSH eax
PUSH dword [esp+8]
CALL _PB_ReverseString@8
LEA eax,[esp+4]
PUSH eax
CALL _SYS_AllocateString4@8
MOV edx,dword [esp]
PUSH dword [_PB_StringBasePosition]
CALL _SYS_CopyString@0
POP eax
ADD eax,[PB_StringBase]
JMP _EndProcedure1
MOV eax,[_PB_StringBasePosition]
ADD eax,[PB_StringBase]
MOV byte [eax],0
_EndProcedure1:
PUSH dword [esp]
CALL _SYS_FreeString@4
ADD esp,4
POP ebx
RET 4 + 4
Testé avec PB 4.6 B3
Merci d'avance de votre aide pour faire avancer Moebius.