Real Software Forums

The forum for Real Studio and other Real Software products.
[ REAL Software Website | Board Index ]
It is currently Mon Oct 22, 2018 2:40 am
xojo

All times are UTC - 5 hours




Post new topic Reply to topic  [ 7 posts ] 
Author Message
 Post subject: Is PageSource.Source read only at runtime?
PostPosted: Tue Dec 18, 2012 8:58 am 
Offline

Joined: Fri Sep 30, 2005 2:03 pm
Posts: 53
Location: Austin, TX
I'm trying to assign a value to PageSource.source (ie, "PageSource1.Source = s") but I'm getting this error:

Cannot assign a value to this property.

Is setting a value in the properties pane in the IDE the only way to set the PageSource content?


Top
 Profile  
Reply with quote  
 Post subject: Re: Is PageSource.Source read only at runtime?
PostPosted: Tue Dec 18, 2012 12:18 pm 
Offline
User avatar

Joined: Mon Nov 29, 2010 7:01 pm
Posts: 446
matt.quagliana wrote:
I'm trying to assign a value to PageSource.source (ie, "PageSource1.Source = s") but I'm getting this error:

Cannot assign a value to this property.

Is setting a value in the properties pane in the IDE the only way to set the PageSource content?



What are you trying to do? I believe the page source is a read only property. If you want to show some custom HTML use an HTMLViewer. Otherwise use execute javascript to alter elements on the page.


Top
 Profile  
Reply with quote  
 Post subject: Re: Is PageSource.Source read only at runtime?
PostPosted: Tue Dec 18, 2012 2:35 pm 
Offline

Joined: Fri Sep 30, 2005 2:03 pm
Posts: 53
Location: Austin, TX
I'm trying to show a very large block of generally static HTML content with some interactive controls below the HTML content.

If I use an HTML Viewer I am forced to make is take up less than the entire page so that there's some room at the bottom for the other controls I want to add. This isn't horrible, but it would be cleaner if there was a way for me to inject some html directly into the page.


Top
 Profile  
Reply with quote  
 Post subject: Re: Is PageSource.Source read only at runtime?
PostPosted: Tue Dec 18, 2012 3:12 pm 
Offline
User avatar

Joined: Mon Nov 29, 2010 7:01 pm
Posts: 446
matt.quagliana wrote:
I'm trying to show a very large block of generally static HTML content with some interactive controls below the HTML content.

If I use an HTML Viewer I am forced to make is take up less than the entire page so that there's some room at the bottom for the other controls I want to add. This isn't horrible, but it would be cleaner if there was a way for me to inject some html directly into the page.


You can still inject HTML using javascript


Top
 Profile  
Reply with quote  
 Post subject: Re: Is PageSource.Source read only at runtime?
PostPosted: Tue Dec 18, 2012 5:24 pm 
Offline
Real Software Engineer

Joined: Tue Jul 14, 2009 4:33 pm
Posts: 146
Location: Raleigh, NC
If you're using 2012r2, look at the WebSDK. There's an example project that allows you to put straight HTML onto a page.

_________________
Greg O'Lone
Software Engineer
Real Software


Top
 Profile  
Reply with quote  
 Post subject: Re: Is PageSource.Source read only at runtime?
PostPosted: Tue Dec 18, 2012 10:24 pm 
Offline

Joined: Fri Sep 30, 2005 2:03 pm
Posts: 53
Location: Austin, TX
I took a look... did you mean the project named "HTMLArea".

That example shows a technique that's closer to the behavior of an HTMLViewer since the html is rendered within the bounds of the control. I'm looking to inject html directly into the page. The issue here is that I will have a lot of html, much more than one screen's worth and I want the browser --not a control on the page-- to handle scrolling.

I might be able to figure this out from that example, with the help from one of my javascript savvy friends.


Top
 Profile  
Reply with quote  
 Post subject: Re: Is PageSource.Source read only at runtime?
PostPosted: Wed Dec 19, 2012 10:06 am 
Offline

Joined: Wed Mar 22, 2006 11:15 am
Posts: 712
Location: Southern California
matt.quagliana wrote:
I took a look... did you mean the project named "HTMLArea".

That example shows a technique that's closer to the behavior of an HTMLViewer since the html is rendered within the bounds of the control. I'm looking to inject html directly into the page. The issue here is that I will have a lot of html, much more than one screen's worth and I want the browser --not a control on the page-- to handle scrolling.

I might be able to figure this out from that example, with the help from one of my javascript savvy friends.


FWIW Web Custom Controls has a WebHtmlAreaTD control with a ContentResize event. Basically when you set the HTML the event returns the width and height of the HTML as rendered on the client browser. From this you can optionally resize the control itself and the page it's on, and move any other controls as necessary. You can "fill the page" and let the browser handle any scrolling.

_________________
Daniel L. Taylor
Custom Controls for Real Studio WE!
Visit: http://www.webcustomcontrols.com/


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC - 5 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group