Forms :: Add A Command That Changes Contact Status In Archived Field Of Table

Jun 18, 2013

I have a query that gets it's data from tblContacts. In this table is a yes/no field for archiving and the query gets only those records with a No in the field. The default is no. Next I have a form based on this query, which I am using to hold a set of command buttons which act on a contact chosen from an unbound list. So far so good but now I would like to add a command that changes the contact's status in the archived field of the table to Yes, so that I can use the form to view/edit, or email, or archive.

View Replies


ADVERTISEMENT

Forms :: Command Button To Open Datasheet Of Contact Names

Dec 5, 2013

I am trying to add a command button to my main menu to open the contact names as a datasheet, I have changed the properties on the contact names form to datasheet as well as changing the properties on the button to the below:

Private Sub Command48_Click()
DoCmd.OpenForm "Contact Names", acFormDS
End Sub

at first after I saved it, the button did nothing. Now after a bit of playing around (probably not a good idea) I have a new message that states:"The expression On Click you entered as the event property setting produced the following error: Ambiguous name detected: Contacts_Click.To add some additional information, in the vba sheet above the code i wrote above it says:

Option Compare Database
Private Sub Contacts_Click()
DoCmd.OpenForm "Contact Names", acFormDS
End Sub

Private Sub Contacts_Click()
DoCmd.OpenForm "Contact Names", acFormDS
End Sub

should I delete this?

View 5 Replies View Related

Tables :: Update A Field In One Table Based On Status Of A Field In Another Table

Aug 2, 2013

I have started work on a database to track the many (several hundred per annum) projects my company undertakes. A 'main' table lists projects, their fees, their key dates, their project numbers, etc. I have created another table for tasks. Each task is assigned to a project (via the project number), and may be 'open' or 'closed'. I have separated the tasks table from the projects table as there may be several different tasks for each project. It is also good to keep a record of the tasks.

I want to prepare a report from the projects table that lists projects IF they have any open tasks.

In my mind, this means 'If a task, with the corresponding project number, is open, put a 'Yes' in the 'Tasks open' field of the Projects table.'

View 7 Replies View Related

Contact Table - Filter Set For Field Not Saving

Dec 17, 2011

I Have a Contacts table, when I use the filter on the field that I want filtered I get what I want, no problem, however when I save that filter and close the table and then reopen it it the filter is gone, how can I save the filter that I set up?

View 2 Replies View Related

New Record For This Contact - Command Button

Sep 7, 2006

Hi all,

I have a database for customer enquiries, and there is one record per product that the customer shows interest in. I want to have a button on the enquiry details form that creates a new enquiry but automatically fills in the contact details from the previous record.

Please also note that I do not wish to "normalize" this so that there is a seperate table for contacts and another for enquiries; it's much easier from our point of view to have the whole enquiry in one record, especially as this is a stand-in database before a fully integrated CRM is implemented. In any case most of the other data (e.g. product, category etc) is already stored in separate tables.

What sort of method do I need to use to create a Command Button that:

-Creates a new record
-Copies and Pastes data from selected fields into the new record?

I tried using the command button wizard for sample code but I got paste errors which were pasted into a new table, and I don't really understand the process of how this works as the Commands are numbers from a list (apparently in the macro window), which I can't find.

I'm using Access 2003 but the database file is in A2000 format. The code is below.

Thank you!



Private Sub ContactAddEnq_Click()
On Error GoTo Err_ContactAddEnq_Click


DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 2, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 5, , acMenuVer70 'Paste Append

Exit_ContactAddEnq_Click:
Exit Sub

Err_ContactAddEnq_Click:
MsgBox Err.Description
Resume Exit_ContactAddEnq_Click

End Sub

View 2 Replies View Related

Modules & VBA :: Add Contact From Outlook - Command Or Action Not Available

Jul 26, 2015

I am trying to use

RunMenuCommand
command : AddContactFromOutlook

But i get this error message

"The command or action AddFromOutlook isn't available now "

on a demo access "project manager" it works but in my data base does not ...

View 1 Replies View Related

Forms :: Change Button Enabled Status On Field Values

Jun 22, 2014

I have several buttons on a form and I want to set enabled = false on one of them when I open the form - that's fine

I have two txt fields - ReceiptNo and BankPaymtId if the both have a value I want to make the button enabled = True

