file upload

Posted on 2003-02-27
Medium Priority
Last Modified: 2013-12-18

i use domino's file upload function to upload file to the web. after i uploaded the file, the icon will show below the bar. is there a way to change this icon to a link and place it where i want it to be?

thank you very much..
Question by:janelow
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4

Expert Comment

ID: 8035463
This is called a V2-style attachment (because this is the only way in Notes V2 to attach a file). Here is how you can convert them to an attachment within a rich text field of your choice:




Author Comment

ID: 8040954
thanx for the reply.

i don't need to show the content of the attachments in a rich text field. just need to show the link at a specific location in the form.

i use $V2AttachmentOptions with the value "0". this will hide the whole icon, including the link. can i just have the link? how do go around doing it?

thank you very much


Expert Comment

ID: 8043577
You could create some computed text on your form that would serve as an HTML link to the attachment using the $FILE URL syntax to reference the attachment. Something like this:

"http://" + your_server_name + "/" @Subset(@DbName; -1) + "/" + view_id + "/" + doc_id + "/$FILE/" + @AttachmentNames

If there are multiple attachments, the concatenation operator should concatenate each name returned by @AttachmentNames with the rest of the string, producing a link to each separate file. In the above example, you would have to also create some hidden computed fields to calculate the value of the your_server_name, view_id, and doc_id parts of the URL - these can be calculated by parsing the Query_String CGI field.

Hope this helps.


Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.


Author Comment

ID: 8087693
sorie. i still have problem.
i've tried the solutions suggested but i still can't get the link to work. it returns the file not found error. can i replace the doc_id with the form name instead?
please correct me if i'm wrong here.

i've also tried placing this coding as pass-thru html in the form
<a href = "http://localhost/ResourceCentre.nsf/ceeb1319541daa6348256caa002a662f/frmthesis/$File/filename?OpenElement">(filename)</a>

the filename in brackets is a computed for display field with the
value @AttachmentNames. the link will display as where i want it but
it will show the 'can't find' error when i click it.

so i've changed the link to
<a href = "http://localhost/ResourceCentre.nsf/ceeb1319541daa6348256caa002a662f/frmthesis/$File/">(filename)</a>
and it will display the internal server error.

i've also tried the link i found in designer help, which is
<a href = "http://localhost/ResourceCentre.nsf/ceeb1319541daa6348256caa002a662f/frmthesis/$File/InternalFileName/Filename?OpenElement">(filename)</a>.
it will display the 'can't find' error..

i have another problem is that when i edit this document, how do i delete the previous attachment if i want to? if i just use domino's default upload function, it has a 'mark attachments for deletion' checkbox. if it requires too much effort then it's okie. i'll skip this part.

thanks a lot for any help.

Expert Comment

ID: 8107387
The link should be:


in which case ceeb1319541daa6348256caa002a662f should be the UNID of the view from which this document is looked up. It MUST be a sorted view. The first sorted column must have a value of frmthesis for this particular document. Easy way to test this is: open the view in Notes client (not web browser), start typing "frmthesis" and hit Enter (quick search a.k.a. jump to particular key value in sorted view). It should say Found 'frmthesis' in the status bar and your cursor should now be selecting the document in question. If not, or it says "Could not find 'frmthesis'", then it will not work on the web either.

As long as the document can be retrieved in this manner, then the rest of the URL, /$File/filename, should work without any problems to reference the attachment.

As for deleting previous attachments, you could probably do this with a small LotusScript agent called from the form's WebQuerySave event. I would do this for you, but at the moment I am incredibly busy, if you are interested in pursuing this, I would post a new question, and there are probably plenty of experts that can do this for you fairly quickly.



Author Comment

ID: 8118885
thanx scott for the reply. it's okie. i'll post another question if i really need it.

however, i still can't get the link to work. i think it's because the link doesn't refer to the attachment. the link will end with filename for all the links, instead of the name of the attachment file.

good day.

Accepted Solution

scottrma earned 120 total points
ID: 8120524
Sorry, I thought you were using "filename" as a generic variable to refer to the file names. I didn't realize you were using it as a string literal. What you would want to do is to make your HTML link a computed text field (allowing multiple values). The first part of the link is constant:


The second part of the link is calculated by Notes before converting to HTML and sending output to the browser:


and if there are multiple attachments, Notes will form a link for each one. Therefore, your formula for the computed text field should be a concatenation of the first and second parts:

"http://localhost/ResourceCentre.nsf/ceeb1319541daa6348256caa002a662f/frmthesis/$File/" + @AttachmentNames

This will cause Notes to produce the following for the field:


if there are files called file1.exe, file2.exe, and file3.exe attached to the document. You should probably choose "New Line" as the multi-value separator in the field properties so that you don't have multiple URL links on one long line.



Author Comment

ID: 8223235
thanks scott,

pls don't apologize coz probably my question wasn't clear enough and i'm the one asking for help. i've tried lotz of times and still don't get it... my supervisor doesn't seem mind with the default display so i just let it go.... and the project has come to tis due date. anyhow, thanx for all the help.

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This is an old article, please see an updated version of this article, located here: http://www.experts-exchange.com/articles/23619/Notes-8-5x-Windows-7-Notes-info-and-tips.html
You’ve got a lotus Domino web server, and you have been told that “leverage browser caching” is a must do. This means that we have to tell the browser everywhere in the web to use cache. In other words, we set (and send) an expiration date in the HT…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question