Image Button without border and without animation to open web adress

border:false -- doesn't help. It's showing black border and is animating when mouse over - I want it to work like usual images but to open link when pressed

dotNetControl logobtn "Button" pos:[0,0] width:400 height:286 border:false
on testRoll open do (logobtn.image = (StringToImage img_logo))
 
 
on logobtn click do
	(
        	HyperLink Hypl_homepage "homepage" pos:[50,320] width:65 height:15 address:"www.google.com"
	)
 
<code>

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
artrender.info's picture

SOLVED!!!! Thx boys!

I've come up with this and it's working great!

dotNetControl logobtn "System.Windows.Forms.Label" pos:[0,0] width:400 height:286
on testRoll open do (logobtn.image = (StringToImage img_logo))
on logobtn click do  --pressed do 
	(
        	ShellLaunch @"http://www.scriptspot.com"  ""
	)
Anubis's picture

solved?...

What about border and animation of the button? At least this is the actual question in your title.

Take a look at imgTag ui control.

Cheers!

my recent MAXScripts RSS (archive here)

artrender.info's picture

srry, but I don't understand

What code would you use? I'm new in max scripting but I'm an old max user, and I want to simplify things that I'm repeating for years! That's why I started to learn maxscript! But I APPRECIATE your time that you consume to help others! You are a big BLESSING for new scripters!

Anubis's picture

well... :)

Your main question was about visual behaviour of your button, not about it action (what happen when its clicked), and I not see how you solved your main query, for that I ask ;-)

Usually, buttons or other interactive controls using icons to represent there state like when selected (get focus), pressed, checked, disabled, etc. And all this is made with meaning to help as know that the control react to us.

I have the feeling you need a "button" without such visual changes, therefore I thought about using ImgTag.

So, am was just curious how you solve this.

my recent MAXScripts RSS (archive here)

barigazy's picture

Hey Panayot i send you PM

Hey Panayot i send you PM about your previous question. devX ctrl produce best visual style but also slowest one

:)

bga

Anubis's picture

thanks

But I'm still stubborn donkey anchored to Max 2009 :lol:
Can I test somehow DevX on my shack?

my recent MAXScripts RSS (archive here)

barigazy's picture

If you ask me, i combine .net

If you ask me, i combine .net and mxs in most cases. But in your case i not see the reason why not use imgTag ctrl. .net is for more complicated tasks only (when standard mxs ctrl not get you right solution).
That's my opinion.

bga

barigazy's picture

Yep. That is best mxs

Yep. That is best mxs solution but he start with dotnet button controll, and end up with dotnet label ctrl. I guess that's OK.

bga

miauu's picture

This will open the scriptspot web page with the default browser.

on btn_openWebPage pressed do
(
	ShellLaunch @"http://www.scriptspot.com"  ""
)
barigazy's picture

u can use dotnet label

u can use dotnet label

bga

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.