Hi,
This is my wraper code over the DOM API component of Windows, in asm32 language. include sample code and necessary inc file. because XML inc/lib or code is not available in masm32 compiler's librarys or in this forum, so this post may be usefull to anyone.
enjoy it.
veri@   
Attachments:
Posted on 2007-08-09 09:17:27 by veri@
Wow. Thank you for sharing.
BTW you should preserve ebx in ParseXML ;).

greetings
GM
Posted on 2007-08-10 03:55:06 by Gismo
Gismo,
thanks, you are right. I forget it.
Any suggestion to optimize this code, for example in memory management or speed optimization, can be usefull.
regards
Veri@
Posted on 2007-08-12 14:16:57 by veri@
Hi, veri@

I found a memory leak in your code.
When your app closes, it tries to free memory:
invoke	GlobalFree,lpwXMLBuff

but in your case, lpwXMLBuff is Local variable!
so, declare it as global variable.

does lpXMLBuff is freed anywhere in your code?

when you call LoadXMLFile, you do not free lpXMLBuff buffer in case if all was OK.
and in case of fail of LoadXMLFile, bstr is not freed too.

Attached updated source code.


--------------------------------------
v1.1 Oct 1, 2007
--------------------------------------
[-] Memory leak fixed
[+] VersionInfo resource added
[+] Manifest
[+] Icon
[*] Little code redesign
[+] WinAsm Studio Project
[!] by Jupiter
Attachments:
Posted on 2007-09-30 14:03:48 by Jupiter
Hi
Thank you Jupiter.
I am so happy for your post and your attached update. I hope this code can be extend in the future more and more. I will review your code later.
Thanks again.
Posted on 2007-10-02 04:43:18 by veri@