Question about bpy.ops.wm.context_modal_mouse

how can i use the header_text property ?
if i give it a value of “test” i get this error:

Traceback (most recent call last):
File “c:\blender-2.80.0-git.490a385c8124-windows64\2.80\scripts\startup\bl_operators\”, line 782, in modal
header_text = header_text % eval(“item.%s” % self.data_path_item)
TypeError: not all arguments converted during string formatting

based on my limited python knowledge the i should get test + the value of the property that im changing in the blender header.
The code of the operator can be found here

What do you mean with

if I give it a value of “test”

What is it in this case? How do you assign “test”, and to what?

Setting the header text from an Add-on should work using the code in line 786 of the code you linked: context.area.header_text_set(header_text). So context.area.header_text_set("test") should do what you (I believe) want.

so here is my code and i get the error mentioned above if i run it

edv = box.operator(“wm.context_modal_mouse”,text=“Adjust Focal Length”, icon=“ARROW_LEFTRIGHT”)
edv.input_scale = 0.01
edv.header_text = “test”
edv.data_path_iter = “selected_editable_objects”
edv.data_path_item = “data.lens”

in the W menu there is an option called ‘Camera Lens Angle’ i want exactly the same thing only in my menu