Autoscrolling a listbox to the bottom

This function, when called with the name of the control window and the listbox name will scroll the listbox to the very bottom, such as if you had used the scrollbar to do it.

Function autoscrolllistbox(ctrlwindow,listboxname)
	string ctrlwindow,listboxname
	controlinfo/w=$ctrlwindow $listboxname
	Wave/z w = $S_DataFolder
	if(V_Flag>0)
		listbox/z $listboxname win=$ctrlwindow,row=ceil(dimsize(w,0)-V_height/V_rowheight)
	endif
End

Forum

Support

Gallery

Igor Pro 10

Learn More

Igor XOP Toolkit

Learn More

Igor NIDAQ Tools MX

Learn More