I am designing a form. In the form will have a few fields of regular text data. I would also like to create a field kind of like the field/names type/use address dialog for choices. But of course I want it to be a browse window for files and folders. The goal is to pop up a window that will allow a person to select the file that want to store in the field. Once the file is selected it will be attached to the document.
Any ideas?
Subject: Form Question - can you create a dialog for getting files?
Hi, This can be done with the command
@Command( [EditInsertFileAttachment] )
Before that move the insertion point to the Rich Text field where you would like the attachment to be inserted using
@Command([EditGotoField];)
Create a hotspot ( button ) and add this code to the click event. Hope this helps.
Subject: RE: Form Question - can you create a dialog for getting files?
@Command([EditGotoField];file);@Command( [EditInsertFileAttachment] )
My field name is simply just file. I added the above lines to a button and I got an error saying “Cannot execute the specified command”
My field is richtext.
Any ideas?
Subject: RE: Form Question - can you create a dialog for getting files?
I forgot to add that the document to which you are trying to add the attachment must be in editable mode. Try opening the document in editable mode and then execute the above @commands. It should work.
Subject: RE: Form Question - can you create a dialog for getting files?
Yeah I figured it out as well. I just added an extra line.
@If(@IsDocBeingEdited;“”;@Command([EditDocument]));
@Command ([EditGotoField]; “file”);
@Command([EditInsertFileAttachment])
Thanks for your help, I knew it was probably something easy to do but when you do not know what to use it can take a while figuring it out. You just saved me a lot of time from doing that research.
Subject: RE: Form Question - can you create a dialog for getting files?
Good to know that my inputs helped you.
Subject: RE: Form Question - can you create a dialog for getting files?
One more way to do this is to make field a rich text lite field and select the type as attachemnts only.