Results 1 to 5 of 5

Thread: tearing at "circular dependencies between modules" in ActiveX project

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Aug 2016
    Posts
    597

    tearing at "circular dependencies between modules" in ActiveX project

    I changed a new PC, but my old ActiveX project can't compile any more with error "circular dependencies between modules". I have changed the VBP Reference to right path (C:\windows\system32 to c:\windows\syswow64), but still got such error.

    This ActiveX combines few other internal controls. I noticed those controls turned into picturebox already. I have to add those internal controls one by one again? any trick is available?
    Last edited by DaveDavis; Jun 11th, 2020 at 10:51 PM. Reason: add more info

  2. #2
    Hyperactive Member
    Join Date
    Jan 2018
    Posts
    264

    Re: tearing at "circular dependencies between modules" in ActiveX project

    Quote Originally Posted by DaveDavis View Post
    I changed a new PC, but my old ActiveX project can't compile any more with error "circular dependencies between modules". I have changed the VBP Reference to right path (C:\windows\system32 to c:\windows\syswow64), but still got such error.

    This ActiveX combines few other internal controls. I noticed those controls turned into picturebox already. I have to add those internal controls one by one again? any trick is available?
    I wouldn't edit that path. Windows resolves system32 to syswow64 automatically when you run a 32-bit program. But then 32-bit OS installs are so rare nowadays that it probably doesn't matter.

    As for the rest, it depends on what the "internal controls" are that are failing. Check the .log files that VB generates when it can't load them.

    I'd only worry about the circular dependency error after you've fixed the controls that aren't loading. I've seen that error come and go as a side effect of other things.

  3. #3
    Fanatic Member Episcopal's Avatar
    Join Date
    Mar 2019
    Location
    Brazil
    Posts
    547

    Re: tearing at "circular dependencies between modules" in ActiveX project

    As for the rest, it depends on what the "internal controls" are that are failing. Check the .log files that VB generates when it can't load them.
    This happened to me, and they were with class and not control ....


    I've seen that error come and go as a side effect of other things.
    exactly ...

  4. #4
    The Idiot
    Join Date
    Dec 2014
    Posts
    2,721

    Re: tearing at "circular dependencies between modules" in ActiveX project

    isn't that an error u get if your class/activex depend on each other, like:
    A need B, B need C, C need A
    that will make it impossible to add, if the initialization is automatic.
    but it could be:
    A need B, B need C
    here you can:
    add C first, than B and lastly A
    or change initialization to be manual.

  5. #5
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Location
    Sofia, Bulgaria
    Posts
    5,120

    Re: tearing at "circular dependencies between modules" in ActiveX project

    "Circular dependencies" is a real error. For instance if you have a module with a Public Type and a class with a Public Enum you cannot use the enum in the module and the UDT in the class -- the compiler wouldn't know which to compile first.

    What you do is add a *third* module and move *both* the type and the enum to it so that the original module and class now depend on this newly added module, not on each other in a circular fashion.

    For an ActiveX project (DLL or OCX) best would be to add some kind of catch-all Enums class and move all public enums to it (from public user-controls and public classes that is).

    cheers,
    </wqw>

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width