Home All Groups Group Topic Archive Search About

Compile, Save, Exit, ReStart, big trouble

Author
12 Oct 2005 3:34 AM
Lorin
I have an App that works in the IDE.
I compile with no errors.
I start to exit the IDE and IDE asks to save.  I do.
I restart and get a bunch of errors.
The tab strip is now a picture box and some others change to pictureboxes too.
I exit without saving this mess.
I open App.VB in Notepad and find two entries Reference=*\G{118DAE1B-1D19-4EC1-8C91-ACFA017EC96A}#1.3#0#..\..\WINDOWS\system32\comctl32.oca#Microsoft Windows Common Controls 5.0 (SP2)
Object={6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0; comctl32.ocx
I delete the first one and restart with no errors.
Found out how to do this by trial and lots of errors.
Who is putting the duplicate entry into the App.VB file?
Why is it doing this?
How do I stop this?
This same thing happens when this app is updated to SP6.
I made sure there are no old controls in the app.
I have several apps that do this and many others that do not but I cannot
yet see the difference.

Author
12 Oct 2005 8:35 AM
Jan Hyde
"Lorin" <Lo***@discussions.microsoft.com>'s wild thoughts
were released on Tue, 11 Oct 2005 20:34:02 -0700 bearing the
following fruit:

>I have an App that works in the IDE.
>I compile with no errors.
>I start to exit the IDE and IDE asks to save.  I do.
>I restart and get a bunch of errors.

What errors?

>The tab strip is now a picture box and some others change to pictureboxes too.
>I exit without saving this mess.
>I open App.VB in Notepad and find two entries
>Reference=*\G{118DAE1B-1D19-4EC1-8C91-ACFA017EC96A}#1.3#0#..\..\WINDOWS\system32\comctl32.oca#Microsoft Windows Common Controls 5.0 (SP2)
>Object={6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0; comctl32.ocx
>I delete the first one and restart with no errors.
>Found out how to do this by trial and lots of errors.
>Who is putting the duplicate entry into the App.VB file?

App.VB file? Are you talking .Net here? Because if you are
you need to be asking in a dotnet group.

>Why is it doing this?
>How do I stop this?
>This same thing happens when this app is updated to SP6.

SP6 for VB6?

>I made sure there are no old controls in the app.
>I have several apps that do this and many others that do not but I cannot
>yet see the difference.

Before we go and further I think we need to determine which
language your working in.




Jan Hyde (VB MVP)

--
Defence: Perimeter of de garden (Jan Hyde)

[Abolish the TV Licence - http://www.tvlicensing.biz/]
Author
13 Oct 2005 4:53 AM
Lorin
Running
VB6 SP6

Show quoteHide quote
"Jan Hyde" wrote:

> "Lorin" <Lo***@discussions.microsoft.com>'s wild thoughts
> were released on Tue, 11 Oct 2005 20:34:02 -0700 bearing the
> following fruit:
>
> >I have an App that works in the IDE.
> >I compile with no errors.
> >I start to exit the IDE and IDE asks to save.  I do.
> >I restart and get a bunch of errors.
>
> What errors?
>
> >The tab strip is now a picture box and some others change to pictureboxes too.
> >I exit without saving this mess.
> >I open App.VB in Notepad and find two entries
> >Reference=*\G{118DAE1B-1D19-4EC1-8C91-ACFA017EC96A}#1.3#0#..\..\WINDOWS\system32\comctl32.oca#Microsoft Windows Common Controls 5.0 (SP2)
> >Object={6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0; comctl32.ocx
> >I delete the first one and restart with no errors.
> >Found out how to do this by trial and lots of errors.
> >Who is putting the duplicate entry into the App.VB file?
>
> App.VB file? Are you talking .Net here? Because if you are
> you need to be asking in a dotnet group.
>
> >Why is it doing this?
> >How do I stop this?
> >This same thing happens when this app is updated to SP6.
>
> SP6 for VB6?
>
> >I made sure there are no old controls in the app.
> >I have several apps that do this and many others that do not but I cannot
> >yet see the difference.
>
> Before we go and further I think we need to determine which
> language your working in.
>
>
>
>
> Jan Hyde (VB MVP)
>
> --
> Defence: Perimeter of de garden (Jan Hyde)
>
> [Abolish the TV Licence - http://www.tvlicensing.biz/]
>
>
Author
13 Oct 2005 8:20 AM
Jan Hyde
"Lorin" <Lo***@discussions.microsoft.com>'s wild thoughts
were released on Wed, 12 Oct 2005 21:53:02 -0700 bearing the
following fruit:

>Running
>VB6 SP6

Usually you see the picture box replacing controls when the
reference to the ocx is broken or missing, it's unusual
(well I've never seen it) that it happens witht he common
controls.

I can't guess why it might be happening in this case but I
can offer some advice. Never, ever save a form once controls
have been changed to picture boxes, otherwise you have to
painstakingly replace them all.

Load the project, ignore all the errors, fix the references
in the VBP and save ONLY the vbp. You should be able to load
the project correctly now.

J

Show quoteHide quote
>"Jan Hyde" wrote:
>
>> "Lorin" <Lo***@discussions.microsoft.com>'s wild thoughts
>> were released on Tue, 11 Oct 2005 20:34:02 -0700 bearing the
>> following fruit:
>>
>> >I have an App that works in the IDE.
>> >I compile with no errors.
>> >I start to exit the IDE and IDE asks to save.  I do.
>> >I restart and get a bunch of errors.
>>
>> What errors?
>>
>> >The tab strip is now a picture box and some others change to pictureboxes too.
>> >I exit without saving this mess.
>> >I open App.VB in Notepad and find two entries
>> >Reference=*\G{118DAE1B-1D19-4EC1-8C91-ACFA017EC96A}#1.3#0#..\..\WINDOWS\system32\comctl32.oca#Microsoft Windows Common Controls 5.0 (SP2)
>> >Object={6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0; comctl32.ocx
>> >I delete the first one and restart with no errors.
>> >Found out how to do this by trial and lots of errors.
>> >Who is putting the duplicate entry into the App.VB file?
>>
>> App.VB file? Are you talking .Net here? Because if you are
>> you need to be asking in a dotnet group.
>>
>> >Why is it doing this?
>> >How do I stop this?
>> >This same thing happens when this app is updated to SP6.
>>
>> SP6 for VB6?
>>
>> >I made sure there are no old controls in the app.
>> >I have several apps that do this and many others that do not but I cannot
>> >yet see the difference.
>>
>> Before we go and further I think we need to determine which
>> language your working in.
>>
>>
>>
>>
>> Jan Hyde (VB MVP)
>>
>> --
>> Defence: Perimeter of de garden (Jan Hyde)
>>
>> [Abolish the TV Licence - http://www.tvlicensing.biz/]
>>
>>


Jan Hyde (VB MVP)

--
What do you do if you see a spaceman. Park your car in it man.  (Geoff Tibballs)

[Abolish the TV Licence - http://www.tvlicensing.biz/]
Author
12 Oct 2005 3:29 PM
Ralph
"Lorin" <Lo***@discussions.microsoft.com> wrote in message
news:35C72369-458F-442F-A7A0-26BE59BFC755@microsoft.com...
> I have an App that works in the IDE.
> I compile with no errors.
> I start to exit the IDE and IDE asks to save.  I do.
> I restart and get a bunch of errors.
> The tab strip is now a picture box and some others change to pictureboxes
too.
> I exit without saving this mess.
> I open App.VB in Notepad and find two entries
>
Reference=*\G{118DAE1B-1D19-4EC1-8C91-ACFA017EC96A}#1.3#0#..\..\WINDOWS\syst
em32\comctl32.oca#Microsoft Windows Common Controls 5.0 (SP2)
> Object={6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0; comctl32.ocx
> I delete the first one and restart with no errors.
> Found out how to do this by trial and lots of errors.
> Who is putting the duplicate entry into the App.VB file?
> Why is it doing this?
> How do I stop this?
> This same thing happens when this app is updated to SP6.
> I made sure there are no old controls in the app.
> I have several apps that do this and many others that do not but I cannot
> yet see the difference.
>

One source of this behavior is because of a 'syntax' error or un-resolved
reference within your code. It is sort of the obverse to the phenomena where
VB will report a bogus 'un-resolved' error on a line that actually contains
a 'referenced' item - when there is a 'missing' reference. (there, did that
confuse you? <g>).

Anyway, when you get your project up and running check references for
anything missing and open the components and recheck anything you are using.

Then do a complete compile (make) - you will likely find something odd, like
a Sub defined with a return, wrong type, missing implemented member, wrong
parameters, etc.  It will be something normally caught, but for some reason
you were able to confuse VB before you saved the project.

Do an occasional full compile during development in order to head off these
kinds of errors.

-ralph
Author
12 Oct 2005 3:47 PM
Ken Halter
"Lorin" <Lo***@discussions.microsoft.com> wrote in message
news:35C72369-458F-442F-A7A0-26BE59BFC755@microsoft.com...
>I have an App that works in the IDE.
> I compile with no errors.
> I start to exit the IDE and IDE asks to save.  I do.
> I restart and get a bunch of errors.
> The tab strip is now a picture box and some others change to pictureboxes
> too.
> I exit without saving this mess.

Good.... Once you save, you're hosed <g>

> I open App.VB in Notepad and find two entries
> Reference=*\G{118DAE1B-1D19-4EC1-8C91-ACFA017EC96A}#1.3#0#..\..\WINDOWS\system32\comctl32.oca#Microsoft
> Windows Common Controls 5.0 (SP2)
> Object={6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0; comctl32.ocx
> I delete the first one and restart with no errors.

Correct. The VBP file should never contain any permanent references to
OCA's.

> Found out how to do this by trial and lots of errors.
> Who is putting the duplicate entry into the App.VB file?
> Why is it doing this?
> How do I stop this?
> This same thing happens when this app is updated to SP6.
>
> I made sure there are no old controls in the app.
> I have several apps that do this and many others that do not but I cannot
> yet see the difference.

"My Theory" as to why this is happening more and more as new OSs/SPs come
out...... hard-drive write caching (iow, it's a timing problem)  VB is
supposed to replace any references to OCAs with references to OCX's when you
close your project. Something (?) is preventing this from happening. I've
never had both OCX and OCA show but I do get OCA errors. Mostly from the
CommonDialog OCX.

One thing to try is.... fire up Windows Explorer, search for *.oca and
delete every single one of them. Since VB will re-create them on demand (and
we're not on 386's any more), they're just extra baggage. Problem is,
they're also registered... which means, you'll be better off if you run
RegClean after deleting them.

I'm planning on adding an OCA scanner to my ComGuard add-in that will scan
projects for OCA references before attempting to load them. Might even add
functionality that removes the OCA from the registry and deletes it when the
project closes. (sounds good to me...)

--
Ken Halter - MS-MVP-VB - http://www.vbsight.com
DLL Hell problems? Try ComGuard - http://www.vbsight.com/ComGuard.htm
Please keep all discussions in the groups..
Author
13 Oct 2005 5:02 AM
Lorin
Hmmm...

Although there are no reference to previous objects, since I cleaneand them
all out and removed the components (not in the component area) i wonder if a
vbx might still contain a reference.

I notice that .vb files contain references to deletions.

There may be a bug in the compile process that sees a "ghost" and tries to
work with it.

I have had a few apps unrelated with this same problem.
As i remember they were old VB6 that were upgraded to newer components.
Seems like it is component related but I cannot find where this is referenced.

At least now I know how to recover.  In the past i rebuild program components.
i.e. deleted the picturebox that was a tabstrip and then put the tab strip
back in.
That was the hard way with multiple componets.


Show quoteHide quote
"Ken Halter" wrote:

> "Lorin" <Lo***@discussions.microsoft.com> wrote in message
> news:35C72369-458F-442F-A7A0-26BE59BFC755@microsoft.com...
> >I have an App that works in the IDE.
> > I compile with no errors.
> > I start to exit the IDE and IDE asks to save.  I do.
> > I restart and get a bunch of errors.
> > The tab strip is now a picture box and some others change to pictureboxes
> > too.
> > I exit without saving this mess.
>
> Good.... Once you save, you're hosed <g>
>
> > I open App.VB in Notepad and find two entries
> > Reference=*\G{118DAE1B-1D19-4EC1-8C91-ACFA017EC96A}#1.3#0#..\..\WINDOWS\system32\comctl32.oca#Microsoft
> > Windows Common Controls 5.0 (SP2)
> > Object={6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0; comctl32.ocx
> > I delete the first one and restart with no errors.
>
> Correct. The VBP file should never contain any permanent references to
> OCA's.
>
> > Found out how to do this by trial and lots of errors.
> > Who is putting the duplicate entry into the App.VB file?
> > Why is it doing this?
> > How do I stop this?
> > This same thing happens when this app is updated to SP6.
> >
> > I made sure there are no old controls in the app.
> > I have several apps that do this and many others that do not but I cannot
> > yet see the difference.
>
> "My Theory" as to why this is happening more and more as new OSs/SPs come
> out...... hard-drive write caching (iow, it's a timing problem)  VB is
> supposed to replace any references to OCAs with references to OCX's when you
> close your project. Something (?) is preventing this from happening. I've
> never had both OCX and OCA show but I do get OCA errors. Mostly from the
> CommonDialog OCX.
>
> One thing to try is.... fire up Windows Explorer, search for *.oca and
> delete every single one of them. Since VB will re-create them on demand (and
> we're not on 386's any more), they're just extra baggage. Problem is,
> they're also registered... which means, you'll be better off if you run
> RegClean after deleting them.
>
> I'm planning on adding an OCA scanner to my ComGuard add-in that will scan
> projects for OCA references before attempting to load them. Might even add
> functionality that removes the OCA from the registry and deletes it when the
> project closes. (sounds good to me...)
>
> --
> Ken Halter - MS-MVP-VB - http://www.vbsight.com
> DLL Hell problems? Try ComGuard - http://www.vbsight.com/ComGuard.htm
> Please keep all discussions in the groups..
>
>
>
Author
13 Oct 2005 5:16 AM
Someone
> Reference=*\G{118DAE1B-1D19-4EC1-8C91-ACFA017EC96A}#1.3#0#..\..\WINDOWS\system32\comctl32.oca#Microsoft
> Windows Common Controls 5.0 (SP2)
> Object={6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0; comctl32.ocx

FYI, Microsoft Windows Common Controls 5.0(comctl32.ocx) came with VB5, and
version 6.0(mscomctl.ocx)  came with VB6. Version 6.0 of the common controls
have few more properties.



Show quoteHide quote
"Lorin" <Lo***@discussions.microsoft.com> wrote in message
news:35C72369-458F-442F-A7A0-26BE59BFC755@microsoft.com...
>I have an App that works in the IDE.
> I compile with no errors.
> I start to exit the IDE and IDE asks to save.  I do.
> I restart and get a bunch of errors.
> The tab strip is now a picture box and some others change to pictureboxes
> too.
> I exit without saving this mess.
> I open App.VB in Notepad and find two entries
> Reference=*\G{118DAE1B-1D19-4EC1-8C91-ACFA017EC96A}#1.3#0#..\..\WINDOWS\system32\comctl32.oca#Microsoft
> Windows Common Controls 5.0 (SP2)
> Object={6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0; comctl32.ocx
> I delete the first one and restart with no errors.
> Found out how to do this by trial and lots of errors.
> Who is putting the duplicate entry into the App.VB file?
> Why is it doing this?
> How do I stop this?
> This same thing happens when this app is updated to SP6.
> I made sure there are no old controls in the app.
> I have several apps that do this and many others that do not but I cannot
> yet see the difference.
>
>