New topic: Using HTMLViewer1.LoadPage with TextArea1,Text
<http://forums.realsoftware.com/viewtopic.php?t=46959> Page 1 of 1 [ 3 posts ] Previous topic | Next topic Author Message barrytraver Post subject: Using HTMLViewer1.LoadPage with TextArea1,TextPosted: Fri Feb 15, 2013 2:00 pm Joined: Fri Sep 30, 2005 1:53 pm Posts: 822 Location: Philadelphia, PA A while back (May 15, 2010 to be exact) I posted this comment: Quote:HTMLPageDisplayer If you have the HTML information loaded into a TextArea (such as TextArea1), the following should be sufficient: HTMLViewer1.LoadPage TextArea1.Text, "" That seems NOT to be true now. Was it true back them? Or does the current situation differ from what the situation was earlier? AIso, I currently get the error message "Parameters are not compatible with this function." And the Language Reference currently gives this example of working code to display a Web page whose contents are in TextArea1: Dim f As New FolderItem HTMLViewer1.LoadPage(TextArea1.Text, f) That example DOES work, even though I'm not sure why, since nothing specific is set as to where the somewhat hypothetical folder item is (and that could be important, since temporary files cannot be written to a CD Drive (which may be D:\ or E:\, depending on the computer) or you may not want the program to write temporary files to a nearly full hard drive or to a small flash drive (just to give two examples). I guess I'm really asking two questions: (1) Did the following work at one time?: HTMLViewer1.LoadPage TextArea1.Text, "" (2) Where does Real Studio put the temporary files if you use the sample code in the current Language Reference?: Dim f As New FolderItem HTMLViewer1.LoadPage(TextArea1.Text, f) Again, that code DOES work. I'd just like to know if temporary files are being written just where they are being written. Barry Traver Top charonn0 Post subject: Re: Using HTMLViewer1.LoadPage with TextArea1,TextPosted: Fri Feb 15, 2013 2:16 pm Joined: Mon Apr 02, 2007 2:08 am Posts: 1126 Location: San Francisco, CA, USA I'm not sure that HTMLViewer1.LoadPage TextArea1.Text, "" ever worked. The second parameter must be a folderitem. If you use the sample code, the folderitem will point to the same location as GetFolderItem("") would, which is the parent folder of the executable. A more appropriate sample might be: HTMLViewer1.LoadPage(TextArea1.Text, SpecialFolder.Temporary) _________________ Boredom Software Top barrytraver Post subject: Re: Using HTMLViewer1.LoadPage with TextArea1,TextPosted: Sat Feb 16, 2013 10:21 am Joined: Fri Sep 30, 2005 1:53 pm Posts: 822 Location: Philadelphia, PA Charonn0, Thanks for the information. I have edited my original post so that it is now correct. Barry Traver Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Page 1 of 1 [ 3 posts ] -- Over 1500 classes with 29000 functions in one REALbasic plug-in collection. The Monkeybread Software Realbasic Plugin v9.3. http://www.monkeybreadsoftware.de/realbasic/plugins.shtml [email protected]
