Open GeekyMonkey opened 6 years ago
If you are using reactive forms then it is possible to specify: formControlName="imageUrl".
How can i implement this?
formControlName="imageUrl" ?
Can u provide example for this @ogix
@GeekyMonkey Did you figure this out
No. Sorry. I gave up on this control and rolled my own. It wasn't a great fit for my use anyway.
Anyway if somebody needs it
public fileControl = new FormControl();
ngOnInit() {
this.fileControl.setValue('url', { emitEvent: false});
}
<fancy-image-uploader id="field_photoUrl" name="photoUrl" [formControl]="fileControl" [options]="options" (onUpload)="onUpload($event)"></fancy-image-uploader>
i try from @enyachoke suggestion. it does not working. I got some error. Can you help me to fix?
I want to use this on a form where the user may have already uploaded an image previously. So they're not adding an image, but they can replace the image. Is it possible with this control to display that initial image instead of the empty box with the "add" text?