Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Show/Unload Userform
For some reason, I keep getting a message "Runtime error 361. Can't unload
this object." The part that has me stumped is that "frmWEFNetPlotting.Show" works fine. "Unload frmWEFNetPlotting" debugs with that message. Any suggestions? Obviously they're referencing the same object, but I don't see why it will show the object, but then not unload it. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Show/Unload Userform
Strange
If you use "Unload Me" in the code in the userform module do you have the same problem then Where do you use the code line Unload frmWEFNetPlotting -- Regards Ron de Bruin http://www.rondebruin.nl "StephanieH" wrote in message ... For some reason, I keep getting a message "Runtime error 361. Can't unload this object." The part that has me stumped is that "frmWEFNetPlotting.Show" works fine. "Unload frmWEFNetPlotting" debugs with that message. Any suggestions? Obviously they're referencing the same object, but I don't see why it will show the object, but then not unload it. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Show/Unload Userform
I use
Sub NetWEFPlotting() frmWEFNetPlotting.Show End Sub to bring up the form. Then within my form: Private Sub Cancel_Click() Unload frmWEFNetPlotting End Sub Private Sub OK_Click() For i = 0 To ListBox1.ListCount - 1 If ListBox1.Selected(i) Then Workbooks.Open Filename:="\\Fl-msjf-fs1\Data\Data\RECOVERY\EXLDATA\Loan Recovery MIS\Net Placement Plotting\WEF\WEF " & ListBox1.List(i) & " Net Plotting by Placement.xls" End If Next i Unload frmWEFNetPlotting End Sub Private Sub Userform_Initialize() With ListBox1 .AddItem "Primary", 0 .AddItem "Secondary", 1 .AddItem "Tertiary", 2 .AddItem "Deceased", 3 .AddItem "Internal", 4 .AddItem "IGATLB", 5 End With End Sub I just switched it to "Unload Me" and that works fine. I'll leave it that way, but that was really strange. "Ron de Bruin" wrote: Strange If you use "Unload Me" in the code in the userform module do you have the same problem then Where do you use the code line Unload frmWEFNetPlotting -- Regards Ron de Bruin http://www.rondebruin.nl "StephanieH" wrote in message ... For some reason, I keep getting a message "Runtime error 361. Can't unload this object." The part that has me stumped is that "frmWEFNetPlotting.Show" works fine. "Unload frmWEFNetPlotting" debugs with that message. Any suggestions? Obviously they're referencing the same object, but I don't see why it will show the object, but then not unload it. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
unload userform problem | Excel Programming | |||
Unload Userform doesn't work here - why? | Excel Programming | |||
Userform Question (Load/Unload/Show/Hide) | Excel Programming | |||
load/unload userform | Excel Programming | |||
unload userform from within one of that form's beforeupdate events? | Excel Programming |