Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hi
i wish to change the font for a button object when it is qliked
can i include some code in the expression which will check the "active" state of the object and take approp action ?
anything in "mind" ?
hi,
If you don't want to change the existed text of a button then comment the below line in the macro of my earlier post.
prop.Text.v = "Change_Font"
It will works for all the objects for that you need to provide those objectID's in the macro.
Regards
..........
Do you want to change the font on the button? And I'm assuming that you wanted to change the font style? Is this right, or do you want to change text on the button where user "Clicks"?
Thanks,
DV
hi,
Use the below macro in a button action.
Hope it helps you.
Sub TestFont
set button = ActiveDocument.GetSheetObject("BU04")
set prop = button.GetProperties
set fnt=button.GetFrameDef.Font
prop.Text.v = "Change_Font"
fnt.PointSize1000 = fnt.PointSize1000 + 2000
'prop.TextColor.PrimaryCol.Col = RGB(255,0,0)
button.SetProperties prop
button.SetFont fnt
End Sub
Regards
..........
hi,
If you don't want to change the existed text of a button then comment the below line in the macro of my earlier post.
prop.Text.v = "Change_Font"
It will works for all the objects for that you need to provide those objectID's in the macro.
Regards
..........
thanks Rav and regrads, clive
Hi,
Please mark the correct answer if it works.So that others can able to get the solution.
Regards
...........