In a message regarding Re: New HTMLViewer Question dated Thu, 27 Apr 2006
23:01:57 -0400, Barry Traver said that ...

> If one does not know the name of an existing file, how does one set 
> RelativeTo to Nil?

I don't recommend it because it doesn't work on Windows but
HTMLViewer1.LoadPage M, Nil
shoud work on OS X

The safest cross-platform answer is probably to create a file to use in the
temporary directory.

  Dim fileToAccess As FolderItem
  Dim tos As TextOutputStream
  fileToAccess = TemporaryFolder.Child("greekNT.html")
  If fileToAccess.Exists = False Then
    tos = fileToAccess.CreateTextFile
    tos.Close
  End If

> Related question:  how would I go about seeing that the temporary files
> will be written not to the folder containing the program but to a folder
> on a hard drive (e.g., whatever on the Mac would correspond to "C:\" on
> a Windows computer)?

Volume(0) is the cross-platform version of "C:\" but once again don't use
it.
What you're looking for in this instance is TemporaryFolder

> P.S.  Also, what does "ISTR" stand for?

Apologies - I Seem To Recall

--
Steve Garman
Using REALbasic 2006r2 Professional on Windows XP Pro



_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to