UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome to UtterAccess! Please ( Login   or   Register )

Custom Search
 
   Reply to this topicStart new topic
> Error 3024, Access 2016    
 
   
noobdba
post Aug 23 2019, 04:51 PM
Post#1



Posts: 26
Joined: 21-June 19



So a bit of prologue:
I created an Access database for a small company. I split the database, leaving the be/back-end to be put on their server and the front-end on the users' computer. I told them to use the front-end I placed on their Desktop and not the back-end on their server. Seemed to go okay for a few weeks until I come in and see they're getting Error 3024. That the file can't be found. I search for the file on the user's computer and the server...can't find it. I believe it was deleted.

Disclaimer: I don't maintain their server.

I try to debug it and here's the code.

CODE
Private Sub cmd_login_Click()
Dim db As DAO.Database
  Dim rst As DAO.Recordset
  Dim strSQL As String

  If Trim(Me.txt_username.Value & vbNullString) = vbNullString Then
    MsgBox prompt:="Username should not be left blank.", buttons:=vbInformation, Title:="Username Required"
    Me.txt_username.SetFocus
    Exit Sub
  End If

  If Trim(Me.txt_password.Value & vbNullString) = vbNullString Then
    MsgBox prompt:="Password should not be left blank.", buttons:=vbInformation, Title:="Password Required"
    Me.txt_password.SetFocus
    Exit Sub
  End If

  'query to check if login details are correct
  strSQL = "SELECT FirstName FROM tbl_login WHERE Username = """ & Me.txt_username.Value & """ AND Password = """ & Me.txt_password.Value & """"

  Set db = CurrentDb
  Set rst = db.OpenRecordset(strSQL)
  If rst.EOF Then
    MsgBox prompt:="Incorrect username/password. Try again.", buttons:=vbCritical, Title:="Login Error"
    Me.txt_username.SetFocus
  Else
    MsgBox prompt:="Hello, " & rst.Fields(0).Value & ".", buttons:=vbOKOnly, Title:="Login Successful"
    DoCmd.Close acForm, "frm_login", acSaveYes
  End If

Set db = Nothing
Set rst = Nothing
DoCmd.OpenForm "Main Menu"
End Sub


It complains about the:
CODE
Set rst = db.OpenRecordset(strSQL)


I'm not sure if this is a symptom, but one of the users was saving the backups on the server instead of their computer.

I'm wondering if this is an issue I can solve myself, or do I need to the server admin?
Go to the top of the page
 
June7
post Aug 23 2019, 05:34 PM
Post#2



Posts: 1,010
Joined: 25-January 16



So are table links correct? How are they set up? I use VBA to set links with UNC pathing in master frontend then distribute that to users. Backend file must certainly exist for any linking to work. So have they lost all their data?

Why would users be saving backups at all?
This post has been edited by June7: Aug 23 2019, 05:35 PM

--------------------
Attachments Manager is below the edit post window. To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
DEBUG! DEBUG! DEBUG! http://www.cpearson.com/Excel/DebuggingVBA.aspx
Go to the top of the page
 
noobdba
post Aug 23 2019, 05:40 PM
Post#3



Posts: 26
Joined: 21-June 19



Hello June7, thanks for replying!

They should be correct. I used the the Database Splitter tool. I recommended they make backups in case the file gets corrupted. I can't even access the front-end file, because it can't find a file that's been deleted.
This post has been edited by noobdba: Aug 23 2019, 05:41 PM
Go to the top of the page
 
noobdba
post Aug 23 2019, 05:54 PM
Post#4



Posts: 26
Joined: 21-June 19



I can't even find the back-end file. Other than deleted the file, perhaps they overwrote it.
This post has been edited by noobdba: Aug 23 2019, 05:54 PM
Go to the top of the page
 
June7
post Aug 23 2019, 06:05 PM
Post#5



Posts: 1,010
Joined: 25-January 16



I have never used the splitter tool. I suspect it uses drive letter mapping in table links. If user does not have appropriate drive letter mapped, won't be able to find backend.

If they overwrote it, should still be a file in that folder location.

What do you mean by "can't access the front-end"?

Backend should have backups. I rely on the network backup process.

If user frontend copy gets corrupted, they should just replace it with a new copy of master. Users don't need to do backups. If user wants to save a backup to a folder on server, that is fine as long as they are not really overwriting the master. I have development master frontend file in a folder that only I have permissions for. I put a copy of the master in another folder that users can copy from. Every time I modify master I replace the copy and users are notified they need to install new copy on their machine.
This post has been edited by June7: Aug 23 2019, 06:06 PM

--------------------
Attachments Manager is below the edit post window. To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
DEBUG! DEBUG! DEBUG! http://www.cpearson.com/Excel/DebuggingVBA.aspx
Go to the top of the page
 
GroverParkGeorge
post Aug 23 2019, 06:05 PM
Post#6


UA Admin
Posts: 36,176
Joined: 20-June 02
From: Newcastle, WA


That sounds pretty serious. The back end file with all of your data in it has disappeared? That means "someone" went out onto their network and deleted it or moved it, and that's kind of scary.

Have you told IT to restore the most recent backup?

--------------------
My Real Name Is George. Grover Park Consulting is where I did business for 20 years.
How to Ask a Good Question
Beginning SQL Server
Go to the top of the page
 
noobdba
post Aug 23 2019, 06:48 PM
Post#7



Posts: 26
Joined: 21-June 19



I don't know if they lost data. I can't access the front-end, the back-end, or any backups because the file the error comes up with is gone. I didn't get a chance to call IT since the office closed.
This post has been edited by noobdba: Aug 23 2019, 06:48 PM
Go to the top of the page
 
noobdba
post Aug 23 2019, 06:55 PM
Post#8



Posts: 26
Joined: 21-June 19



June7, could you clarify about "Backend should have backups. I rely on the network backup process." ?
Go to the top of the page
 
June7
post Aug 23 2019, 09:30 PM
Post#9



Posts: 1,010
Joined: 25-January 16



What is not clear? Data should be backed up, always. Whether you copy file each day to a USB or external hard drive (in the old days it was tape, floppy, cd) or let your network backup procedures 'watch your back', a copy should be somewhere for 'roll back' in case of disaster.

--------------------
Attachments Manager is below the edit post window. To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
DEBUG! DEBUG! DEBUG! http://www.cpearson.com/Excel/DebuggingVBA.aspx
Go to the top of the page
 
noobdba
post Aug 23 2019, 10:12 PM
Post#10



Posts: 26
Joined: 21-June 19



Ah. They've been making backups of the front-end.
Go to the top of the page
 
GroverParkGeorge
post Aug 24 2019, 10:35 AM
Post#11


UA Admin
Posts: 36,176
Joined: 20-June 02
From: Newcastle, WA


You should have your master copy of the FE so you can easily replace that for the users.

The problem is the missing back end with their DATA, which I assume has been entered by users over the weeks in which they did use it.

Who makes the backups for files on their network?

--------------------
My Real Name Is George. Grover Park Consulting is where I did business for 20 years.
How to Ask a Good Question
Beginning SQL Server
Go to the top of the page
 
GroverParkGeorge
post Aug 24 2019, 10:37 AM
Post#12


UA Admin
Posts: 36,176
Joined: 20-June 02
From: Newcastle, WA


And there is probably no reason for users to be making backups of ANYTHING.

After all, you design and deploy it and they should not need to be changing anything you've provided for them.

What was the logic behind having users making backups?

--------------------
My Real Name Is George. Grover Park Consulting is where I did business for 20 years.
How to Ask a Good Question
Beginning SQL Server
Go to the top of the page
 
noobdba
post Aug 24 2019, 03:03 PM
Post#13



Posts: 26
Joined: 21-June 19



It appears I made too many mistakes, from more detailed directions on how to use the database, to making a master front-end copy, and about doing backups. It was a contract so I'm no longer on-site.

Well, I really messed it up.
Go to the top of the page
 


Custom Search


RSSSearch   Top   Lo-Fi    9th December 2019 - 10:07 AM