[AccessD] Moving on to Fonts

Stuart McLachlan stuart at lexacorp.com.pg
Tue Jul 12 20:40:53 CDT 2022




On 12 Jul 2022 at 20:41, John Colby wrote:

> Since I have Stuart's attention...
> 
> When I put up a line of text, I can use the face html tag and use a
> small selection of fonts.

There is no "face tag".  in HTML. "face" is an attribute of the "font" tag :)
Not sure what you mean by "put up a line of text".

> 
> When I click in the control, the editor allows me to edit the font to
> any font on my computer (it appears).  However, the html in the
> control itself does not change, IOW if I read it back out of the text
> box and print it to the debug window, it is still what I wrote in
> there.  But the display shows what I did to it in the editor on the
> tool bar.

Do you mean you copy/paste into the debug window? 
In that situation, Access just copies the plain text to the clipboatrd, not the formatted HTML.

>
> It is as if the control stores what I write into it somewhere else,
> but keeps the "text" property as what I wrote.  then if I edit it with
> that little editor, it stores that somewhere and displays THAT.

No, the full HTML is stored in the field.  Your problem is that whatever you are doing is  not 
getting that actual field's content, it is just getting the text without the markup.

Here's a demo of getting the actual sotred HTML:

Function Test() As String
Dim rs As DAO.Recordset
Set rs = CurrentDb.OpenRecordset("Table2")
Dim s As String
rs.MoveFirst
Debug.Print rs!RTF
Debug.Print
Test = rs!RTF
End Function
==========================================
? test
<div><font face=Algerian>This is a rich </font><font face=Algerian
color="#ED1C24">text</font><font face=Algerian> field</font></div>

<div><font face=Algerian>This is a rich </font><font face=Algerian
color="#ED1C24">text</font><font face=Algerian> field</font></div>


> 

> 
> Bizarre functionality.
> 
> My question to those more knowledgeable than I, Is there any way to
> actually use those other fancy fonts with my <font face = FontX> tag. 
> I understand the limitations of "what is on MY computer" but still.  I
> am totally unable to display things other than bog standard.
> 
> -- 
> John W. Colby
> Colby Consulting
> -- 
> AccessD mailing list
> AccessD at databaseadvisors.com
> https://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
> 




More information about the AccessD mailing list