473,405 Members | 2,176 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,405 software developers and data experts.

Replace function - odd problem

I have an Access 2K application that is distributed to about a dozen
users (all with identical NT environments and identical Access
versions, object libraries and service packs). I am using the VBA
Replace function in a couple of queries to reformat some data. The
application works flawlessly on 8 of the workstations, but on the
other 4 throws a "Unrecognized function Replace" error when the
queries in question are encountered.

I have worked around the problem by implementing the required replace
functionality in code and eliminating the Replace function altogether,
but as a matter of curiosity, can anybody explain why this might be
happening?

Thanks
Dave
Nov 13 '05 #1
3 3753
Likely a References problem.

This can be caused by differences in either the location or file version of
certain files between the machine where the application was developed, and
where it's being run (or the file missing completely from the target
machine). Such differences are common when new software is installed.

On the machine(s) where it's not working, open any code module (or open the
Debug Window, using Ctrl-G, provided you haven't selected the "keep debug
window on top" option). Select Tools | References from the menu bar. Examine
all of the selected references.

If any of the selected references have "MISSING:" in front of them, unselect
them, and back out of the dialog. If you really need the reference(s) you
just unselected (you can tell by doing a Compile All Modules), go back in
and reselect them.

If none have "MISSING:", select an additional reference at random, back out
of the dialog, then go back in and unselect the reference you just added. If
that doesn't solve the problem, try to unselect as many of the selected
references as you can (Access may not let you unselect them all), back out
of the dialog, then go back in and reselect the references you just
unselected. (NOTE: write down what the references are before you delete
them, because they'll be in a different order when you go back in)

For far more than you could ever want to know about this problem, check out
http://members.rogers.com/douglas.j....nceErrors.html

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)

"Dave" <dg*****@erols.com> wrote in message
news:8d**************************@posting.google.c om...
I have an Access 2K application that is distributed to about a dozen
users (all with identical NT environments and identical Access
versions, object libraries and service packs). I am using the VBA
Replace function in a couple of queries to reformat some data. The
application works flawlessly on 8 of the workstations, but on the
other 4 throws a "Unrecognized function Replace" error when the
queries in question are encountered.

I have worked around the problem by implementing the required replace
functionality in code and eliminating the Replace function altogether,
but as a matter of curiosity, can anybody explain why this might be
happening?

Thanks
Dave

Nov 13 '05 #2
Dave, I don't have a solution for you, but thought you might like to know
that I have seen the identical problem. It's only been on a small
percentage of about 80 systems, all of which are running the identical .mde.
It's so sporadic that I haven't been able to clearly identify a fix, but I
think re-running, either the MDAC update or the Office 2000 service pack,
fixes it.
"Dave" <dg*****@erols.com> wrote in message
news:8d**************************@posting.google.c om...
I have an Access 2K application that is distributed to about a dozen
users (all with identical NT environments and identical Access
versions, object libraries and service packs). I am using the VBA
Replace function in a couple of queries to reformat some data. The
application works flawlessly on 8 of the workstations, but on the
other 4 throws a "Unrecognized function Replace" error when the
queries in question are encountered.

I have worked around the problem by implementing the required replace
functionality in code and eliminating the Replace function altogether,
but as a matter of curiosity, can anybody explain why this might be
happening?

Thanks
Dave

Nov 13 '05 #3
On 1 Jul 2004 10:52:24 -0700, Dave wrote:
I have an Access 2K application that is distributed to about a dozen
users (all with identical NT environments and identical Access
versions, object libraries and service packs). I am using the VBA
Replace function in a couple of queries to reformat some data. The
application works flawlessly on 8 of the workstations, but on the
other 4 throws a "Unrecognized function Replace" error when the
queries in question are encountered.

I have worked around the problem by implementing the required replace
functionality in code and eliminating the Replace function altogether,
but as a matter of curiosity, can anybody explain why this might be
happening?

Thanks
Dave


Assuming it's not a common reference problem ....
I've not had to deal with this personally, but if memory serves me
correctly, there were some versions of Access 2000 in which the
Replace function would not be recognized in a query, but which would
work in a code module.
The work around is to write a module using the replace function:

Function Workaround(StringIn)
Workaround = Replace(StringIn,"abc","xyz")
End Function

Then in the query:
Exp:Workaround([FieldName])

Try it and let me know if my memory is O.K., or if I should stop
staying up so late.
--
Fred
Please only reply to this newsgroup.
I do not reply to personal email.
Nov 13 '05 #4

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

Similar topics

5
by: adrian zaharia | last post by:
Hello, Is it possible to use Replace function in a query against an excel file? I am trying this test code and gives me an error: Set cnnExcel = Server.CreateObject("ADODB.Connection")...
6
by: Séverine Donnay | last post by:
Hello, I try to use the replace function with a very long text and I have this error : error '80020009' Exception occurred. Do you have any idee to resolve this problem ? Thanks
4
by: Lauren Wilson | last post by:
Hi folks, We have a need to replace sub strings in certain message text. We use the Office Assistant to display help and often use the imbedded formatting commands. Those of you who have used...
5
by: enno | last post by:
Dear Community, We have a problem with null-Bytes in varchar-Columns, which are not handled correctly in our application. Therefor we try to filter them out using the Transact-SQL REPLACE...
10
by: localpricemaps | last post by:
i have some html that looks like this <address style="color:#">34 main,<br> Boston, MA</address> and i am trying to use the replace function to get rid of the <Br> that i scrape out using...
7
by: denoxis | last post by:
Hi, I have a mystery to solve. It is a mystery because it happens randomly. In the ASP page that is in question, I build a large string (no more than 10K) which is basically an email...
11
by: Lothar Behrens | last post by:
Hi, I have selected strtok to be used in my string replacement function. But I lost the last token, if there is one. This string would be replaced select "name", "vorname", "userid",...
1
by: seanmatthewwalsh | last post by:
Hi I have a website that uses an Access 2003 database. I have controls on my pages that are bound to SqlDataSources that pull data from this database. In a couple of them, I need to use the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.