Modules & VBA :: Edit Recent Files Of Access Database
Mar 18, 2014
Is it possible to edit the recent files of a access database?
We have a main database (version control database) from where you can open a database which is located on a network drive.
By selecting the datbase you need from a dropdown menu, access will check which version you have locally. If there is an updated version available on the network it will download this updated version, overwriting the old one. The 'main' database is then closed and the local version of the database you needed is opened.
The problem is that this local database is mentioned in the recent files history so people are able to bypass using the main database.
In Excel you can clear the recent files with application. Recent Files setting the maximum to 0 and back to original again. In Access you do not have this option.
Where I would be able to find this option. Ideally I'd like to only take out a specific databasename from the recent files, rather then resetting the full list.
View Replies
ADVERTISEMENT
Aug 7, 2015
I have files that have extension of TSV which are text files but viewable in exel. I figured out a way for the user to click on a button in Access which does the following
1. Run Macro in Excel: The macro prompts the user to select the TSV file. After selection, macro opens the employee.tsv file in the excel (with excel being invisible) and saves it as employee.xls
Code:
Sub SaveTSVtoXLS()
Dim myPath As String
Dim myString As Variant
Application.DisplayAlerts = False
With Application.FileDialog(msoFileDialogOpen)
[Code] .....
2. Imports the Excel file (employee.xls) into two tables: tblEmployee and tblDepartment using the following codes.
Code:
DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel12Xml, "qryDepartment", selectFile, True - 1, "A1:C2"
DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel12Xml, "qryEmployee", selectFile, True - 1, "A1:AE2"
Everything is working flawless except that the user has to select the file three times:
1 time for the tsv
2 times for the xls file
Is there a way that the user can select the file only once (tsv file) or at least only twice one of the tsv file and the other for the xls file?
View 8 Replies
View Related
Nov 11, 2013
I have to write a code for my database,i have folder with files "pending Review" and a table with column "tblExcelLocation". when i run my database all the files from pending review folder goes to "tblExcelLocation" on a click of button.But,if the files already exists it should not insert those files and insert the rest.For this i tried to write a code but i think i m unable to do that .
Code:
Loop through files in folder
folderspec = "O:QA FilesQC ReportingPending Review"
Set fs = CreateObject("Scripting.FileSystemObject")
Set f = fs.GetFolder(folderspec)
Set fc = f.files
[code]...
View 7 Replies
View Related
Apr 13, 2007
I have recently gotten a handle on ASP and found it to be a very powerful tool.
I am wondering if there is a way to design a page where I can list my database tables, and by using a command, I can use asp to do the following.
1. Add or delete table
2. Add, delete, or update fields within the tables
for instance: rename a field 'PersonName' to 'MyName' without change the original values in the field 'PersonName'
I have searched all over the net and could not find information on this subject.
Thanks in advance.
View 3 Replies
View Related
Jun 10, 2015
i want to browse the files from a form and then store hem to the database.i have the following code, i can show the file path to the text box but i don't know how to store the file or how to upload the file to the database.
Dim f As Object
Dim strFile As String
Dim strFolder As String
Dim varItem As Variant
[code]....
View 5 Replies
View Related
Mar 21, 2005
hello, im actually trying do design a database with attached
word files, ie the persons information and his attached cvs
i never done that before and im confused, should i attach all the cvs(words documents) to the database ie can i create a field which is a word document or i should put all the cvs in a folder outside the DB and put a link to them in the table taking into consideration that it s gonna be a big database, and if so can the user attach a file to the database using a button ie in the forms
thanks in advance
View 11 Replies
View Related
Aug 23, 2011
I have an Access 2010 database that I have split. In the database I have a couple tables, forms and two reports. I have entered some data into one of the tables, but when I go to edit the data in the form the next time, there is no data (though I have verified that there is data in the table). Also, there are two reports that can pull the data without any problem.
Why the data wouldn't show up in the form.
View 3 Replies
View Related
Jul 1, 2013
how i can import database files from ms access to visual studio?
View 3 Replies
View Related
Jul 1, 2013
how i can import database files from ms access to visual studio?
View 6 Replies
View Related
Oct 18, 2006
Is it possible to attach a WP, Excel, or Adobe file to a form, possibly by using a control key? How?
View 6 Replies
View Related
Sep 9, 2014
I have parameter form that ask for state and begining date. on click it runs a query and creates a report by state that has multiple pages.. I want to create a separate pdf file for is page (which would be by delegate_name).
This is the coding I have so far and am gettting the error '424' object required. This is the coding I currently have. I haven't worked with access in over 9 yrs so am a little rusty with it.
StateAbb = Me.State
PeriodStartDate = Format(Me.Period_start_date, "MM-DD-YYYY")
Dim strSQL As String
Dim db As Database
Dim rs As Recordset
Dim strRptName As String
[Code] ....
View 14 Replies
View Related
Apr 29, 2015
i want that if any powerpoint application is open after closing my access app all of these powerpoint files will be closed. i found this code for excel file and i changed it for powerpoint application. but i have an error message in this pink line?
error 438: object doesn't support this property or method
Code:
Public Function test()
Dim oApp As Object
Dim workbook1 As Object
[Code].....
View 2 Replies
View Related
May 4, 2014
I am using Access to save an Excel file in a particular directory. The code was created about 10 years ago and hence saves the file with .xls extension and I would like to save with a .xlsm extension. If I just change the .xls to .xlsm, in the code below, the file is saved but the Compatibility Checker comes up (I would like to stop this) and when the file is reopened I get an error message stating there is a file extension problem and the file won't open.
Code:
strExt = ".xls"
'If .txtFriendlyName <> "" Then
' strDestFileName = .txtFriendlyName
'Else
' strDestFileName = Left(objFile.Name, Len(objFile.Name) - 4) & MakeFilePosfix(Now())
[Code] ....
View 7 Replies
View Related
Nov 6, 2014
I have a text file that details every single incident that happened in the system. This means that it is extremely messy and non-comprehensible to a normal person due to the use of codewords and all.
Is it possible to scan through the document and insert the data into access, such that the different keywords are put as seperate events?
Ps, the number of characters between each event and data may not always be the same, so seperating them by that is not the way to do it. However, when I open the file in notepad++, I can confirm that each event is 6 lines.
E.g. Line 1 = Event timestamp, Line 2 = Event Name, Line 3 = Acknowledged or not, Line 4 = Acknowledged by who, Line 5 = Event Details, Line 6 = Application Owner.
Basically, the 6 lines are the 6 columns that I would need in my table. So, is it possible to separate out and read every 6 lines of data in the text file?
View 14 Replies
View Related
Mar 17, 2014
I want a string of code that allows me to import a series of delimited text files into access using VBA. I have the first bit of code down:
Code:
DoCmd.TransferText acImportDelim, deltxtimptbl, "Delivery(local)", "msfs3109data1shareeveryoneprorep ranhistDelivery" & currentdate & ".txt"
The text files hold data for a specific days work. Each day has its own text file. I would like to be able to import the text files within a specific date range, specified by the user. Below is the total code i have for my form button:
rivate Sub Command0_Click()
Dim startdate As String
Dim enddate As String
Dim currentdatex
Dim count As Integer
count = 0
[Code] .....
View 12 Replies
View Related
Aug 1, 2013
[URL]
I have a button on a form, when it is clicked it opens a video file located in a folder on the local computer. Each time the button is clicked a security pop up appears that says "Opening file://C:lahblahyadayadaFile.mp4 Some files can contain viruses or otherwise be harmful to your computer. It is important to be certain that this file is from a trustworthy source. Would you like to open this file?" options are open or cancel. How can these messages be turned off?
I have already played around in the trust center of Access 2010 and changed the "trusted documents", "trusted locations", and "message Bar" tabs with no results. Do I have to play with regedit in windows to get rid of these pop ups? Or can I somehow use VBA code to disable them?They are just a nescience.
View 2 Replies
View Related
Feb 19, 2008
Hello all
I'm sure the answer is on here somewhere but trying to find it and then getting it to work is a bit of a problem, so i resorted to posting.
I have 5 tables
Partnership Details, Invoices, Funding, Communication, Communication Types.
the field Partnership Name in the Partnership Details table has a one to many relationship with the partnership name on tables: Invoices, Funding and Comunication.
What I want to do is create a query that will show the most recent invoice (detirmined by date) and the most recent funding (detirmined by date) for each partnership.
I can do this using max if I only want the feilds Partnership name, invoice date and funding date. however I want to create a report that will show several feilds from partnership details and I want to show the invoice no. and amount as well as the date and also the amount and notes field for funding
Is anyone able to help?
Thanks
Niyx
View 3 Replies
View Related
Jan 25, 2012
When you first open Access 2007 you can see a list of recent databases on the right under the heading 'Open Recent Database.'How do I clear that list?
View 4 Replies
View Related
Sep 29, 2014
There is a manual process I'd like to automate. Instead of the user manually importing an external file into a table, I want a function to grab the most recent file in a particular directory. Is that possible?For example, I have a table called Input, and I want to append the file I just saved on my network, which in this case is G:Files2014TA_140928_011007.txt. The two ways to know which file to use is that the date is part of the filename (TA_ YYMMDD_ 999999. txt), and also the Date Modified attribute.
I am aware that if the user needs to work the files out of date order, he/she cannot use this code.
View 1 Replies
View Related
Jun 20, 2013
I have a database that is used to allocate appointments to our staff. It has 2 tables, one that lists the clients we need to call in that day, and another that stores details of each contact attempt. I'd like to design a query that find all clients who we have not dealt with so we can easily get their details in a list. I know what the criteria for the query would be, but I'm stuck for how to actually execute it. Here are the details.
Table tClients stores the current clients - primary key is named "clientRef"
Table tContactEvents stores each contact attempt and the date/time is stored in a field named "dateTime".
When an entry has been dealt with successfully a yes/no field named "completed" will be set to "Yes".
There may be many attempts to contact a specific client on a given day, unsuccessful attempts will not have the completed flag set.
Once the completed flag is set that client will be ignored so no further entries will appear.
So I need a query that searches tContactEvents for the most recent match to each number in tClients.clientRef and checks if the completed flag is set. If the completed flag is false, or if the number has no match (i.e. no contact attempts made yet) then the clientRef should be displayed. I also need this to be restricted to the current date, as the same client could have rebooked their appointment to a different day.
View 10 Replies
View Related
Feb 8, 2006
I would like to edit a MS Database structure from a Web Browser using ASP. What I mean is I would like to be able to add more columns to a database table or delete or rename...Not the data that is already in the columns... Is this possible? If so can some one please point me in the right direction. I've searched these forums and have not been able to find the answer.
View 2 Replies
View Related
Sep 15, 2011
I am used to old Access 97 where I could edit a report while others are in it. I created an Access 2007 db and it does not let me edit unless I have exclusive rights to the file. Is there a way to turn that functionality on?(editing reports/queries/ while others are in the database. ?
View 6 Replies
View Related
Jun 4, 2013
I have an access 2007 database that is split front end and back end. There are about 15 users and the backend is stored on the network. Currently I am e-mailing out the FE when chagnes are made so they have the latest copy.
With everything I have read I think a bat file would work the best at allowing me to make changes on demand without having to continually email out new versions of the FE. Sometimes the changes are behind the scenes unnoticable to the user while others are obvious.
Questions: Exactly HOW does a bat file work? When the user clicks on the access file stored on their laptop? Where is the bat file stored? I am unfamiliar with where to write the bat file code as well - notepad perhaps?
I am not sure how to create a bat file and what the code should be?
For version tracking I need to put a version table in the BE and in the front end correct?
have made a few significant changes but I'm holding out e-mailing it if I can get this version copying figured out and in place first.
View 4 Replies
View Related
Jul 9, 2007
Hello,
When I attempt to open any of my Access databases I am presented only with the form that has been selected as the 'startup' option. Furthermore, it seems to be impossible to switch to 'design' view and my only options on the toolbar are File, Edit, Insert, Records, Windows, Help. As far as I can tell, none of these enable me to select the options required to give me my entire database back.
I am something of an Access novice, so if the above problem seems familiar to anyone i'd be grateful for the solution! The help option within MS Access hasn't been particularly useful.
Many thanks,
David
View 3 Replies
View Related
Jul 26, 2007
I wrote the following statements to update a SQL server database:
Dim MyDb As Database
Dim MyRs As Recordset
Set MyDb = DBEngine.Workspaces(0).OpenDatabase("AMD", dbDriverPrompt, False, "ODBC;DATABASE=AMD;DSN=Remote")
Set MyRs = MyDb.OpenRecordset("SELECT AllAttendanceEvents.* FROM AllAttendanceEvents ORDER BY AllAttendanceEvents.EntryTime DESC")
MyRs.MoveFirst
While Not MyRs.EOF
MyVal = MyRs!EntryTime
Debug.Print MyVal
MyRs.Edit
MyRs!Ix = 50099
MyRs.Update
MyRs.MoveNext
Wend
When it execute the red line statement, it generates the error:Cannot update. Database or object is read-only.
This error is generated isnpite that I already checked the boxes: SELECT, INSERT, UPDATE, DELETE in the Permissions page of the tables?
Please advise.
View 3 Replies
View Related
Jan 21, 2014
I'm trying to secure my database so users can't edit tables, forms, reports, queries, etc.I'm splitting the database, making an ACCDE for users:
1. I inserted code to disable the bypass key.
2. I inserted code to hide the Quick Access Toolbar (QAT) in the On_Load sub of the form that opens with the DB.
3. Deselect Navigation Pane, Allow Full Menus and Allow Default Shortcut Menus are deselected
4. Then, I use the immediate window to show the QAT, I then create an ACCDE.
How do I link this ACCDE with the original ACCDB? Am I supposed to delete tables from the front end and link the forms/reports to the back end DB?
View 7 Replies
View Related