Custom header picture from file

I want to add a picture to a custom header.

The only guide I can find is for dotNet (Setting Headers and Footers|Documentation)

I have tried the following, that does not give an error, but also does not show the picture

logo_url = “LM logo.png”
with open(logo_url, “rb”) as image:
f = image.read()
headerPicture = bytearray(f)

worksheet.page_setup.set_header_picture(1, headerPicture)
worksheet.page_setup.set_header(1, “&G”);

If I add the image to the Excel file manually and save it, &G does show the picture, but only on the first page.

Actually, after starting over with a new empty Excel file this does work. So no worries.

@rlloyd,

It looks like you have sorted it out. Please feel free to write back to us if you still encounter any issues or have other queries or comments. We will be happy to assist you soon.