Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Importing / Linking / August 2005

Tip: Looking for answers? Try searching our database.

Link text file that does not have .txt as extension

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Brad - 18 Aug 2005 20:23 GMT
Thanks for taking the time to read my question.

My DB was in 97 and it works perfectly.  My company changed to 2000 and now
one part of the DB doesn't work.

I am linking 2 external text files to the program.  They are text documents,
but have different file extensions (I made them up: .lnu and .pmf)  This
helps me separate them when I populate a combo box, as well as a few other
functions.

Now in 2000 I can no longer link the files.  How can I fix this?

The Error I get is 3027: Cannot Update. Database or Object is Read-Only

Here is my code:

Function DeleteLNUViewingCopy(FilePath As String, FileName As String)
Dim TheFileAndPath, TheFileAndPathDest As String
Dim x, y As Integer

On Error GoTo DeleteLNUViewingCopy_Err

If Right(FilePath, 1) = "\" Then
   TheFileAndPath = FilePath & FileName
Else
   TheFileAndPath = FilePath & "\" & FileName
End If

x = Len(FileName)
y = Len(TheFileAndPath)

If x = 0 Then Exit Function

TheFileAndPathDest = Left(TheFileAndPath, y - x) & "LNUViewingCopy" &
Left(Right(TheFileAndPath, x), x - 3) & "txt"

Kill TheFileAndPathDest

DeleteLNUViewingCopy_Exit:
Exit Function

DeleteLNUViewingCopy_Err:

If Err.Number = 53 Then
   Resume DeleteLNUViewingCopy_Exit
Else
   MsgBox Err.Number & ", " & Err.Description
   Resume DeleteLNUViewingCopy_Exit
End If

End Function

Thanks for your help

Brad
'69 Camaro - 18 Aug 2005 20:48 GMT
Hi, Brad.

> Now in 2000 I can no longer link the files.  How can I fix this?

Access 2000 doesn't recognize these files as text files, due to the
non-standard file name extension.  To remedy this, please see the following
Web page:

http://support.microsoft.com/default.aspx?id=304206

Modifying the Windows Registry would be the easiest choice, but don't modify
the Registry unless you are comfortable doing so.

HTH.

Gunny

See http://www.QBuilt.com for all your database needs.
See http://www.Access.QBuilt.com for Microsoft Access tips.

(Please remove ZERO_SPAM from my reply E-mail address, so that a message
will be forwarded to me.)
Beware to those who use munged addresses:  known newsgroup E-mail harvesters
for spammers are Ripley@CASInternet.Net and scott@ripleysoftware.com

- - -
When you see correct answers to your question posted in Microsoft's Online
Community, please sign in to the Community and mark these posts as "Answers,"
so that all may benefit by filtering on "Answered questions" and quickly
finding the right answers to similar questions.  Remember that questions
answered the quickest are often from those who have a history of rewarding
the contributors who have taken the time to answer questions correctly.

> Thanks for taking the time to read my question.
>
[quoted text clipped - 51 lines]
>
> Brad
Brad - 18 Aug 2005 21:10 GMT
Thanks!

I've changed the registry and it works great!

Have a great day,

Brad

> Hi, Brad.
>
[quoted text clipped - 84 lines]
> >
> > Brad
'69 Camaro - 18 Aug 2005 21:39 GMT
You're very welcome!

Gunny

See http://www.QBuilt.com for all your database needs.
See http://www.Access.QBuilt.com for Microsoft Access tips.

(Please remove ZERO_SPAM from my reply E-mail address, so that a message
will be forwarded to me.)
Beware to those who use munged addresses:  known newsgroup E-mail harvesters
for spammers are Ripley@CASInternet.Net and scott@ripleysoftware.com

> Thanks!
>
[quoted text clipped - 102 lines]
>> >
>> > Brad
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.