H
Henri Schomaecker
Hi again,
as I already wrote, I'm trying to get image binary data into a var holding
an unsigned char string and then print it directly to the browser.
I now already did some tries with an array and now found the buffer()
function. - I thought I would have the solution now and also changed stdout
to O_BINARY, but still I don't get the data right:
8<--------8<--------8<--------8<--------8<--------
imgObj = win32com.client.Dispatch("mine.imgsender")
myImgData = buffer(imgObj.getImgData())
msvcrt.setmode(sys.stdout.fileno(), os.O_BINARY)
sys.stdout.write(myImgData)
8<--------8<--------8<--------8<--------8<--------
I'm really lost and would be very thankful if someone could help me with
that.
Many thanks in advance,
yours Henri
as I already wrote, I'm trying to get image binary data into a var holding
an unsigned char string and then print it directly to the browser.
I now already did some tries with an array and now found the buffer()
function. - I thought I would have the solution now and also changed stdout
to O_BINARY, but still I don't get the data right:
8<--------8<--------8<--------8<--------8<--------
imgObj = win32com.client.Dispatch("mine.imgsender")
myImgData = buffer(imgObj.getImgData())
msvcrt.setmode(sys.stdout.fileno(), os.O_BINARY)
sys.stdout.write(myImgData)
8<--------8<--------8<--------8<--------8<--------
I'm really lost and would be very thankful if someone could help me with
that.
Many thanks in advance,
yours Henri