View Single Post
Old 04-08-2007, 12:56 PM   #32
esperanc
Member
esperanc began at the beginning.
 
Posts: 20
Karma: 10
Join Date: Nov 2006
Device: Sony Reader
Quote:
Originally Posted by scotty1024
Everything you need to build a Windows tool is provided. A copy of Visual Studio C++ Express (a free download) and 10 lines of C code (provided by Sony), and you've got your very own LRS to LRF tool you can customize to your heart's content.
Has anyone tried to do this? I have tried it in python using the following code (which didnīt work):

Code:
from ctypes import *
xylog = windll.LoadLibrary("XylogParser.dll")

check = xylog.MSXML_InitInstance()

if check:
    success = xylog.XYP_Create()
    print "create=",success
    xylog.XYP_SetTextCompressionFlag(0)
    xylog.XYP_SetPCMCompressionFlag(0)
    xylog.XYP_SetFontEncFlag(0)
    xylog.XYP_SetProducerName(u"test")
    #XYP_SetMsgWnd(wnd);
    #XYP_SetMsgID(WM_USER + 100)
    parse = xylog.XYP_ParseDocument(u"test.lrs")
    print "parse=",parse
    xylog.XYP_Release()
Incidentally, the output is

create= 1
parse= 0

Last edited by esperanc; 04-08-2007 at 12:59 PM.
esperanc is offline   Reply With Quote