Your prc works fine. I am using Cygwin for
compilation. I am able to create and access font file
using xFont.
But when i call FntDefineFont, FntSetFont in my code
where we enter a character in 'Field' under
'KeyDownEvent', but changing into customize font for
characters which are typed on a 'Field' doesn't work.
ex code:
case keyDownEvent:
FieldPtr fldP =
(FieldPtr)FrmGetObjectPtr(FrmGetActiveForm(),
FrmGetObjectIndex(FrmGetActiveForm(),1002)); // my
password field
MemHandle textH = FldGetTextHandle(fldP);
if ( textH )
{
FldSetTextHandle(fldP, textH);
MemPtr textP = MemHandleLock(textH);
char * fldStr = FldGetTextPtr(fldP);
fontHandle = DmGetResource(fontRscType,resource);
if ( fontHandle )
{
fontP = (FontPtr)MemHandleLock(fontHandle);
if ( fontP )
{
FntDefineFont( fID, fontP );
}
fntID = FntSetFont( fID );
if (fontHandle)
{
MemHandleUnlock(fontHandle);
DmReleaseResource(fontHandle);
}
MemhandleUnlock(...)
}
This is just example snippet, so don't mind about
memfree etc.,
Tell me what is the wrong from this logic.
cathy.
--- Caio Proiete
<[EMAIL PROTECTED]> wrote:
> Of course you can... I do it all the time.
> Did you ever clicked on the link I've pointed you
> to?
>
> Bwlow you can download a sample PRC that does just
> what we are talking about: Change the font of a
> FIELD to a font that displays only "*" chars.
>
> http://tinyurl.com/2c459f
>
> Cheers,
> Caio Proiete
>
> --
> For information on using the ACCESS Developer
> Forums, or to unsubscribe, please see
http://www.access-company.com/developers/forums/
Unlimited freedom, unlimited storage. Get it now, on
http://help.yahoo.com/l/in/yahoo/mail/yahoomail/tools/tools-08.html/
--
For information on using the ACCESS Developer Forums, or to unsubscribe, please
see http://www.access-company.com/developers/forums/