I want to hide a pre-filled question so that it will still be automatically filled, but will not be visible to the user while they are responding to the form. This is to keep confidential information hidden and to simplify the form's appearance. I tried to run some scripts like this one, but none of them worked as expected so far.
There is not a way to do what you're trying to accomplish and this is likely intentional on Google's part. While I don't know EXACTLY what your requirement is, it could be used to track individual data about users' submissions without them being aware of it. Google (and Microsoft) seem committed to properly apprising form users when their submissions are and are not anonymous. As a result, there are certain roadblocks you might encounter such as....
A pre-filled form must have the pre-populated link within the URL. You could try to trick someone by using a shortened link, but the identification will still be in the URL after it loads. It will appear after the ...viewform
with a ?
after it with the exact item ID and response. It disappears once loaded, so maybe you could get around it using link shortener, but it would still be visible to the user.
One workaround that I just considered was having a section that the form skipped, but had a pre-populated URL. So if you had three sections, and section 1 jumpted to section 3 with section 2 having the pre-written URL... it does not work, meaning the pre-populated information is not part of the form response.