This is the code I have used on the BankPaymentId On Dirty event

Private Sub BankPaymentId_Dirty(Cancel As Integer)
If Me.[ReceiptNo] <> "" Then
If Me.[BankPaymtId] <> "" Then
Me.CreateOutlay.Enabled = True
End If
End If
End Sub

This is the one for ReceiptNum on Dirty event

Private Sub ReceiptNum_Dirty(Cancel As Integer)
If Me.[ReceiptNo] <> "" Then
If Me.[BankPaymtId] <> "" Then
Me.CreateOutlay.Enabled = True
End If
End If
End Sub

Nothing seems to be happening.

Even the Form on Dirty is not working now....

View 4 Replies View Related

Forms :: Checkbox Based On Status - Updating A Text Field

Mar 8, 2013

My database has a text field "Status" where the text is either, A, W, C. There is a form to update this field; currently it uses a standard Access created text field. The users want a checkbox which will show up as checked when the status is W, if the status is anything else, the checkbox will be blank. If the user clicks the checkbox within the form the status will be changed to W.

If [table.status] = 'W'
then checkbox = 0
else
checkbox = -1

and then somewhere on the update it would be

if checkbox = -1 then [table.status] = R

Except that Access doesn't think the way I do.

View 1 Replies View Related

General :: Lock Archived Records To Prevent Editing?

Dec 12, 2012

I want to lock archive records so that they can't be edited, however I want them available to users for viewing. So for example if the file is "closed" the record can not be changed.

View 5 Replies View Related

Command Button To Populate Field With Value From A Table?

Oct 14, 2011

What is the best way to get a Command Button to populate a field on a form with a value from a another table in the database?

View 3 Replies View Related

Forms :: What A Command Button To Link To A Field

May 10, 2013

Ok so the Data I have holds a hyperlink to a file this field is "basepath".In Form view I want to have a command button that reads the basepath (for that record) then opens said hyper link.

View 3 Replies View Related

Copy Field Data To Status Bar

May 24, 2006

I have a form that resembles a spreadsheet and have data in certain fields that is longer than the field is wide. (The widths are set according to client preference and widening the field is not the solution.) I was thinking perhaps I could use the status bar to show the data when the focus is on that particular field. Right now, the only help on the StatusBarText topic that I can find indicates that the status bar can be "programmed" with static text only, but I was hoping to make it dynamic, depending on the field in focus.

