Is there a way to create an import specification automatically, such as via vba? I'm trying to create a form that will allow a user to import a list of fields that could appear on a table. This field can change though depending on what kind of list they are trying to import. Does anyone know a way?
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.
I'm interested to find out what spec of PC everyone here is using, more so for those of us who develop and work with access daily as part of their job.
Currently my pc at work is:
HP Compaq dc7100 multiprocessor Intel Pentium 3.00 Ghz 512MB RAM (:( I know! I'm getting 2GB upgrade!) 80GB HD Win XP Pro SP2 Access 2003 (Have 2007 installed but databases developed in 03)
Find it very slow with one of my larger test databases when working with a local copy. I'm constanly having to crash out during development and sometimes it takes a while to get into the backend. All my live databases run off a network server and are split. They don't have any major performance issues for users. It's development time on my own PC that is slowing me down.
I have comboboxes on forms that i have entered the values for the drop down list in.They are on a form with textboxes and go through a one to many relationship via an intermediate table.I deleted one value from the list as it was no longer required and i also deleted the records that used to use that name.
When i looked at the list, the value is still there?I tried inserting a new Combo Box - the same?Will it clear if i create a new blank Database and import everything?
I'm using an MS Access 2007 command to open Outlook. I can get it to open, fill in address, subject, and text, but what I haven't been able to conquer is to get it to send without a mouse click on the send button within Outlook.
I want the email to fill in and send without any human interaction at all.
I need to know how to change the Access variable names programmatically.
I have a large Access database, with hundreds of variables that need to be shortened to 8 characters since they are to be imported into a SIR database, which does not allow variable names longer than 8 characters.
Because the variables have to be unique and yet still identifiable, I have to write code that will do abreviations. For instance:
hello! i'm trying to select more than one value in a listbox based on a comma-seperated string in a textbox. it seems to be doing what it's supposed to do, except it's only selecting the last value it loops through. it doesn't seem to remember the others. there's probably an easier way to do this than how i did it, but here is the code:
Code:Dim lst As ListBoxDim lngCount As LongDim strSelection As StringDim strNewSelection As StringDim intLen As IntegerDim lngLen As LongstrNewSelection = ""strSelection = Me.Text19.ValueWhile InStr(1, strSelection, ",") <> 0strSelection = Trim(strSelection)lngLen = Len(strSelection)intLen = InStr(1, strSelection, ",")strNewSelection = Left(strSelection, intLen - 1)Set lst = Me!List0lst.RowSource = lst.RowSourceFor lngCount = 0 To lst.ListCount - 1 If lst.Column(0, lngCount) = strNewSelection Then lst.Selected(lngCount) = True Exit For End IfNext lngCount strSelection = Right(strSelection, lngLen - intLen)Wend
Using Access 2000, I have an BeforeInsert event to set a value in a field by referencing the form/subform/fieldname. When the user enters a new record simpy by arrowing down the subform, this value IS entered but NOT displayed until the record is saved.
How do I get the programmatically stored value to display on the proper field box WHILE the user is entering the other fields?
I assume the NEW record is a buffer (not in the database yet), so perhaps I need to reference the new record buffer so it displays on screen. How do I reference that?
I want to progammatically align the report controls position. I have a control with left=2.7 in the Design view property. I want to set programmatically set this value to 3.0 or other value accoring to a parameters. The problem is that when I set this property at the event Report-Open, the control appears always in another position regardless of the left value, i.e appears always at the new constant position.
I have a Paycheck form with a subform on it. The goal is to not have to click on the check field for every paycheck, instead use a Batch procedure. When you click in the subform (field) (CCheckNo) which gets the focus by default it advances to the next check number and performs other code operations. If you have a lot of checks this is not very user friendly. I created a command button on the subform to try and auto ate this process. Below is the code for this. It gives no errors but does nothing. The db is very complex. The form opens to the first record but can't be sure when the user could run the Batch procedure.
The idea was to try and use the OnClick procedure to run the event code. The field in question is CCheckNo which advances the check number.
frmBonusReimbursementChecks is the Main form. (Check) form is a Subform CCheckNo field gets focus on Load which is the Subform.
Code Below is on a Command Button on the Subform.
If MsgBox("Are you sure you want to Assign All Checks?", vbYesNo, "All Checks Confirmation") = vbYes Then End If If IsNull(Me.CCheckDate) Then 'If no Check Date, Assign One. Me.CCheckDate = Date End If If IsNull(Me.[CCheckNo]) Then 'Advance to the next available Check Number. Me.CCheckNo = Next_Custom_Counter
when trying to automatically send email through MS Access application, the following message appears:
"a program is trying to access e-mail addresses you have stored in Outlook and asking if you want to allow this" "a program is trying to automatically send e-mail..."
How to disable these warning messages when executing MS Access application to send email?
I have an Image control on a form which I want to examine programatically. It seems there used to be a way of doing it using Point and PSet from info I have seen online. Is this contained in any of the libraries available under References in Access and if so which one...
I am using Access 2010. How to change the property of a field in a table programmatically.
I have a table in which one field has Required property set to "Yes". I would like to set this property by using VBA code to "No", then add data into a table using a query and re-set the Required property to "Yes".
i have 2tables,table1=productid,ProductName,Qty table2=Productid,productName,Qty,date(). I want to be able to backup Records programatically daily from table1 into table2 OnClose.But i do not want duplication of record in the same day. If changes occurs in table1 after backup,table2 should be updated Programatically.
I am after a script to change the linked table paths like the following.
It will only ever be the path that is changing not the file name and only ever linked tables
Code: for each table in tabledefs if table.path = c:Testing* then table.path = w:Testingfilename if table.path = c:Jobs* then table.path = w:Jobsfilename if table.path = c:Quotes* then table.path = w:QuotesNewfilename next table
I need a way that I can simply have a User click a button on a form of the database and it will do automatically create a zip file of the entire database and start Outlook and attach the zip file and send it to me.....
Pls. help!!!, the attached document is the application I want to programmatically control the data entry:
1.) Parent Form is unbounded fields, and set a record source in my table "BidTabTransaction". If I want to retrieve record, I just populate the table by querydef and sql into recordset and put all the table fields into form fields. The same thing if I want to save the record, and edit the record in the form.
2.) My problem is the child form. I set a record source in my table "BidTab Details". I set the child form to allowaddition=Yes; data entry=No;Allowdeletion=No;AllowEdits=No then it just simply display the records which is equal to Bid Tab No. because it is bounded the form fields into record source fields of "BidTabDetails" Table.
How could I retrieve a record from parent form and display the details in the child form in both unbounded form fields? (FrmBidTabTransaction & FrmBidTabDetails)
I would be grateful if someone out there attends immediately with my problem because I am in deadlock deadline to submit at least a partial running application. Thank you for your kindness...
Will be waiting. You can email me at jrb_ph@yahoo.com. God Bless!!!
I have a form (about patients) containing a listbox (list of visit dates) and a subform (showing medications at that date). When you click on the listbox, the subform is re-queried with the selected date as a parameter to show the medications that were in use on that date. This is working fine.
However, when you move to a new record (patient), the subform is initially blank because the listbox hasn't been clicked on yet. This means that it looks like the person isn't on any medications, which is causing some confusion.
I need a way to have the subform show the "top" (most recent) date because that is the current medication list, and the thing most people want to see first. It is always the top of the list, so I would like to do something like this (pseudocode)
Code: Private Sub Form_Current() Forms![MedSearch].SelectDateBox.Requery Send MouseClick Event to line 0 of SelectDateBox End Sub
I have one Access Database and i want to import the flat file coming from Cisco Phone Logs, its a comma delimited that contains the column names in the first row, and in the second row, its the data type, then the succeeding rows contains the data of the logs which are in Comma separated values, I want to put it to my created table programmatically,I used Docmd.TransferText but this will not let me define the row which i wanted to start at row 3.
I have the following piece of code for importing the .csv files from a selected folder and then renaming them into 'imported & filename' if succesful and 'failed & filename' if import failes for whatever reason (bad formating, etc.).
The problem is that the first time it encounters a 'bad' file after another, instead of going again to the Error handler, the command
gives me the default MS Access error, namely 2391. I would like it to go the the Error_handler again ang follow the course of actions and rename the files into 'failed' and 'imported'.
Here's the code:
Sub ImportActivitate() Dim strFile As String 'Filename's Dim strFileList() As String ' File Array Dim intFile As Integer 'Number of files Dim filename As String, sFullName As String, sFilename As String DoCmd.SetWarnings False
[code]....
Also, how can I make the routine stop cycling through the files after I renamed them all?
I want to make a database of diseases (need to learn them for school and would like a serchable database on my smart phone for future reference). Unfortunately spent a lot of time making hundreds of pages of word tables before i realized a database would be better. See attached image or pdf. Is there a way to import the tables to Access?
I need to preserve the hierarchic info in the nested bullet point lists. E.g. under treatment i might have a point called Acute treatment, with sub-levels, Step 1, Step 2, etc. with their own sub-levels. I need to maintain this relational hierarchic info.
I have a multi slect list box (simple) and I need to find and select an item using vba - e.g., the bound column is the ID field and I need to select a specific ID (which will be different each time) as opposed to selecting the 100th record for example. How do I do this?