I have a problem and not sure what the best approach is.
Our study enrolls patients and then re-contacts them every month for 1 year. I want to create 12 new records in "Table2" based on the "baseline_date" and "StudyID" of each patient in "Table1". "Baseline_date" is the initial date the patient is enrolled in the study and "StudyID" is a number created based on information from the patient. Both are unique values. What I want to do, is after the "baseline_date" variable is updated with the date of enrollment on a form I want to trigger VB code to automatically create 12 records in "Table2". "Table2" would have the following variables: "StudyID", "Early_Date" and "Late_Date". The records would be created based on the following.
The -3, +10 gives us a two week window in which to contact the patient. "Table2" containing the newly created records will have a many to one relationship with "Table1".
I have searched, but found no reference to my exact question. I have a list of drivers I need to create a checklist for each day. The Parent form is the day and the subform is the list of drivers. What I would like to do is have a command button automatically enter all the drivers that are active (denoted by a chechbox) into the tabular subform.
Hello there is a field in my form named "numphotos" and I write the number of photos than that folder contains.
I have a subform in that main form named "descriptions", here I describe, one for one, all photos of that folder.
Itsnīt a problem if the folder contains a few photos, but I have folders that have even 100 photos :confused: then I must to create 100 records in my subform :eek:
I would like than Access create those records automatically according to the number of photos that I indicate at the field numphotos.
My example in photo: http://farm2.static.flickr.com/1141/1093088982_a084bff95f_o.jpg
I only would desire that Access create that many lines to me as I have written on "numphotos". I would write the rest of the information (photographer and description)
I have a database with over one hundred employees in. Attached to each employee is a relationship where they can do many activities. How can I automatically create one activity record per employee at the beginning of a day and give the date field in the many part of the relationship the current days date.
I assume you've got to create a recordset and do something along the line of - do until EOF docmd.acrecnew. But haven't got a clue where to start.
I have a table in access which captures a couple of bits of information. The database is for tenant management and payment records. This is what i am trying to achieve:
In one table I record payment information, when they paid, and how much they paid.
In the lease table I capture information such as first pay date, and the payment schedule, whether this be weekly, monthly, fortnightly etc.
I would like to create a table of sorts which has the next twelve months worth of payments dates. Then when i add a payment to my payment table it will match it up with the correct payment date. This will allow me to track arrears and missed payments.
I want to create a database that keeps track of contributions of members of an association. Every member can voluntarily give a standing order to contribute a fixed amount every month. A member can as well decide to review his/her contribute.
how I can come up with a database that can automatically add the contribution of a member monthly without manual input since the stated contribution is known. So that I can run a report for individual member and the report can capture the every monthly contribution that has been added automatically and shows when ever a member changes his/her contribution amount.
Is there a way via code in a module to automatically create a snapshot of a report, save it in a specifed folder location in the code and save it as the current date as the file name when a button is clicked.
I'm looking on how to do this as I have many reports to create, move to an intranet folder and then name it to the current date. It will save me lots of time if this can be done automatically.
I am using MS Access 2000 and the folder location will be on my hard drive.
In my DB I'm tracking seed. I have a form that I enter in some info in and an ID number is created (based on that info). Then in a different form I track "events" that happen to that ID (drying, moved, bagged). Is it possible to have a button or something like that that after my ID is created from my frmHarvest to automatically generate an event in tblEvents that has the date the ID number and then have something like Harvested in the description field?
I have a form and it has a field as question. I also have a field as I'd in this form from the same table that is autonumber. I want that for each field the question will be created automatically in the table as below:
Is epm ( my Id field) is created Is epm and is created are string
They should also include Id number of each row. So It would be like:
Is epm -1 implemented Is epm-2 implemented . . For each row
I am using an attendance management system with a DB in Access. Now I want to create APPLICATION_ID automatically by continuing number. For example, I have a table called "LEAVE_APPLICATION" and the structure is below:
Now I want to update the table by adding the below data
00360 2 00360 2 01390 14 01390 1
How can i create the APPLICATION_ID field auto generating while pasting additional data. It should be numbering continually from the last record (Grouping to be applied for EmpID)like below:
I created two tables, let's refer to them as Cars (VW, BMW and Audi) and Colours (White, Black and Grey).
Is it possible to create another table based on these tables - i.e. in the new table the rows will be the Cars and the columns the Colours as such:
White Black Grey
VW
BMW
Audi
And should I enter another Car or Colour in one of the first mentioned tables, then I would like this "new" table to update automatically. For example, if I have a new Car (say, Merc), then I would like the "new" table to update to the following:
I use Access 2013. Is there an easy way to do the following: I have a contract that starts on eg 01/07/2015. Tenant has to pay 100 each month. Is there a way to create a query/table/... where access automatically makes a due date? EG: Joe needs to pay me 100 each month, starting 01/01/2015 until 31/12/2018.
This means:
01/01/2015 - due 100 from Joe 01/02/2015 - due 100 from Joe ... 01/12/2018 - due 100 from Joe
I've been building a CRM in Access that allows for creating profiles for our accounts. When we add a new account, I'd like an Account ID to automatically generate and look like this: CRMXXXXX where the X's represent a random number. I originally wanted to set the field as autonumber to just count up, but unfortunately I need to append this value to another sales database we have; you can't store the text "CRM" with an autonumber in a table.
Right now, all I've done is place an equation in the default value of a textbox I have on my 'Add Account' form. I then made the control source of the text box the Account ID field. My equation is as follows:
="CRM" & CStr(Int(Rnd(Now())*10000))
This appears to work, as it generates a value in the correct format. However, I've realized that each time I open the CRM, the random numbers start over again and I run into issues of trying to create a new record with the same ID as a previously created record. I assume I need to incorporate some sort of timestamp to it in order to change it.
I am trying to create a form button that will automatically email each row of a query result to myself. At first the VBA code worked fine with a standard query. However when I use it with a query that contains a reference to a combobox form such as "<=[Forms]![Reminder]![Monthsleft].[Value] And >=0" I get the 3061 run-time error and "Too few parameters. Expected 1." I have included the VBA code below.
Private Sub Command9_Click() Dim MyDb As DAO.Database Dim rsEmail As DAO.Recordset Dim sToName As String Dim sSubject As String Dim sMessageBody As String
[code]....
If you intend to renew the lease, terms and conditions will need to be submitted for ECC for approval (regardless of changes or not in lease rates). If the terms have yet to be confirmed, it is important to begin the negotiation process as soon as possible with a target to provide the ECC submission at least two months prior to the commencement date of the renewed lease. To ensure sufficient time for ECC approval before the contract expiry date, please prepare the ECC paper and obtain necessary endorsements. Submission details can be found here. The ECC submission template and PSD Questionnaire could be found from this link
When I import an excel spreadsheet into my Access database it always creates a couple of new blank records. I import this spreadsheet frequently so I would like to set up a macro that will automatically delete any blank records it creates. Can someone tell me specifically how to do this?
I have for some time now been fooling around with a database to keep track of several clinical trials Basicallly I have made 4 tables..2 which defines the project ( Project and visist), 1 that populates the projects ( patients) and 1 that bind the patients visits to specific dates ( appointment)
The trouble is that im Lazy :D and therfore dont want to enter the appointment data for all patients one at a time each time we get a new guniea pig since all thats diffferent is the dates he/she has to show up. Im hoping for some way to fill up my appointment table based on patientID and projectID alone.
SO this is my 4 tables... ( some unimportant fields left out)
The idea is to create a project and then add a set amount of visits to the project ( days when they have to come and get a blood sample taken) All patients involved in the project is likewise added in the Patients table and joined to a project.
Since the patients all have to come to a fixed amount of visits ( determined by the project) I was thinking I could make a form where I pick a patient from a combobox (select projectID,PatientID,PatientName) and then automatically generate a record for each visit in my Visit table where Visits.ProjectID = cboPickPatient.ProjectID and show them in a subform so I can enter the date they have to come. I hope that makes sense. ( preferably I would like to add the date also by just entering the first Visit date and the using the DaysToNextVisit to make the other visit dates or each patient, but thats a whole other problem :o )
My instinct tells me I have to do some sort of loop code but I havent figured out the details.
Can any of you guys lead me in the right direction before I loose all my hair in frustation??
This seems to me to be a pretty simple problem-making a recordset based on a projectID and the visits involved in that project but im just out of ideas:confused:
I currently Have this form setup in 2 sections. The first section includes 2 text boxes for Eligibility Number (field name = EligibilityNum) and the second for School (SchoolName). The second section is a subform called sfrmSchools that includes all the eligibility numbers, schools and other useful information.
I have created an Access 2003 database from a ledger. The main key is an eligibility number that corresponds to a school. There are over 2000 schools in my database. How can I program Access to automatically find the record (eligibility number or school) if I type it in the first section. For instance if I was looking for a given school with an eligibility number of 5670A0324. If I type in '56' I would be taken to those eligibility numbers with 56 to show. Same for if I typed in the name of a school. If the school I wanted started with 'D', I would be taken to them.
Okay I had an idea and I thought I might get ffedback as I am relatively new to this. I went through a period a couple of years ago when I used access alot and was becoming familiar with VBA etc but I havent touched it in 2 years so Im pretty rusty.
I am running a study and need to have to create a database that:
a. collects data about participants b. Has a number of questionnaires (5), each of which can be filled out by participants.
THe main table has a number of fields that collects info about the participants the most important of which will be the ParticipantID - an automatically generated number which is my primary key.
In table 2/form 2 I will host questionnaire one. This will be linked to Table 1/Form 1 (Particpant Information) by this tables primary key - also the Participant ID. The relationship will be 1:1. Each participant can only have one Participant ID and will only need to fill out questionnaire one once.
Is it possible that when I add a new participant to the Participant Information table/form I also automatically create a record in Table 2/Form 2 (Questionnaire 1), as well as Table 3/Form3 (Questionnaire 2) and so on so that they have the same ParticipantID...?
I was reading a similar query somewhere else and they said to use the Form_AfterInsert Event command? Is this right (see here http://www.pcreview.co.uk/forums/thread-1687644.php)?
I feel a bit stupid but I am willing to learn and try new things Once I get started I think I will be okay. If you could steer me in the right direction it would be much appreciated.
I added several records in another table but it wont show the records until I press the Refresh button at the ribbon of Home-> Refresh. How can i view the records automatically without pressing the Refresh button?
I'm trying to create a table that automatically contains records for every permutation of the two foreign keys it imports. Let me explain with an example:
I have a Characters table: CharacterID (Primary Key) CharacterName CharacterClass [...]
And, I have a Skills table: SkillID (Primary Key) SkillName SkillDescription [...]
I want a third table named CharacterSkills to combine those two tables. It might look like this: CharacterID (Primary Key) SkillID (Primary Key) CharacterSkillSlot [...]
That looks a lot like a junction table for a many-to-many relationship. The difference is I want this table automatically filled with every combination of Characters and Skills. For example, if I have three characters and five skills this table would contain fifteen records. If I add a fourth character I'd expect this table to grow by another five records (as one record per skill is automatically added).
Here are those same tables with some example data.
Can someone direct me as to the most efficient way to add records to a table from a form? I have a table of members and a table of invoices and want to automatically create an invoice for each member by clicking a button on a form. Is there a way to do this using a macro, query, or do I write it in VBA?