473,326 Members | 2,010 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

How to delete the missing References for VBA

Dear reader,

For removing a reference in the VBA reference form I receive from Doug
Steele the following code:

...........

References.Remove refCurr

..........

By running this code the following error occur:

Error no. 17

Error description: Can't perform requested operation

The question is how can I unable the tick box (remove tick form tick box) in
the VBA references form for the missing (broken) references.

Thanks for any help.

Kind regards,

Simon van Beek
Nov 13 '05 #1
2 22182
I suggest you perform this task on a machine that has the "Missing"
references installed, after which, you can uninstall those references or
move the project to the machine that is missing the references.

It might prove beneficial if you post the names of the missing references...

Good luck,
Curt
"S. van Beek" <S.******@HCCnet.nl> wrote in message
news:43*********************@reader1.nntp.hccnet.n l...
Dear reader,

For removing a reference in the VBA reference form I receive from Doug
Steele the following code:

..........

References.Remove refCurr

..........

By running this code the following error occur:

Error no. 17

Error description: Can't perform requested operation

The question is how can I unable the tick box (remove tick form tick box)
in
the VBA references form for the missing (broken) references.

Thanks for any help.

Kind regards,

Simon van Beek

Nov 13 '05 #2

Seeing the whole of the code would be more useful as in the snippet you show
it would appear that refCurr is a variable, we really need to know the code
around that line.

If you are doing something like this for example

Dim refCurr As Reference

For Each refCurr In References
If refCurr.IsBroken Then
References.Remove refCurr
End If
Next

Then this will fail (if you do have Missing references)

This on the other hand should succeed

Dim refCurr As Reference
Dim intX As Integer

For intX = References.Count To 1 Step -1
Set refCurr = References(intCount)
If refCurr.IsBroken Then
References.Remove refCurr
End If
Next

.... unless the Missing reference is an inbuilt one, but the code could be
changed to

Dim refCurr As Reference
Dim intCount As Integer

For intCount = References.Count To 1 Step -1
Set refCurr = References(intCount)
If Not refCurr.BuiltIn Then
If refCurr.IsBroken Then
References.Remove refCurr
End If
End If
Next

and then you really must disambiguate when checking references in case one
of them is broken so the code should really be.

Dim refCurr As Access.Reference
Dim intCount As Integer

For intCount = Access.References.Count To 1 Step -1
Set refCurr = Access.References(intCount)
If Not refCurr.BuiltIn Then
If refCurr.IsBroken Then
Access.References.Remove refCurr
End If
End If
Next

Now do you see why the surrounding code is important ?

--
Terry Kreft
MVP Microsoft Access
"S. van Beek" <S.******@HCCnet.nl> wrote in message
news:43*********************@reader1.nntp.hccnet.n l...
Dear reader,

For removing a reference in the VBA reference form I receive from Doug
Steele the following code:

..........

References.Remove refCurr

..........

By running this code the following error occur:

Error no. 17

Error description: Can't perform requested operation

The question is how can I unable the tick box (remove tick form tick box) in the VBA references form for the missing (broken) references.

Thanks for any help.

Kind regards,

Simon van Beek

Nov 13 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Andrew DeFaria | last post by:
I created the following .sql file to demonstrate a problem I'm having. According to the manual: If |ON DELETE CASCADE| is specified, and a row in the parent table is deleted, then InnoDB...
2
by: Eric | last post by:
Hi, I'm used to C/C++ where if you "new" something you really need to "delete" it later. Is that also true in javascript? if i do "mydate = new date();" in a function and dont "delete mydate" when...
16
by: cppaddict | last post by:
Hi, I am deleting some objects created by new in my class destructor, and it is causing my application to error at runtime. The code below compiles ok, and also runs fine if I remove the body...
9
by: Robert Schneider | last post by:
Hi to all, I don't understand that: I try to delete a record via JDBC. But I always get the error SQL7008 with the error code 3. It seems that this has something to do with journaling, since the...
14
by: Karl O. Pinc | last post by:
Hi, Thought perhaps some other eyes than mine can tell if I'm doing something wrong here or if there's a bug somewhere. I've never passed a ROWTYPE varaible to a function but I don't see where...
5
by: Jeff User | last post by:
Hello ..NET 1.1, VS 2003, C# & asp.net I have tried to follow msdn instructions and samples but I can not get an event to fire for this button on the datagrid. There has to be something obvious...
2
by: jodyblau | last post by:
I have noticed that when I move my database onto a different computer, I often get a message about some reference missing. So I go into the reference list, and find the one that says "Missing,"...
1
by: muralik | last post by:
Hi all, I want to refer to a foreign key in a table and set null on delete and on update cascade it...my commands were as follows.. create table Institute( name ...
3
by: sun919 via DotNetMonster.com | last post by:
hi , i have a question to ask regarding deleting the worksheet basically i have written code which find the select worksheet which work fine but it didn't delete the worksheet from the workbook...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.