Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I am stymied trying to figure the code that sets the focus of an
ActiveX ListBox to the first name appearing in the ListBox. The ListBox is on Sheet1. I tried this code but get the error message "Compile Error Sub or Function not defined" I am using Excel 2007 Private Sub Workbook_Open() Application.ScreenUpdating = False Sheets("Sheet1").Select OLEObject("ListBox1").Value = "ABC" Application.ScreenUpdating = True End Sub Can anyone help me correct this code so when the workbook opens - it displays the right sheet and the ListBox shows the focus on the first name? Thank you, Rob |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
ListBox Property where 'focus' triggers selection | Excel Programming | |||
ActiveX Combo Box Focus | Excel Programming | |||
Listbox Item Focus | Excel Programming | |||
ActiveX comboboxes on worksheet (lost focus problems) | Excel Programming | |||
removing selection focus in listbox | Excel Programming |