How to reference attachment id in form

commcare

When using a multimedia question, I've noticed that the image/video/recording gets saved to an attachment ID on CommCareHQ. Is it possible to save or reference that ID in the form so that I can save it to a hidden value?

Best Answer

CommCare automatically generates an attachment ID when multimedia is attached to a form. To save or reference this ID, you can create a hidden value and set the calculation equal to the media capture question. If you need to refer to this attachment ID in another form, you can save the hidden value as a case property and reference it as required.