[QUOTE=mikelaw;30504]I add a master detail form as grid with document in, so i can view documents associated with record.
Then i use Javascript to remove the checkboxes and file from the upload field.
Javascript:
Add code to javascript section under object: “Form” and under the Event: “onload”
document.getElementById("id_sc_loaded_documents").remove();
The code above will remove all checkboxes, the delete option, and filename/icon.
Use a grid to manage documents better!
I have also taken to creating a separate form for file uploads, because having to press the upload button and then to press save is too much for most users, or they forget to press save or upload either way lol.
-
So i have a button on the form i want to upload files to.
-
That button takes me to a separate form to upload a file
-
User chooses file presses save, there is only one button needed on a upload form (no multi-upload from a direct form, but can be done using multi-record form). File is uploaded and associated to the record.
-
The upload form closes, and the original form refreshes
-
The file appears in the document grid i added to master detail.
It just looks neater! :D[/QUOTE]
I tried this and get the error in the console:
TypeError: document.getElementById(…) is null
document.getElementById(“id_sc_loaded_documents”).remove();
A search within source of the generated html shows “id_sc_loaded_documents” does not exist on the page.
What could I be doing wrong?