I'm trying to make a custom single image selector control. In this control I want to be able to select an image from EPiServer or from another specified source. It is too bad I had to create the control from scratch; I'd like to be able to just extend the existing control. This means I cannot drag and drop the image into the field; I have to select it.
But it is acceptable and it almost works. I can change the URL by selecting an image from my 'other specified source', but I cannot select an image from EPiServer... I've have the following code which is run 'onclick' of the EPiServer select image button:
Problem is: this.metadata.additionalValues["modelType"] is null... And I have no idea what value to put there to get the image picker dialog; I've tried about everything I could think of. When I click the button, the first time nothing happens, and the second time an empty dialog is shown.
I'm trying to make a custom single image selector control. In this control I want to be able to select an image from EPiServer or from another specified source.
It is too bad I had to create the control from scratch; I'd like to be able to just extend the existing control. This means I cannot drag and drop the image into the field; I have to select it.
But it is acceptable and it almost works. I can change the URL by selecting an image from my 'other specified source', but I cannot select an image from EPiServer...
I've have the following code which is run 'onclick' of the EPiServer select image button:
Problem is: this.metadata.additionalValues["modelType"] is null... And I have no idea what value to put there to get the image picker dialog; I've tried about everything I could think of.
When I click the button, the first time nothing happens, and the second time an empty dialog is shown.
How can I get the imagepicker to show?