Reading report font slots
Doug Easterbrook
doug at artsman.com
Tue Dec 15 01:08:42 EST 2020
hi Scotte
I have not done it for reports fonts.. But I know I’ve done it for some other things that are ’not easy to get at’. so I dug this up for how we change $numberformats and $inputMasks.
I do not see these in the $prefs for a library when inspecting it..
we use styles in reports and you can get a list of $fieldstyles — — but those attributes only seem to say that it $hasfont
and after a little sleuthing…. looks like $root.$libs.YOURLIBRARY.$prefs.$reportfonts might be what you want.
so try a makelist on them, or addressing the ’$fontname’ directly like the following… which gave me ’times new roman'
Calculate #S1 as $clib.$prefs.$reportfonts.1.$fontname
hope that helps.
------
# Allow user to set the display format of the account number
Calculate $clib.$prefs.$numberformats.13.$text as pick(len($ctask.tDefaultData.D_DEFAULT_ACCT_NO_FORMAT)>0,'0-0000-000',$ctask.tDefaultData.D_DEFAULT_ACCT_NO_FORMAT)
Calculate inputMask as con('>>',$clib.$prefs.$numberformats.13.$text)
Do tStringFields.$replace(inputMask,'0','#',inputMask) Returns I_ERROR_CODE
Calculate $clib.$prefs.$inputmasks.13.$text as inputMask
Doug Easterbrook
Arts Management Systems Ltd.
mailto:doug at artsman.com
http://www.artsman.com
Phone (403) 650-1978
> On December 14, 2020, at 3:56 PM, Scotte Meredith <spomacguy at gmail.com> wrote:
>
> Hi all --
>
> I've done this before somewhere, but I can't find any code snippets.
>
> How do I read the font slots out of #WIRFONTS in Studio 10.2? I want to get a list of fonts by slot. Later I will need to write to it.
>
> I set an item reference to the #WIRFONTS but there is nothing valuable to see in Property Manager
>
> Set reference lirRef to $clib.$classes.#WIRFONTS
>
> Scotte Meredith
> spomacguy at gmail.com
> 509/998-0991
>
>
>
>
> _____________________________________________________________
> Manage your list subscriptions at http://lists.omnis-dev.com
> Start a new message -> mailto:omnisdev-en at lists.omnis-dev.com
More information about the omnisdev-en
mailing list