PC Review


Reply
Thread Tools Rate Thread

Access 97 vs Access 2002

 
 
=?Utf-8?B?Q29uZnVzZWQgZGVzaWduZXI=?=
Guest
Posts: n/a
 
      16th Jun 2004
Hi everybody!
Please, can anybody tell me how to solve this problem? I've written a procedure for opening data from a file, make some changes in this file and then save it to the disk for later import into a table.
This is the code that enables this:
Set oFileSystem = CreateObject("Scripting.FileSystemObject")
Set OpenText = oFileSystem.OpenTextFile("Dane.txt", ForReading, False)
Do While Not OpenText.AtEndOfLine
Dim liniatemmp As String
liniatemmp = OpenText.ReadLine
.....
Loop

Everything works OK in Access 2002, but when compilled in Access 97, I get an error in the line replacing "," with ";" .....
How to do that in Access 97?
Any help will be appreciated.
liniatemmp = Replace(liniatemmp, Chr(44), Chr(59))
 
Reply With Quote
 
 
 
 
=?Utf-8?B?QW5vbXltb3Vz?=
Guest
Posts: n/a
 
      16th Jun 2004
There is no Replace function in Access 97. Access 2000 was the first version with a built-in Replace(). You need to write the Replace function by your own or you use a userdefined function from the internet like this one, it is stable and extremely fast, faster than VB6 (?) and Access 2000:

http://vb-tec.de/replace.htm



"Confused designer" wrote:

> Hi everybody!
> Please, can anybody tell me how to solve this problem? I've written a procedure for opening data from a file, make some changes in this file and then save it to the disk for later import into a table.
> This is the code that enables this:
> Set oFileSystem = CreateObject("Scripting.FileSystemObject")
> Set OpenText = oFileSystem.OpenTextFile("Dane.txt", ForReading, False)
> Do While Not OpenText.AtEndOfLine
> Dim liniatemmp As String
> liniatemmp = OpenText.ReadLine
> ....
> Loop
>
> Everything works OK in Access 2002, but when compilled in Access 97, I get an error in the line replacing "," with ";" .....
> How to do that in Access 97?
> Any help will be appreciated.
> liniatemmp = Replace(liniatemmp, Chr(44), Chr(59))

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Access 2002 English vs. Access 2002 Hebrew - problem running code =?Utf-8?B?Zm9q?= Microsoft Access Getting Started 3 16th Jun 2006 04:17 AM
Using Access 2002 Access Object Lib. In Access 2000 meyvn77@yahoo.com Microsoft Access VBA Modules 0 17th Sep 2005 08:53 PM
can't open an access 2002 db in access 2003 but can in 2002? =?Utf-8?B?Q1c=?= Microsoft Access 5 12th Aug 2005 12:37 PM
Office XP 2002 Access 2000 or Access 2002?? =?Utf-8?B?U2hlcnls?= Microsoft Access 4 15th Jan 2005 12:54 AM
Access 2002 query SP2 not running, but runs Access 2002 SP1 =?Utf-8?B?RXJuZXN0IERlaGFhbg==?= Microsoft Access Queries 0 26th Nov 2003 09:51 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:05 PM.