View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
DanB DanB is offline
external usenet poster
 
Posts: 12
Default Testing to find if UserForm is Loaded

Not quite what I'm looking for but it'd probably work.
I'll need to check if the result is different for testing both Hidden and
Unloaded Forms.

To be more specific, if I had a form that was previously Unloaded I want to
make sure that it doesn't exist before I try to Unload it again. I was
hoping that there was something as simple as an IsLoaded property, but no
such luck.

If there's another way of detecting, I'm all ears!

Best,
DB

"JLGWhiz" wrote:

Why not use and If ...Then statement:

If UserForm1.Visible = True Then
'Do something
Else
UserForm1.Show
'Do something
End If


"DanB" wrote in message
...
I have multiple userforms open and hidden.

How can I test to see if a userform is loaded before attempting to either
Unload or change attributes to any controls contained therein?

thanks,

DanB