Results 1 to 11 of 11

Thread: Lost VB?

  1. #1
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Warrington, Cheshire, England
    Posts
    712
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I was amending VB for my database. One of the objects in the Project Explorer window no longer has any VB so I was trying to delete it from the list. Didn't manage that, so moved to the code window. I thought I hit the close button, but must have hit the minimise button. This exposed many other smalled windows, and without thinking, I hit the close button for one of these windows.
    Now I find that another of my DB objects just displays a blank window when I try and view its code.
    I desperation, I deleted that object from the DB and imported an older version from another DB, but this still has no code visible in the code window.
    Have I deleted all the code for this object or is it just 'hidden'.
    Need help urgently, please!
    Thanks
    Silverback
    Silverback

  2. #2
    Gold Lounger
    Join Date
    Feb 2001
    Location
    Sint Niklaas, Belgium
    Posts
    2,778
    Thanks
    0
    Thanked 0 Times in 0 Posts
    In the Project Explorer window, have you double click on the object name ?
    Francois

  3. #3
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Warrington, Cheshire, England
    Posts
    712
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Yes, Francois. And right clicked and selected View Code. Nothing

    But the wierd thing is if I go to an old version of the DB, I still get a blank code window there for this object. Even if I've deleted the code in one DB version, it can't have deleted it in another version can it?
    Silverback
    Silverback

  4. #4
    Gold Lounger
    Join Date
    Feb 2001
    Location
    Sint Niklaas, Belgium
    Posts
    2,778
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Deleting the code in one DB will not affect another DB. Do you have a third copy of the DB or a Backup ?
    Francois

  5. #5
    Gold Lounger
    Join Date
    Feb 2001
    Location
    Sint Niklaas, Belgium
    Posts
    2,778
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Just thinking. Are you sure you have imported the object from the old DB into the new DB, and not from the new one into the old one ?
    Francois

  6. #6
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Warrington, Cheshire, England
    Posts
    712
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Yes - have even opened the old DB's and still the code won't show. That's the hope I'm hanging on to - it can't possibly have been deleted in DBs that weren't even open when i made my mistake, so somehow (I'm hoping desperately) VB must not be able to display the code for these windows I closed.
    how can it be that when I open an archive version of the DB, the code window for this object is still blank?
    I'm completely baffled - I had hoped to open the code in an old version, copy it and paste it into the current DB version - but all code windows for this object are blank.
    Silverback
    Silverback

  7. #7
    Gold Lounger
    Join Date
    Feb 2001
    Location
    Sint Niklaas, Belgium
    Posts
    2,778
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I have no idea how it come that you don't have code in the archive DB's. It is totally impossible that when you delete code in one DB, it also disappear in another DB.
    The only ways to remove all the code from a object (form or report) is
    1) in the VBE press CTRL+A end then Delete
    2) in design view set the property Has Module to No

    I'm out of idea here.
    Francois

  8. #8
    Silver Lounger GARYPSWANSON's Avatar
    Join Date
    Aug 2001
    Location
    Frederick, Maryland, USA
    Posts
    1,788
    Thanks
    0
    Thanked 2 Times in 2 Posts
    Silverback,

    Are the databases being opened in the same operating system that they were designed in? You might want to check to make sure your VB references are still valid. Are you able to debug in VB without receiving errors? Is the db in question a standalone database on a particular machine or setup as a front end and back end on a network? If on a particular machine, I would try it on a different machine. Just my 2 cents here. HTH.
    Regards,

    Gary
    (It's been a while!)

  9. #9
    Platinum Lounger
    Join Date
    Dec 2001
    Location
    Melbourne, Australia
    Posts
    4,594
    Thanks
    0
    Thanked 27 Times in 27 Posts
    Can you post a compacted zipped version of you database for us to look at.?

  10. #10
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Warrington, Cheshire, England
    Posts
    712
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I am hugely embarrassed to admit that this posting has been a waste of everyone's time. The reason the code page for this form object is empty is because there is no code to display; I moved it after a lounge reply to a previous posting of mine showed a better way of achieving the required testing for the form fields (but had forgetten that I had done so)
    An application of basic logic would have told me that the reason code pages showed up as empty in archive versions of the DB was because they were empty; instead, I panicked and assumed I had somehow corrupted the VB editor.
    I am so sorry to have wasted the time of loungers who tried to help - especially Francois whom I particularly confused.
    Again, my profuse apologies.
    Silverback
    Silverback

  11. #11
    Gold Lounger
    Join Date
    Feb 2001
    Location
    Sint Niklaas, Belgium
    Posts
    2,778
    Thanks
    0
    Thanked 0 Times in 0 Posts
    No problem Silverback. As long as you haven't lose anything.
    Francois

Posting Permissions

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