Forms :: (Upload File) Button Stopped Showing All File Types
Oct 7, 2013
I recently upgraded a DB from 2003 to 2013 and ran into the following problem.
I have a button that opens a file dialog box and allows the user to upload a file to a predetermined location (and store the address as a hyperlink). I borrowed this code from someone else on here and modified it slightly.
In any case, the button still works, but now when it opens it doesn't have an option for "All files" under file types. So I can upload MS Office files, text files, etc., but not PDF files which are by far the most common types my users upload.
Private Sub Command35_Click()
Dim dd As Integer
Dim fileDump As FileDialog
Set fileDump = Application.FileDialog(msoFileDialogOpen)
dd = fileDump.Show
Dim Yourroute As String
Dim yourrouteName
Yourroute = fileDump.SelectedItems(1)
yourrouteName = StrReverse(Yourroute)
yourrouteName = StrReverse(Mid(yourrouteName, 1, InStr(yourrouteName, "") - 1))
FileCopy Yourroute, "us170fp00dataWBO_Tool_RoomDrawings" & yourrouteName
Me.Drawing_Link = yourrouteName & " # us170fp00dataWBO_Tool_RoomDrawings" & yourrouteName
End Sub
View Replies
ADVERTISEMENT
Jan 11, 2015
I would like to create a form that allows me to search for a folder on my desk top, then once located i can transfer that file to a specific location on another drive, Similar to the Browse / upload function you see on many applications.I am using Access 2003. Is this possible??
View 5 Replies
View Related
Oct 4, 2013
I recently upgraded a DB from 2003 to 2013 and ran into the following problem.
I have a button that opens a file dialog box and allows the user to upload a file to a predetermined location (and store the address as a hyperlink). I borrowed this code from someone else on here and modified it slightly.
In any case, the button still works, but now when it opens it doesn't have an option for "All files" under file types. So I can upload MS Office files, text files, etc., but not PDF files which are by far the most common types my users upload.
Here's my code and a screenshot is attached.
Private Sub Command35_Click()
Dim dd As Integer
Dim fileDump As FileDialog
Set fileDump = Application.FileDialog(msoFileDialogOpen)
dd = fileDump.Show
[Code] ....
View 3 Replies
View Related
Nov 20, 2007
hello good day. hope im inthe right place.
can someone point out to me if there is a way to do a file upload using ms access 2003 and not just stor the file path...thanks
View 14 Replies
View Related
Jun 22, 2005
Hello...
This should be an easy one for many of you..
I have the following to code to let the user select a file..
It worked before but suddenly stopped working...I remember adding some reference but I dont remember exactly the name of the reference..
After I did this, I converted the database from 2000 - 2002/2003 ..back and forth...I did not change/remove any references.
I have access 2003 but my database is in 2000 format because my teammates have 2000.
Thanks in advance for the help.
-------------------------------------------
Dim fDialog As Office.FileDialog
Dim varFile As Variant
' Set up the File Dialog.
Set fDialog = Application.FileDialog(msoFileDialogFilePicker)
With fDialog
' Allow user to make multiple selections in dialog box
.AllowMultiSelect = False
' Set the title of the dialog box.
.Title = "Please select a file"
' Clear out the current filters, and add our own.
'.Filters.Clear
' .Filters.Add "All Files", "*.*"
'.Filters.Add "Access Projects", "*.HTM"
'.Filters.Add "Access Projects", "*.HTML"
'.Filters.Add "Access Projects", "*.DOC"
'.Filters.Add "Access Databases", "*.VST"
'.Filters.Add "Access Databases", "*.VSD"
'.Filters.Add "Access Databases", "*.TXT"
'.Filters.Add "Access Databases", "*.MDB"
'.Filters.Add "Access Projects", "*.XLS"
' Show the dialog box. If the .Show method returns True, the
' user picked at least one file. If the .Show method returns
' False, the user clicked Cancel.
If .Show = True Then
'Loop through each file selected and add it to our list box.
For Each varFile In .SelectedItems
DocsPath_TB.Value = varFile
Next
End If
End With
End Sub
---------------------
View 5 Replies
View Related
Sep 12, 2014
I work in a school where teachers have to archive their assessments and other documents monthly. Currently they email them to a set email address but I was wondering if it would be possible for me to make something with access whereby they can do this. I'd like to make a form where they selected their name and then attached a file, this file would then be saved in an area I would have assigned that persons name to, does this make sense? I want it to be very simple so just a name section from a dropdown then a file upload section and done.
View 11 Replies
View Related
Oct 31, 2007
Hi Folks,
I have created a file sweeping program in Microsoft Access via VBA in a few modules. The program simply reads certain files in certain directories, and determines if, when, and where to copy those files based on certain user inputs.
One of the features I would like to add would be to upload the files that meet that criteria to a conventional FTP server requiring a username and password. However, the last few days of research all tells me that it is not possible to perform FTP functions in Microsoft Access or in VBA.
I am just wondering if that statement is really true? I figure the worse case is that windows has its own version of FTP.exe that you can execute in a DOS window ... would one be able to perhaps create a command line execution via VBA? Any simple ideas or is it not worth the trouble trying to FTP upload some files via Microsoft Access with VBA?
Thank you very much,
Joe
View 1 Replies
View Related
Nov 16, 2004
I have a database application that I have to get to display some external PDF files.
I thought that I would create a command buttone and use that to open the files, but that doesn't want to work. Can anyone provide some thoughts on how to open a Word document or PDF file from within an access form? I only need to display it and then close the file so it doesn't have to be anything fancy.
Help
View 9 Replies
View Related
Jan 15, 2008
hello good afternoon.
i am trying to open different file types using ms access. the following piece of code i found would only open 'word' documents. how do i make this piece of code more flexible to open pdf documents and excel as well. as it is currently i have a txt field on my form and if the path in the txt fiels leads to a word document when i click a button the word file opens. i want it to open a pdf or excel doc if it was in the txt field
[code]
Sub OpenWordDoc(strDocName As String)
Dim objApp As Object
'Opens the document
Set objApp = CreateObject("Word.Application")
objApp.Visible = True
objApp.Documents.Open strDocName
End Sub
View 4 Replies
View Related
Aug 21, 2014
I have inherited a number of 2007 Access databases that have a PDF (Adobe Acrobat Document) as the file type for the locking record.
These databases seem significantly slower, and have more frequent "Not Responding" periods on the network - especially when compared to those with a standard ldb file type locking record.
What determines the file type for a locking record?
Can the Adobe locking record be changed to a ldb? and How?
View 9 Replies
View Related
Jan 26, 2014
Looking for a way to use transfertext to make a table and create a spec file from csv files I am importing. I want all fields in the table to be shorttext.
Otherwise I need another way to bring the files into a table.
I have a generic spec to use that brings in any data as text.
Created the spec from a delimited file with 255 text fields... Field001, Field002, etc.
However the field names need to be changed. My field names are in the first row of a table. I will need to read each fields data in the first row and rename the field.
View 1 Replies
View Related
Aug 19, 2015
I would like to open a PDF document using a button control on a form to a file path listed in a field on the form (Me.Link). I am trying to use the followHyperlink code but I keep getting the runtime 490 error.
This is the code im using:
Dim strFilePath As String
strFilePath = Me.Link
Application.FollowHyperlink (strFilePath)
If I put a filepath to one of the pdf documents in the place of (strFilePath) it opens that pdf document fine but not when I declare a filepath based on the one listed on the form.
View 8 Replies
View Related
Oct 5, 2014
I've got the forms and queries in one .accdb file and my tables in a separate .accdb file. The forms file links to the tables in the tables file. The tables file resides in a folder called simply enough C:acc_tables and thats where i browsed to (obviously) when i set up the linkage.
One of the users does not wish (for whatever goddamn reason) to create a C:acc_tables file to stick the tables file in , and wants the tables file in some other folder.. Unfortunately this user does not have the skills to delete the existing links and re-link to the tables file after putting it in the folder he wants.
Where in the file that holds the forms and and queries do i find the path setting to the tables linked file? Can it be changed without deleting links and then re-linking?
View 4 Replies
View Related
Dec 5, 2014
i had a database that allowed me from a form to store a file location for a record on a form, so i any time i could access the record, and then open the file, usually a pdf, it wasnt stored as a hyperlink, but as long text
i made the mistake of not copying the files for safe keeping when i got a permanent position..i am now back self employed, i need to recreate the database.
View 4 Replies
View Related
Apr 18, 2013
I need to open a specific pdf file per record by using a command button. The pdf files will all reside in a specific folder in a partition on my hard drive. Each pdf file will have a unique four digit file name e.g 1234.pdf.The file name will match a unique number allocated to each record. This number is generated by adding 1000 to the record ID.Record 10 will therefore have an associated pdf file name of 1010.pdf.I have created a text box field , named 'TestReportID', to capture the unique four digit number per record that I assume is needed to be referred to when setting up the code to find and display the correct related pdf file.
I have set up a command button on the records form and as simple test using the hyperlink address to the folder where the pdf files reside, I can open a pdf file by clicking on the command button but it does not matter what record is open when I click the command button, it will always open the same pdf file.If I don't identify a specific file name in the hyperlink address, when I click on the button it will display a file open dialog which lists all the relevant pdf files and I can then select and open the required file.I would like to cut out that step and get the correct file to open when I click the button.
View 2 Replies
View Related
Apr 22, 2013
I saved my database as ACCDE file which is executable now the problem i am facing is i can't edit my database since i can not view it into design view.
How can i change it to its normal file format
View 4 Replies
View Related
Jan 28, 2014
My company wants to store both a digital copy and a hard paper copy of the files in the access database. Because of this I need to figure out a way to show in the reports the paths to the attached files so that people reading the paper versions can locate the corresponding files on the computer in the future. I have been searching the internet for several hours and have come up with nothing. Is there a way to do this?
View 1 Replies
View Related
Nov 23, 2006
I tried to use wizard to build a button that will run a file from WORD. but it doesn't seem to work.
When i'm on wizard for runapplication, it even gives an example.
Excel.exe c:Travel rips.xls
Anybody could help me?
View 2 Replies
View Related
Nov 8, 2007
Hey again all!
Implementation is going fabu, but I had a request to add a button on the main form to open the HTML FAQ I wrote. I thought I would be able to quickly point the button to the file using the button creation wizard, but that doesn't seem to work so well. (not at all)
Did I miss something or is this something that needs to be coded with VBA (very little knowledge of VBA here... negligible even.)
View 1 Replies
View Related
Nov 9, 2005
I currently export a select query as a .dbf file to a particular location and file name. I would like to automate this procedure to a command button on click event. Does anyone know the code to do this or have another way for me to do this automatically? It would even be better if I could export this same Query to Crystal Report automatically.
Thanks for the help!
View 3 Replies
View Related
Aug 10, 2014
I am trying to code a button to select a file path.I get a compile error: User-defined type not defined on the following line;
Code:
Dim fldg As FileDialog
View 7 Replies
View Related
Mar 11, 2014
I often create contract using mail merge. I have an access file that I want to use as data source for word file. But it does not automatically.
Please download the attached file !
If there are 1 customer and 1 property, I do not need to do anything. Conversely, if there are many customers and many properties, I take time to manipulate.
Firstly, I open the word file. I have to copy and paste paragraphs that I want. Highlight of the original paragraphs is blue.
Secondly, I click 'Insert Word Field' -> select 'Next Record'.
In short, I wish to use VBA in access file to automatically perform the steps that I have outlined.
View 3 Replies
View Related
Jul 20, 2006
hello,
I would like to automate something presently done on a one-by-one basis. Here: a number of text files(containing data) are to be exported into an MS Excel file, with each text file to occupy a different worksheet. Presently, the idea is to use the Data/import external data/import data feature of MS Excel for importing the text files one-by-one into newly created worksheets(within the same workbook).
I would appreciate some advice on how to go about creating a useful MS Access application to achieve the above. I have checked the available Macros in MS Access, but I could not find one to suit my purpose. can anyone pls assist, on how I can get started?
Tokunbo
View 3 Replies
View Related
Aug 14, 2015
Question: Is it possible, using VBA, to determine the actual Excel file type without opening the file?
I receive data files from other departments. Seems like every time someone changes their download structure, I end up with file types that do not match the download extension (example: xlm file with a xls extension). The files can't even be opened because of this. I think I can fix it if I could figure out how to determine what the file type really is.
I'm using Office 2010.
View 3 Replies
View Related
Jun 20, 2014
I am using the following code to select files using Microsoft Office's file dialog:
Public Function fTestFilePicker() As String
Dim fdFileSelection As Office.FileDialog, lstrFileName As String
Const kInitialFile = "F:TestbedTest.txt"
Set fdFileSelection = Application.FileDialog(msoFileDialogFilePicker)
With fdFileSelection
.AllowMultiSelect = False
[Code] .....
When I execute it, the file picker goes to the right folder but does not highlight the file test.txt even though that file name shows in the File name text box. Is there any way to correct this?
View 7 Replies
View Related
Aug 24, 2007
Does anyone know the code for opening a specific notepad file from a button? I know there's a default button but it only opens a blank notepad page. I need to open some written instructions from a button you see.
Thanks.
View 3 Replies
View Related