File Upload, Attachment issue

Hello,

Greetings!

I am the first time user of FileUpload Control. There is a master database, in which I added this new Fileupload control to a form. But the documents are actually saved in another sub-database via webQuerySave Agent. I chosen the file and then when I click save button, the webQuerysave agent gets triggered and while executing the below code snippet,

of WebQuerySave Agent, v2FileNames(0) returns null value only. I am actually trying to get the object embedded and reattach it while saving it in the sub-database. But attachment is not returned. If you could reply with screenshots it would be greatly helpful.

v2FileNames = Evaluate(“@AttachmentNames”, doc)

messagebox "Filename - - > " & v2FileNames(0)

here doc is the Session documentcontext.

Thanks in Advance.

Sundar.