Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Form works once only
This routine works once, but fails on subsequent occassions.
Private Sub wholemonthbutton3_click() ListBox1.ListIndex=0 ListBox2.ListIndex = ListBox2.ListCount - 1 ' This line fails Msgbox "Listbox2.Value = " & ListBox2.Value _ & " Count =" & ListBox2.ListCount end sub The first time the sub works. The second time ListBox2.value ="" When the OK button is hit I have Unload Me. When the routine has returned to the calling program I have Unload DatesForGraph. Before the routine is called again I have the same statement. So I think it should be unloaded 3 times but still it gives me the wrong answer! Please advise where am I may be going wrong. (Excel 2003) |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Macros: Step Thru Works, Run Works, Keyboard Shortcut Locks up | Excel Programming | |||
Alt-Tab works differently if Form called from Menu or Buttonbar Icon | Excel Programming | |||
How do I convert works file to excel without works software? | Excel Discussion (Misc queries) | |||
listbox works in form; not imbedded??? | Excel Programming |