Duplicate error !

Duplicate error !

Anonymous
Not applicable
177 Views
1 Reply
Message 1 of 2

Duplicate error !

Anonymous
Not applicable
I tried to run a sub for both part and assembly documents using this select
case and I got this mesg
Anyone helps, pls.
Thx

Select Case ThisApplication.ActiveDocumentType
Case Is = kPartDocumentObject
Dim oDoc As Inventor.PartDocument
Case Is = kAssemblyDocumentObject
Dim oDoc As Inventor.AssemblyDocument
End Select


--
IV11 Pro. sp1 - uninstalled
Window XP Pro sp2
Pentium 3.2 Ghz, 3.0 GB of RAM
NVIDIA FX 3400 84.26
SpacePilot V 1.1.2
0 Likes
178 Views
1 Reply
Reply (1)
Message 2 of 2

Anonymous
Not applicable

You can't conditionally dimension a variable as
two different types in VB6.  Just dimension oDoc
As
Inventor.Document generically then
based upon the ActiveDocumentType use the
appropriate properties or methods of that document subtype.

 

Also, "Case Is =
kPartDocumentObject
" is unnecessary.  Instead, simply use "
face="Courier New">Case kPartDocumentObject
".




Brian R.
Iwaskewycz


style="FONT-SIZE: 14pt; FONT-FAMILY: Verdana">CAD Systems
Manager


style="FONT-SIZE: 14pt; FONT-FAMILY: Verdana">
href="http://www.corefurnace.com">Core Furnace Systems

 
0 Likes