Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Circular Buttons in Forms 2

Status
Not open for further replies.

Only1Abhi

Technical User
Jan 26, 2003
77
GB
Hi.
I need to create circular (and other shaped) buttons in forms.

Other colors apart from the plain dark grey would also help.

Does any1 have any suggestions?

Many thanks in advance.

Regards,
Abhi
 
Since I don't know if there's a method to do it directly, I did it this way:
Insert the button as an image and put your code in the OnClick property. Depending on its purpose, you can have the wizard creating the button and use the (modified)code.

You're not alone,

TomCologne
 
Thanks Tom,

I know how to makes pictures as links but when u click on buttons they change (they look pressed). I wanted this animation aswell. That's why I specifcally said buttons.

Does any1 else have suggestions?

Many thanks Tom and to others in advance.
 
My pleasure.
Maybe you can find an AddIn or something else. If not, the "Push Button" effect could be simulated with labels or background images and some properties code assembly, visible, timer etc..
Good luck,

TomCologne
 
Thanks for the suggestion Tom,

Can u plz guide me on what to do plz?

How can I use lables, background images, code assembly, visible and timer to create this effect? I'm confused.

I would be greateful if u could shed a bit of light on this matter.

:)
 
Those were just a few options that came to mind, not a complete listing. You can, i.e. create a label as a button and change its border style in the OnClick procedure that performs the 'real' task or draw a rectangular frame around it (invisible) and 'illuminate' it by selecting a color and setting the Visible property to True in the event procedure for a backlit effect or....
Here's a primitive example that makes a rectangle,SpecialEffect=Sunken, visible when the button is clicked:

cmdXXX_Click()
stDocName = "qryXXX"
DoCmd.OpenQuery stDocName, acNormal, acEdit
Forms!frmXXX!txtBacklitFrame.Visible = True

There are quite a few ways to achieve that 'Push' effect, just play with it to find the one you want.
If you find an easier solution I'd appreciate your posting it here.
This was hopefully a little help, let me know how it works, please.

Have fun,

TomCologne
 
Hi,

Another 'standard' way is to have 2 images per button - 1 looks unclicked, other looks clicked.

When the image is clicked - change the image source to the other image.

Be warned that it takes a lot of time to get these images looking just right on the form (you have to maintain the 3d effect). You also have to ensure that any image background pixels on the image are exactly the same as the form colour.

(Same type of idea as from Tom).

Regards,

Darrylle "Never argue with an idiot, he'll bring you down to his level - then beat you with experience." darrylles@totalise.co.uk
 
thanks for the help Tom & Darrylles.

I used the 2 different images thing to get the effect. I finally got it.

Thanks a lot for both of your help in this matter.

Regards,
Abhi
:)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top