wrong type when setting panel contents