Results 1 to 10 of 10

Thread: [RESOLVED] How to delete a VB6 Reference?

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2006
    Posts
    403

    Resolved [RESOLVED] How to delete a VB6 Reference?

    In a program I have recently been writing, there is now a reference to DIRECT ANIMATION LIBRARY (DAL).The program was written under 98SE/2000.

    I do not know (remember) how this reference came to be added, and can not find out what it is, what it does or why it is there. But the program code was running satisfactorily with it called up.

    When we came to running the code at the design stage under Vista64, errors were generated related to DAL.

    So I thought to delete the DAL reference from the project on the 98/2000 development machines to see if it was necessary.

    However on opening the project, going to references and attempting to un-check DAL I get the error message "Can't remove control or reference in use".

    So questions are please :

    1. What is DAL and what does it do/interact with?
    2. How can I force its removal as a reference to see if it is serving any useful purpose?

    Suggestions appreciated.


    camoore

  2. #2
    PowerPoster
    Join Date
    Dec 2004
    Posts
    25,618

    Re: How to delete a VB6 Reference?

    you can open the project file (.vbp) in notepad and remove the reference, i would suggest keeping a backup of the original file first, in case you get some problem when you open the file in vb6
    i do my best to test code works before i post it, but sometimes am unable to do so for some reason, and usually say so if this is the case.
    Note code snippets posted are just that and do not include error handling that is required in real world applications, but avoid On Error Resume Next

    dim all variables as required as often i have done so elsewhere in my code but only posted the relevant part

    come back and mark your original post as resolved if your problem is fixed
    pete

  3. #3
    Frenzied Member some1uk03's Avatar
    Join Date
    Jun 2006
    Location
    London, UK
    Posts
    1,675

    Re: How to delete a VB6 Reference?

    Quote Originally Posted by camoore View Post
    However on opening the project, going to references and attempting to un-check DAL I get the error message "Can't remove control or reference in use".

    camoore

    Find out where in your code this is Referenced to... rather than just trying to remove it!
    _____________________________________________________________________

    ----If this post has helped you. Please take time to Rate it.
    ----If you've solved your problem, then please mark it as RESOLVED from Thread Tools.



  4. #4

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2006
    Posts
    403

    Re: How to delete a VB6 Reference?

    Thank you Westconn1 for the suggestion. I saved a copy of the project.vpb file, then deleted the line referring to danim.dll and all appears well without it.

    Some1uk03 : How please can I determine which part of my code, if any, was using the DAL reference? Having deleted it (but saved the original .vpb file just in case) I assume I would get an error in running the code if it came to a point when it needed it but could not find it?

    I can't find out what the DAL reference has to do with, nor hence guess what part of the program it might possibly refer to. But it was therefore strange that VB6 would not allow me to remove it from the project references list saying that it was in use.

    camoore
    Last edited by camoore; Jan 3rd, 2010 at 07:53 AM. Reason: typo

  5. #5
    Freelancer akhileshbc's Avatar
    Join Date
    Jun 2008
    Location
    Trivandrum, Kerala, India
    Posts
    7,652

    Re: How to delete a VB6 Reference?

    Search your code for the word: DirectAnimation
    If you find anything, then you have to change the coding, otherwise, there is a chance of popping errors...
    (not sure about this...)
    Last edited by akhileshbc; Jan 3rd, 2010 at 11:02 AM.

    If my post was helpful to you, then express your gratitude using Rate this Post.
    And if your problem is SOLVED, then please Mark the Thread as RESOLVED (see it in action - video)
    My system: AMD FX 6100, Gigabyte Motherboard, 8 GB Crossair Vengance, Cooler Master 450W Thunder PSU, 1.4 TB HDD, 18.5" TFT(Wide), Antec V1 Cabinet

    Social Group: VBForums - Developers from India


    Skills: PHP, MySQL, jQuery, VB.Net, Photoshop, CodeIgniter, Bootstrap,...

  6. #6
    Frenzied Member
    Join Date
    Mar 2009
    Posts
    1,182

    Re: How to delete a VB6 Reference?

    Wasn't that part of the DX7 SDK???
    Option Explicit should not be an Option!

  7. #7

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2006
    Posts
    403

    Re: How to delete a VB6 Reference?

    Akhileshbc : Thank you. I had and have carried out a code text search for DirectAnimation and there was / remains a nil return.

    My conclusion is that I must have enabled DAL as a reference in error or as a typo and that it has nothing to do with my program.

    So therefore it is interesting that VB6 seems to think it is being used and will not let me delete it. Hence my needing to use the method kindly suggested by westconn1. That danim.dll / oca seemed stuck to my program like glue.

    I do not have or use Vista 64, but my co-writing forum member found that there is an apparent incompatibility issue between Vista and danim.dll/oca (ie. the DAL reference).

    One reads quite often of members encountering problems when trying to run VB6 at the design stage under the Vista OS. Is there, I wonder, somewhere in the Forum where all such problems encountered with Vista can be listed, and hence easily looked up through a search process?

    camoore
    Last edited by camoore; Jan 3rd, 2010 at 11:43 AM.

  8. #8
    VB-aholic & Lovin' It LaVolpe's Avatar
    Join Date
    Oct 2007
    Location
    Beside Waldo
    Posts
    19,541

    Re: How to delete a VB6 Reference?

    When you or someone adds a reference to VB, VB won't remove it just because it isn't in use. It is common that someone wants to play with a DLL thinking they can use it in their project, later decide to abort the idea, but forget to the remove the reference. That may be the case in your situation.
    Insomnia is just a byproduct of, "It can't be done"

    Classics Enthusiast? Here's my 1969 Mustang Mach I Fastback. Her sister '67 Coupe has been adopted

    Newbie? Novice? Bored? Spend a few minutes browsing the FAQ section of the forum.
    Read the HitchHiker's Guide to Getting Help on the Forums.
    Here is the list of TAGs you can use to format your posts
    Here are VB6 Help Files online


    {Alpha Image Control} {Memory Leak FAQ} {Unicode Open/Save Dialog} {Resource Image Viewer/Extractor}
    {VB and DPI Tutorial} {Manifest Creator} {UserControl Button Template} {stdPicture Render Usage}

  9. #9

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2006
    Posts
    403

    Re: How to delete a VB6 Reference?

    LaVolpe : Thank you. The problem in this case seems to have been that VB "thought" DAL was in use when in fact it was not. Hence VB would not let me un-check DAL in the project reference list. I did not expect VB to delete DAL "just because it isn't in use" but had wanted to delete DAL in response to a specific action on my part. It would not allow me to do so.

    The secondary problem seems to be the incompatibility of Vista 64 with DAL. I can not investigate this right now because I do not have a Vista 64 bit machine, but I flag it up in case another member might encounter a similar problem.

    camoore

  10. #10

    Thread Starter
    Hyperactive Member
    Join Date
    Oct 2006
    Posts
    403

    Re: How to delete a VB6 Reference?

    With many thanks to those who have replied to this thread, I will mark it as resolved.

    However I feel that any further information about incompatibility between DAL and Vista would be of potential interest to Forum members.

    Regards all,

    camoore

    Wales, UK

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