Why my button doesn't work?

I'm a noob in maxscript. I know I need lot tutorials to watch to start, but now i need this thing to work. please help!!
when I evaluate all then it shows the result in lstener, but it doesnot work under the button.
Thank You.

rollout rollout1 "Untitled" width:162 height:300
(
	button 'btn11' "Button" pos:[38,100] width:88 height:53 align:#left
	on btn11 pressed do
		viewport.GetFOV
)
 
 
 
Floater10 = newrolloutfloater "10" 200 200
 
addRollout 'rollout1' Floater10

Comments

Comment viewing options

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

.

This is also works,

rollout rollout1 "Untitled" width:162 height:300
(
	button 'btn11' "Button" pos:[38,100] width:88 height:53 align:#left
	on btn11 pressed do
	(
	a = viewport.GetFOV()
	print a
	)
 )
Floater10 = newrolloutfloater "10" 200 200
addRollout 'rollout1' Floater10
miauu's picture

.

(
	rollout rollout1 "Untitled" width:162 height:300
(
	button 'btn11' "Button" pos:[38,100] width:88 height:53 align:#left
	on btn11 pressed do
	(
		vptFOV = viewport.GetFOV()
		format "vptFOV: % \n" vptFOV
	)
)
 
 
 
Floater10 = newrolloutfloater "10" 200 200
 
addRollout 'rollout1' Floater10
)

Comment viewing options

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