Accessing file in the SharedDocuments

Hi, I want the full url path for a file in the SharedDocuments. This is needed for another app (outside XOJO). I 've search everywhere but without any luck. Please help.

SpecialFolder.SharedDocuments.Shellpath
SpecialFolder.SharedDocuments.NativePath

Depending on your needs

Thanks Greg for your prompt response. Unfortunately, this will not help. I need the full path with https:///. What I got is the following for both (Shellpath & NativePath)

/home/sites/www.example.com/Shared_Documents/test.txt

Oh, you can’t do that. SharedDocuments is specifically not accessible from the web.

If you need to proved that, make a webFile and point it at a file in that directory and then provide the url from that.

Thanks again Greg. I did the following:

dim f as FolderItem
dim wf as WebFile
f = SpecialFolder.SharedDocuments.Child(“test.txt”)
wf = WebFile.Open(f)
MessageBox wf.URL

Now the wf.URL is giving me error message when I tried to access it (Page not found). I put it in this format: http://xxx.xojocloud.net/(the url path)

It seems that the link is a dynamic link that changed every time. Any help?!

The problem is that wf is going out of scope. Instead of declaring it locally, try making it a property of the page or session.

Oh, and if the link isn’t session specific, make sure you set the session property to Nil.

Greg. You made my day :slight_smile:

Thanks alot