If this is the wrong approach (i.e. can't be done), does anyone have any ideas about how to use an external control to show (and possibly edit) data on a spreadsheet-like form?

The client has been using MS Works and is being dragged into Access only if the transition isn't too painful (for him, lol) and having an ability to look and feel like the Works interface is important to him.

Thanks,

- Terri J.

View 3 Replies View Related

Reports :: Group By Status Field

Jul 11, 2013

I have a working report which groups by a status field. Let's say I have Status (AA, BB, CC, DD, EE). It is grouping and summarizing fine. I would like to be able to merge some groups. So I would like to be able to Group on (AA/CC, BB, DD/EE).

What would be the best way to approach this?

View 4 Replies View Related

Forms :: Disable A Command Button Until Field Is Populated

Sep 17, 2014

I am going round in circles here; I have a form which has certain text fields that need to be populated before a user can click a command button named 'Record Movement' that opens up another form. What I want to do is disable the 'Record Movement' button until these fields are populated. I am using Access 2010.

View 6 Replies View Related

Forms :: Update Date Field With Command Button

Dec 31, 2013

I want to be able to update a date field in my form with a command button based off the date the person picks off a combo box in my header... is this possible?

View 1 Replies View Related

How To Add Contact With Field Notes (Memo) In MS Access To Outlook

May 31, 2012

How to I can to add contact with field "Notes" (Type: Memo) in MS Access to field "Notes" in Outlook contact

Is it below ???

item.Notes = varNotes & ""

View 8 Replies View Related

General :: Automated Order Status Field

Feb 25, 2014

Basically working on a Customer Order Database for my carpet shop.

I have a Customer, Job and Order table. The order table contains the line items for each job and each customer can have many jobs.

I have a field in the Order table showing the item order status being either "Instock", "To be Ordered" or "Ordered"

I also have a Job Status field in the Job Table

I would like that Field to be automated depending on the item order status for each item on the job.

At the moment the Job status is a manually selected drop down box of either; 'Ready To Fit', 'Awaiting Stock', 'Items To Order' or 'Job Complete'

For example if all of the items had a item order status of 'Instock' then the Job Status would display as 'Ready To Fit'

If any of the items were 'To Be Ordered' it would display as 'Awaiting Stock'

I dont know how i would solve the situation of some marked as say 'In Stock' some 'Ordered' and some 'To Be Ordered' ????

Also the 'Job Complete' would come from another field in the Job Table marked with a check box...

View 5 Replies View Related

Forms :: Rename Command Buttons From A Table?

May 4, 2015

I made a Point of sale using a form with different sub-forms which have command buttons on it. They basically run a append query from tblStockMain to table cash and on to transactions. That works all fine no problem.

The one missing thing to make it sweet is to rename the command buttons automatically from tblStockMain. With other words, if I change a product in the table it would change the name on the button and the picture if possible with it.

Is there a way to do it?

View 2 Replies View Related

Correct Syntax To Write Command Line Able To UPDATE More Than One Field In Table

Nov 24, 2014

what is the correct syntax to write a command line able to UPDATE more than one field in the table records having multiple WHERE criteria.

Here is my challenge:My TableI has the columns A, B, C and D which are populated, for example, as follows:

TableI
A B C D
1 2
2 6 4 3

1 7 5 9
1 2
2 5 8 5
etc.

I also have a FormII which updates TableII. Among the existing fields of TableII there are the fields C and D (same as above). When saving data entry thru the save button of the FormII, fields C and D will be naturally saved on the TableII. Well, I also want C and D info updated into Table I as well, but only when field A=1 and B=2.So what I need (for the click event of the button save in the FormII) is to open TableI and either insert or update it with the values of the fields C and D in every record WHERE A=1 AND B=2.For instance, assuming C=& and D=%, the desired result should be as follows:

TableI
A B C D
1 2 & %
2 6 4 3
1 7 5 9
1 2 & %
2 5 8 5

I did not find any examples in the net including multiple criteria..Here is what I wrote unsuccesfully:

Private Sub BtSalvarFrmII_Click()
CurrentDb.execute "UPDATE TableI"
Set FieldC = Forms!FrmII!FieldC.value AND Set FieldD = Forms!FrmII!FieldD.value WHERE FieldA = 1 AND FieldB = 2
Docmd.save
Docmd.close
End Sub

What would be the correct syntax?

View 7 Replies View Related

Pulling Contacts From Two Tables Into Third Contact Table

Apr 29, 2014

Ok, I have 3 tables. One lists a contact in conjunction with the branch of the company and the trips that contact takes. The second lists a contact in conjunction with the branch of the company and which team they work with (may work with many). The third should list their email address and their phone number. Is it possible to pull the contact name and branch of company from tables 1 and 2 into 3 automatically, such that all I have to input into table 3 is additional contact information? If that is possible, is it also possible to only pull each contact/branch of company pairing once (I don't want four entries for Joe Shmoe/Sales, even if he's taken 4 trips)?

Table 1
Branch of Company
Trip Dates
Trip Location
Contact

Sales
4/1/14-4/12/14
Chicago
Joe Shmoe

HR
6/2/13-6/4/13
New York
Jane Doe

Table 2
Branch of Company
Company Team
Contact

Sales
Blue Devils
John Deere

Sales
Jets
John Deere

Sales
Jets
Joe Shmoe

HR
Sharks
Jane Doe

Table 3Contact
Branch of Company
Email
Phone

Jane Doe
HR
jane.doe@company.com
800-555-1234

Joe Shmoe
Sales
joe.shmoe@company.com
800-555-1235

John Deere
Sales
john.deere@company.com
800-555-1236

View 4 Replies View Related

Status Bar Not Showing Field Description When Add Or Edit Data?

Apr 26, 2013

When editing a record in Access 2003, the status bar would show the value of each field's description from the table design grid. Is there a way to get Access 2010 to do the same?

View 1 Replies View Related

Getting Record Status From A History Table

Oct 22, 2007

Dear All,

I have a MAIN table which stores the most recent info of a record with
following details:

Unique_Ref_Num|Status|Dept
1 |6 | 1

and a second table called history which records changes in the main table

HistoryID | Status | DateStamp
1 | 1 | #22/10/2007 09:00#
1 | 2 | #22/10/2007 09:01#
2 | 1 | #22/10/2007 09:05#
2 | 2 | #22/10/2007 09:06#
1 | 2 | #22/10/2007 11:00#
2 | 3 | #22/10/2007 15:00#
1 | 3 | #22/10/2007 16:00#
2 | 2 | #22/10/2007 16:10#


Where Status 1 = Open, 2 = Allocated and 3 = Closed.
----------------------------------------------------------------------------------------------
I want to get the count of number of queries which are not closed
(outstanding) at any point in time.

Example: (with a time parameter)
Input | Result
22/10/2007 17:00 | 1
22/10/2007 16:05 | 0
22/10/2007 14:00 | 2

I want to achieve this with just 1 query (not by using one query within the
other) b,coz I want to further use this query from Excel VBA (write through
Excel VBA and not store the query within Access)

Any help will be greatly appreciated
--

Many Thanks
Baapi
:confused:

View 4 Replies View Related

Forms :: Cascading Combo Box - Cannot Choose Contact?

Jan 7, 2014

I have two combo boxes. One with the customer and one with the customer contact. These boxes seem to be working fine however, after you select the customer and then the customer contact box updates, it isn't allowing me to choose the contact. Nothing happens when you click.

View 7 Replies View Related

Queries :: Calls Table - Finding Last Contact Date

Aug 7, 2014

There are three tables. An [Action Register] table, a [Calls] table and a [tblContacts] table. The Contacts are common to both.

The Calls table records calls to customer by date

The Action Register table records issues that Customers send in by Open date.

I am trying to make a query where we see the latest date the customer was contacted regardless of which table.

I created two queries.

qryLastCallDate finds the max date from the Call table:

SELECT Max(Calls.CallDate) AS MaxOfCallDate, tblContacts.ContactName
FROM Calls LEFT JOIN tblContacts ON Calls.ContactID = tblContacts.ContactID
GROUP BY tblContacts.ContactName
ORDER BY Max(Calls.CallDate);

qryLastIssueDate finds the max date from the Action Register table:

SELECT Max([Action Register].Open) AS MaxOfOpen, tblContacts.ContactName
FROM tblContacts RIGHT JOIN [Action Register] ON tblContacts.ContactID = [Action Register].Contact
GROUP BY tblContacts.ContactName
ORDER BY Max([Action Register].Open);

The problem I am having is that if I use Left Join I can see all the records from the Calls table but not all from the Action Register table. And vis versa if I use Right Join. This is because sometimes we have calls but no issues in the Action Register table and sometimes issues with no calls.

This is my Left Join query using a Min Max Module I found here: [URL] ....

SELECT qryLastCallDate.ContactName, qryLastCallDate.MaxOfCallDate, qryLastIssueDate.MaxOfOpen, qryLastIssueDate.ContactName, DateValue(MaxOfList([MaxOfCallDate],[MaxOfOpen])) AS [Last Contact], ([Last Contact]+21) AS NextCall
FROM qryLastCallDate LEFT JOIN qryLastIssueDate ON qryLastCallDate.ContactName = qryLastIssueDate.ContactName;

How do I get to see ALL the records from both queries.

View 3 Replies View Related

Forms :: How To Change Status Of Item

May 6, 2015

I have set up a form that allows me to enter information on an item. This form is for initial entry, like an asset item. In this form I have a field for status of the item and the condition of the item.

Where I am having trouble is being able to bring the item up and change the status of the item if it is broke or damaged. I have the item as [label] and set as the primary key. and an item as [studentid] as a foreign key. I also would like to be able to query the different status'.

I am confident I can set queries up but I need to figure out how to recall the [Label] change the [status] and save it. The only other thing that I could hope for is to track then number of times the [status] was changed.

View 1 Replies View Related

Forms :: Copying Command Button Appearance Properties To Other Command Buttons

Dec 17, 2013

I am rewriting an old Access 2003 database in Access 2010. When creating new command buttons, the current theme gives them a default appearance. I need to apply this appearance to old command buttons. I know there is a way to select the default button and apply its properties to others quickly. I have done it before but didn't write the process down .

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved