Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sorry for the multipost but my message didn't appear in the other
group and microsoft.public.excel.programming is more appropriate anyway. A code snippet: Function FillYearMonth(ByVal theWorkSheet As String, ByVal thePivotTable As String, ByVal thePageField As String) Dim ws As Worksheet Set ws = Worksheets(theWorkSheet) Dim pt As PivotTable Set pt = ws.PivotTables(thePivotTable) Dim pf As PivotField Set pf = pt.PivotFields(thePageField) Dim lb As ListBox Set lb = Worksheets(theWorkSheet).lstYearMonth Call FillListBox(pf, lb) End Function I keep getting error 13 after executing the line Set lb = Worksheets(theWorkSheet).lstYearMonth I checked and there really is a ListBox called lstYearMonth on the worksheet (on ever worksheet there is a ListBox named lstYearMonth) Can anyone point me what is wrong in this code? -- Amedee |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Worksheet setting error... | Excel Worksheet Functions | |||
error 13 when setting worksheet listbox | Excel Discussion (Misc queries) | |||
Setting a Control Variable for a listbox | Excel Programming | |||
Setting Listbox Size VBA | Excel Worksheet Functions | |||
Setting and filter Listbox data | Excel Discussion (Misc queries) |