I am making CRUD apps of monitoring works. I am facing with a little struggle to when update some data after link of image has been sent to spreadsheet.
This image show before update has been performed
my question is after performed update action, why the link of image change just to be "https://drive.google.com/uc?export=view" ? where is the imageID? why is it not same with previouse link? Meanwhile, the link in Urlphot label has save same link with previous one before update
first, when user create a set of data (include photo) they pick the image from their local phone, and the image Will be upload to my Drive and the viewurl of image Will be put on my spreadsheet
then, when the user want to update that data.. first i use read function to read the data include view url, and the url i store it to a label (called urlPhoto label).
after the user change any data, and when they click update button, i use update function with expectation, the viewurl of previous one is same with after update action, because the user didn't change the image when update data.
But, actually the result is not like my expextation.. the viewurl is cutted and change to like my first post, the image id is lost.
The first test is: if (e.parameters.filename && e.parameters.file && e.parameters.imageformat)
these parameters just have to exist, the script doesn't care if they are empty or not, therefore the variable viewurl is generated (without an image ID !)
in my opinion, when user want to update the data except image, it's ok if 3 paramaters ( filename, file, imageformat) are not exist, because the imageurl has been existed from spreadsheet that i store it to urlphoto label. So when user click update button, i hope the image url is still same, because i use e.parameter.PHOTO to get image url from urlPhoto label in my block.
that's true, that the 3 parameters shall exist when user in step create. but in update step, we assume the url image has been created from step create. so i want to keep that image url, when to user want to update any data except the photo(not picking any image anymore), but the result the image url is cutted and image id is gone
Sorry, what i understand is i shall to use UriEncode the UrlPhoto.Text block before updating action? Please correct me, better to share the block what you mean.