LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #9   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 86
Default UserForm_Initialize is not recognized??

Yes, that worked! Thanks!


"Dave Peterson" wrote:

Another thing to try against a copy of the troublesome workbook.

Start a new workbook (just a temporary workbook).
Open a copy of that troublesome workbook.

Go into the VBE.

Show the project explorer (ctrl-r if it isn't visible)

Drag the userform from the troublesome workbook project to the temporary
workbook project.

Does it work ok there?

If yes, try deleting the old userform in the troublesome workbook project.

Drag the userform from the temporary workbook project back to the original
workbook project.

Does it work ok there?

If yes, save the copy and use that instead.



Sam Kuo wrote:

I add another userform as you said, and "UserForm" appears in the righthand
side dropdown of the new userform's code window alright.

However, the event procudures of all controls in the old userform still
works fine. It's only the old userform that cannot be recognized in the VBE.

I wish there is a solution to this problem, as the last thing I want to do
is to retrieve from backup and re-do all the changes I've made...

"Dave Peterson" wrote:

If you add another userform to the same workbook's project, do you see
everything ok?

I've seen situations where worksheets seem to have ghosts inside the VBE. The
worksheet is deleted, but it looks like it's still there in the VBE.

I've never seen this with userforms, though.

Sam Kuo wrote:

Hi Dave

1) Yes, the code is in the userform module as before when it was still
working.
2) There is no "UserForm" for me to select from the lefthand side dropdown.
But the form does exists!

So I'm really lost now...Any idea?

Sam

"Dave Peterson" wrote:

And you're sure your in the userform module?

My second guess is that even though you typed in the correct spelling in your
post, you have a typo in your actual code.

I'd change the lefthand side dropdown to Userform and then choose Initialize
from the righthand side. Maybe you'll see the typo--or just delete the line
with the typo and move the generated line to where it belongs.



Sam Kuo wrote:

Hi

I have one form and an event procedure UserForm_Initialize().

This event procedure was working fine before, but somehow Excel doesn't seem
to recognize the form now (i.e. when I put the cursor within that event
procedure, the object dropdown in the top middle of VB window now shows
"(General)", and "Userform_Initialize" in the event dropdown in the top left)

Please help me!!

Sam

--

Dave Peterson


--

Dave Peterson


--

Dave Peterson

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
UserForm_Initialize Edwin Tam[_7_] Excel Programming 1 April 13th 06 04:49 PM
UserForm_Initialize Bob Phillips[_6_] Excel Programming 1 April 13th 06 04:43 PM
UserForm_Initialize() Joe Derr[_2_] Excel Programming 3 December 4th 04 04:23 AM
UserForm_Initialize Rob Excel Programming 2 January 15th 04 02:00 PM
UserForm_Initialize? How to update. Jelso Excel Programming 2 September 5th 03 07:51 AM


All times are GMT +1. The time now is 06:03 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"