Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Modal form load

Status
Not open for further replies.

DickDavies

IS-IT--Management
Jan 4, 2002
22
GB
I have a modal form consisting of a rich text box and two command buttons (save and exit) which can be called from other forms (mdichild) in the app.

calling code:
If FormEdit.Visible Then Unload FormEdit
FormEdit.Show 1

When loaded the command buttons on the modal form ignore the first few clicks ! If I set a breakpoint on the 'FormEdit.Show 1' command then all is ok !!

The modal form seems to recursively fire events load/activate/queryunload/unload each time a command button is clicked - but after a few clicks all is ok.

I use some global variables in the modal form - is it possible that it loads too fast ?
 
riched20.dll Version 5.30.23.1215
riched32.dll Version 5.0.2134.1
ritx32.ocx Version 6.0.81.69

Interesting. Suggests that the fact that strongm has a different version of the ocx isn't relevant, doesn't it?

Bob
 
Suggests that it is, I think. George gets an error on his office machine (ocx 6.1.97.82) and so do I on the machine in front of me (ocx 6.1.97.82). You, Bob, don't seem to with ocx 6.0.81.69, and neither does George with ocx 6.0.81.69

So, it begins to look as if RichTx32.ocx version 6.1.97.82 may be the culprit ...



 
Scratch that, wooly thinking again, with a little dyslexia thrown in for good measure. Quite the reverse: it would seem that it may very well be the ocx version that's the problem.

Bob
 
All we need to know now (even though he's changed his approach) is what version of the OCX Dick has ...
 
The plot thickens. I copied the ocx from the laptop to the desktop. Registered the ocx. And still the desktop exhibits the buggy behavior.

-George

Strong and bitter words indicate a weak cause. - Fortune cookie wisdom
 
Any possibility that the system replaced the old version with the new version on restart, as it is wont to do with many other library files, or have you completely ruled that out?

Bob
 
Bob,

As a rule, I generally avoid tossing dll's about in some sort of willy nilly fashion. Here's exactly what I did.

1. Copy RichTx32.ocx from C:\Windows\system32 to a smart media card.
2. Threw the SM card in to the desktop, and copied the file to a new folder that I created.
3. Register the file I just copied.
4. Went to VB and checked in components to make sure the 'proper' ocx was being used. It was.
5. Ran the app, and the bug continued to appear.

Perhaps that was not the bet way to test the control. If there is a better method to testing it, let me know and I'll try. It'll have to wait until tomorrow since I am home now.

As I was sitting in my office, pondering this problem, I thought to myself.... Self, what else could be going on here? So, I went on a VB6 runtime dll hunt. Checking both systems, the versions of the runtimes dll's were the same. So, let me be clear. The runtime dll's on the laptop are the same version as the runtime dll's on the desktop. Oddly enough, the runtimes on both systems have different versions than the runtimes that microsoft claims to install.


I haven't tried downloading the runtime service pack and installing on my work computer. I may give that a shot tomorrow.

-George

Strong and bitter words indicate a weak cause. - Fortune cookie wisdom
 
replacing .82 with .69 and still getting the same behaviour
has no logic.
Perhaps you should remove the control and create it new on
your form.

fh
 
Same versions as George

RichEd20.dll Version 5.30.23.1221
RichEd32.dll Version 5.1.2600.0
RichTx32.ocx Version 6.1.97.82

Dick D
 
Dick's second post describes the symptoms we've been getting - so I'd suspect he is
 
strongm,

Since you are experiencing the buggy behavior, perhaps you could try with the version of Richtx32.ocx that I have. If you assure me that it is legal to do so, I will post my 6.0.81.69 version on a website for you to download.

Whadda think?

-George

Strong and bitter words indicate a weak cause. - Fortune cookie wisdom
 
I have a number of RichTx32s available on this PC. If I get the time I'll try several of them out.
 
<Dick's second post describes the symptoms we've been getting - so I'd suspect he is

On my way to the dunce's corner, where I will continue working on my new habit of opening my mouth only when I'm fairly sure I have something to contribute....
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top