FMPRO-L Archives

February 2011, Week 2

FMPRO-L@LISTSERV.DARTMOUTH.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Corn Walker <[log in to unmask]>
Reply To:
FileMaker Pro Discussions <[log in to unmask]>
Date:
Mon, 14 Feb 2011 11:13:01 -0500
Content-Type:
text/plain
Parts/Attachments:
text/plain (30 lines)
On Feb 14, 2011, at 10:33 AM, David Thorp wrote:

> But what if i have a field with a bunch of html in it, perhaps the source from a web page, and i want to render that in the web viewer?  Is that possible?  

Use the "data" URI. For example, here's a calculation to display the record count in a webviewer:

Let ( [
  __rn = Get ( RecordNumber );
  __fc = Get ( FoundCount );
  __trc = Get ( TotalRecordCount );
  __showtrc = Case (
    Get ( WindowMode ) = 1; " Find Requests"; __fc < __trc; " (" & __trc & ") Records" ) ];

  "data:text/html,
  <html>
  <head></head>
  <body bgcolor=\"rgb(45, 63, 83)\">
  <p style=\"text-align: left; padding: 0px; font-family: arial; font-size: 10pt; color: white; background-color: rgb(45, 63, 83)\">" & __rn & " / " & __fc & __showtrc & "</p>
  </body>
  </html>"
)


Cheers,
-corn


Cornelius Walker
Hatfield, MA

ATOM RSS1 RSS2