Why Doesnt This Work

Oct 26, 2005

I have to tables.
one dummy and one main. The have the same fields.
the dummy is filled by a form.
i want to see where they are diffrent. But the query shows all the dummys records. I just want it to show the record that doesnt exists in the main table.


SELECT DISTINCT AttendenceDummy.MeetingCode, AttendenceDummy.EmployeeCode
FROM Attendance INNER JOIN AttendenceDummy ON Attendance.MeetingCode = AttendenceDummy.MeetingCode
WHERE (((AttendenceDummy.EmployeeCode)<>Exists (select Attendance.EmployeeCode from Attendance )));

View Replies


ADVERTISEMENT

Work In One PC And Doesnt In Other!

Jun 9, 2005

I have a form with two textbox, when I type something in textbox, the second textbox is filled with database query "SELECT MAX...", this works in one PC but doesnt work in other...

Why ?

all PCs is Windows XP with Office 97 and 2000.

thx

View 1 Replies View Related

Onclick Even Doesnt Work In Tab Controls?

May 2, 2005

I have a tab control with buttons nested inside of it calling to open a form - but when I go to test the buttons, they do not open the form that the wizard selected. I get the error message: invalid outside procedure. If i copy the button into the main portion of the form outside of the tab control - it seems to work. Any ideas would help. Thanks again!

View 1 Replies View Related

General Q - Code And Why It Doesnt Work All Of The Time

Feb 6, 2008

I am wondering why access does not follow its own code all of the time?

For example I have passworded forms following the tutorial on the Microsoft site. It mostly works when the participants fills in the wrong password we will get an error message box and when they cancel the password dialogue box it wont let the person enter the form - but not all the time. Sometimes if you press cancel it still opens the form anyway (without requiring the correct password).

This is similar with the module that I put in to prevent people from using the mousewheel to leave their record etc. Most times it works but sometimes it just isnt called on form load.

There is nothing wrong with any of these codes and when they work they work well but I cant seem to rely on access to do what is supposed to?

View 1 Replies View Related

Why RecordsetClone.AddNew Doesnt Work Correctly?

Jun 24, 2007

I search a record with values that I am taken from form1 .
If i found the record i show it on the form2 else I add a new record to table with values that i am taken them form form.
this is my code:
Code: Dim stDocName As String Dim stLinkCriteria As String stDocName = "mainhazineh_m" DoCmd.OpenForm stDocName, , , stLinkCriteria Form_mainhazineh_m.mahp.Value = Form_mainform_m.Combo2.Value Form_mainhazineh_m.salp.Value = Form_mainform_m.Combo0.Value Form_mainhazineh_m.RecordsetClone.findfirst "[salp]= " & Form_mainform_m.Combo0.Value & " And [mahp]= " & Form_mainform_m.Combo2.Value & " And [shahrp]= '" & Form_mainform_m.Combo12.Value & "'" If Form_mainhazineh_m.RecordsetClone.RecordCount <> 0 And Form_mainhazineh_m.RecordsetClone.NoMatch = False Then Form_mainhazineh_m.RecordsetClone.edit Form_mainhazineh_m.RecordSelectors = True Form_mainhazineh_m.Bookmark = Form_mainhazineh_m.RecordsetClone.Bookmark Form_mainhazineh_m.RecordsetClone.Update Else Form_mainhazineh_m.RecordsetClone.AddNew Form_mainhazineh_m.mahp.Value = Form_mainform_m.Combo2.Value Form_mainhazineh_m.salp.Value = Form_mainform_m.Combo0.Value Form_mainhazineh_m.shahrp.Value = Form_mainform_m.Combo12.Value Form_mainhazineh_m.RecordsetClone.Update Form_mainhazineh_m.Bookmark = Form_mainhazineh_m.RecordsetClone.LastModified End If
my problem is that when i must add new record to db, it only change the first record of table with values that i make them red then add a new record that all fields of it is empty.
can anyone help me ?

View 1 Replies View Related

It Just Doesnt Add Up !!

Apr 16, 2007

Hi folks,

I am struggling here with something that I am sure is simple but for the life of me can’t crack it. :confused:

I have a table and a subsequent query which shows golfers lowest score on each hole throughout the season. I want to add up the total of each hole by individual membership number and display it as a total for each row

I have attached a sample db with a sample query called 'eclectic latest working'. If you look at this query, I want to have the total of every row.

If you look at my form, the total I have at the moment isn’t correct, it is adding up the whole columns (I think)

If anyone can point me in the right direction, I would be most grateful !!

Thanks for looking

Regards
Steve

View 2 Replies View Related

Works - Now It Doesnt

Dec 9, 2005

What would trigger an error to occur if there has been no changes to a DB.

My error # is 2427 (You entered an expression that has no value).

This error occurs when I click on a command button to open a report. When I debug, it sends me to an IF statement that I have loaded in the On Format of the report.

This worked perfectly fine before - the If statement is simple, if a value is true, then it changes a box to bold and if the value is false, the box in the report remains the same weight.

I am not understanding why it is saying that I have entered an expression with no value when the IF statement reads both the true and the false of a chkbox and adjusts the box accordingly.

Can someone explain why this is occuring? Im litteraly stuck.

View 14 Replies View Related

Why Doesnt Anyone Know About The Calendar?

Jul 31, 2005

I just posted something about the calendar2k. Does anyone know where I can find that calendar add on? I know there are others out there but this one was awesome. It was 2 little buttons that dealt with start date and end date. You would just change the OnClick, so when the person clicked it or double-clicked it, it would enter the date in the correct control for you.

View 3 Replies View Related

Query Doesnt Pick Up All Records, Please Help!

Feb 19, 2007

I have a query which picks picks up all records from a table. One field however seems to randomly not pick up data from certain records even though the data is in the table.

This has been puzzling me for some time now, does anyone have any ideas / suggestions?

View 2 Replies View Related

Object Doesnt Support This Property....

Dec 1, 2005

This error appears when a preview or print button is used. The form has been opened with this.....

DoCmd.OpenForm stDocName, , , , acFormAdd, acWindowNormal

But when I try to preview it gets the error.......
"Object doesnt support this property........."

Same error occurs when the form is opened with.....
DoCmd.OpenForm stDocName, , , , acFormReadOnly, acWindowNormal, stLinkCriteria

The preview button is this.........

Private Sub cmdPreviewRptWO_Click()
On Error GoTo Err_cmdPreviewRptWO_Click

Dim stDocName As String
stDocName = "rptWorkOrderCurrent"

DoCmd.RunCommand acCmdSaveRecord
DoCmd.OpenReport stDocName, acPreview

Exit_cmdPreviewRptWO_Click:
Exit Sub


The really strange thing is I have 2 forms both coding the same..... One doesnt give the error!!

I think the error occurs when it is trying to save before previewing...But it has to save to view the report.

Anyone have the answer?? :confused:

View 8 Replies View Related

#div/0! Error...doesnt Make Sense..

May 26, 2006

I am trying to track down why i get a #div/0 error...

i have a form that is a sales invoice. It also has a subform with in where the items being sold are entered.

in the subform i have on the footer a Sum([Selling price])
so that i have a total in the subform..

then i pull that total into the mainform using =[subform2].Form![TOTAL]

it all works great.... but if some one buys multiple items and one price is left at 0.... i get that div/0 displayed on my totals..??

see the attached image for a visual of what i am talking about...

http://www.access-programmers.co.uk/forums/attachment.php?attachmentid=13727&stc=1&d=1148661307

View 5 Replies View Related

Append If Record Doesnt Exist, Else Update

Feb 19, 2008

I have a table that is filled based on selections that a user makes in combo boxes on a form. I am having trouble trying to figure out the best way to prevent duplicates from being inserted in the table when I do the append query part.

Since the table is filled based on the various selections the user makes I dont have a primary key or unique field.

Can someone help me figure out the best way to do this append/update queries to prevent duplicates. Also if you have a strategy for setting up some sort of unique or primary key for fields that could all be the same yet in the table only 1 record will show, no duplicates.

View 1 Replies View Related

All Data Form Doesnt Display Records

Jun 16, 2005

I am creating a database to store employee data, its divided among 3 tables, storing :Employment data,Personal data and Payment data, the 3 tables are related using a 1-1 relationship between the common field ID in each. I`ve created a form through which all data needed for the fields in each table is entered,while entering the data its possible to view the records, however, when i close the form and check the tables, the data is going to the respective tables,however,after i open the table and then go back to the form, its not possible to view the records in the form, they`re still in the table but i cant view them through the form, i can still add new records using the form, but i`m not seeing the old records anymore. Anyone, help?

View 5 Replies View Related

All Data Form Doesnt Display Records

Jun 16, 2005

I am creating a database to store employee data, its divided among 3 tables, storing :Employment data,Personal data and Payment data, the 3 tables are related using a 1-1 relationship between the common field ID in each. I`ve created a form through which all data needed for the fields in each table is entered,while entering the data its possible to view the records, however, when i close the form and check the tables, the data is going to the respective tables,however,after i open the table and then go back to the form, its not possible to view the records in the form, they`re still in the table but i cant view them through the form, i can still add new records using the form, but i`m not seeing the old records anymore. Anyone, help?

View 1 Replies View Related

Help! Database Doesnt Open And Comes Up With Error Message About Compacting And DAO!

Jan 23, 2008

hi,

the following error message appears when trying to access my database. I can't seem to get into it at all, not even by trying to import the data tables over into a new database. the following message appears:

"The database has been converted from a prior version of Microsoft Access by using the DAO Compact Database method instead of Convert Database Command on the Tools Menu. This has left the database in a partially converted state. If you have a copy of the original format use the convert Database on the Tools menu to convert it. If the original database is no longer available, create a new database and import your tables and queries to preserve your data. Your other database applications can't be recorded''..

the copy and the back up wont let me in either, this just suddenly happened.

Please help!

Thanks in advance

View 2 Replies View Related

Making A Look-Up Form Work The Way I Want It To Work!

Feb 27, 2006

We are creating a simple database to maintain driver license information for faculty, staff, and students who use cars from the university’s motor pool.

To do this, I have created two tables: tblDRIVER and tblLICENSE.

The fields in tblDRIVER are:
pkfDriverIndex
strLastName
strFirstName
strInitial
strAddress1
strAddress2
strCity
strState
strZIP
datBirthDate

The fields in tblLICENSE are:
pkfUpdateIndex
fkfDriverIndex
datDateUpdated
strState
strLicNumber
datExpirationDate
ynViolations
ynActive

Information about the driver is stored in tblDRIVER and the driver’s license information is stored in tblLICENSE. Periodically, we run a report that identifies drivers whose licenses are due to expire within a certain number of days. All this works fine.

My problem is that I am trying to create a lookup form that will load from a data entry form that will permit the Motor Pool Clerk to look up a driver by name and review the licensing information (which appears as a subform).

All this sort of works- I am using a combo box (based on a query) to look up a driver’s last name (which it does) and to populate all the driver’s information on the look-up form (including license information in a subform). Currently, the combo box locates the driver (including the unique index, last, and first names), and populates the form with first and last name but the rest of the information is not displayed on the look up form. Worse still, sometimes one driver’s last name matches up with the first name of the next driver listed in the table! This seems to happen only if a look up is attempted more than once. What gives.

Thanks for the help.

View 9 Replies View Related

I Can't Get This To Work IIf Function Work For Me

Sep 10, 2007

I have an expression in one column of my query and It keeps returning a negative result and there are no negative numbers in the source data. Can anyone help. I just want to sum the sums the two IIf expressions, but its not working. Thanks


Other Qty: Sum(IIf([QSum]![ACCOUNT]=2 And [QSum]![ICUNIT]=95 And [QSum]![UNITS]="ITEM(S)",[QSum]![QUANT],Null)) Or Sum(IIf([QSum]![ACCOUNT]=2 And [QSum]![ICUNIT]=100 And [QSum]![UNITS]="ITEM(S)",[QSum]![QUANT],Null))

View 4 Replies View Related

Cannot Get It To Work.

May 30, 2006

I’m a newbie to Access, I have done some simple things but I now have to do something that is out of my league.

I work in an engineering company and I'm trying to make a database that the engineers can select a specification quickly, a specification or spec is like a table. Things like materials, ratings, pipe Schedule, etc are stored in it. The spec says how strong a pipe will be.

When selecting a spec you have to look at the service (what the pipe is caring, eg high pressure steam, or low pressure water). Services also store things like Design Temperature and Design Pressure.

You are giving the Service, and you have to select a spec that will be able to handle the Design pressures. To do this you compare the Design pressure to the Maximum allowable Pipe pressure (it is calculated at the join (flange) as this is the weakest point).

One other pike of information is the Tables that have the Maximum allowable Pressure. To find the Maximum allowable Pressure, you need to know the Material, Rating and the Design Temperature. Each material has its own table.

If you have a look at the attached file then in tables, SPec has Spec ID (Spec) which is Primary Key. Flange Material (FlangeMat) and Flange Rating (FlangeRating).

The Flange Material should take you to another table, FlangeMat. This table is used to get you to the correct Maximum allowable Pressure table.

There are 2 Maximum allowable Pressure Tables, TABLE_211 and TABLE 212. Here the rest of the information from the Spec is needed (Flange Rating (these are the field names with 150, 300, 1500, etc numbers)). And also the Design Temperature is needed of the service.

Then it looks up the Maximum allowable Pressure from the Table and displays it. I was thinking a form.

Also the design Pressure needs to be displayed so the engineer can compare the two.

So for the form, there will need to be a drop down that has the Service, A drop down that has the Spec, and the two values, the Design Pressure and the Maximum allowable pressure.

All I have done is shown on the file, I started to play around with the Relationships and tried to create a Form but I could not get it to work so. I deleted it and left it with just the tables. If possible can someone please help me, maybe even get my file to work and the post the working one, I will then be able to understand it.

View 2 Replies View Related

Will This Work?

Jul 23, 2006

The company I work for uses A97 throughout. Although on my laptop I have Access 2003. I want to design my inventory control database using A2003 not 97 for obvious reasons. I know A97 users cannot open a Acess 2003 db.My Q is: If I created a A2003 db and also built some data access pages within the database and placed it on my server, could users view/add/edit records in the db via these pages using their web browsers? This would only be required across our small network of less than 10 users.Any advise welcome. Even just a YES or NO would help Many thanks.

View 4 Replies View Related

Why Does This Not Work

Oct 6, 2006

Can anyone look at this database at let me know why it is not working

plse
Stuart

View 7 Replies View Related

Getting The % Work Done

Dec 8, 2006

Hi All,

I need to create some conditional formatting on a field that will change the colour depending on how much money has been spent

I have MaxBilling As the Field I want to attach the condition formatting too which can be a user entered value or system updated depending on other things.

The Current worked costs total field Is Called Text119.

when a project starts The Cost will be 0 so I don't intend to assign a colour there.

when the Costs get to 50% of MaxBilling I would like to change the colour to Green

70% Chances to yellow
90% Would change to Dark Red

I can do most things but %'s and me don't mix well LOL

Any help would be much appreciated

thanks

mick

View 3 Replies View Related

How To Work Out Hrs

May 11, 2006

hey there kinda new to access...

how would i work out the amount of hrs worked?
e.g

time start at 8.00am, time finish at 5.00pm

how would i get to say 9hrs?

View 5 Replies View Related

Qry Work In One Db But Not Another

Dec 7, 2006

I have two database which are very similar. They both use the same back end table. I have a query that I developed in one db and it works correctly there. However, when I import it into the other db, I get the Ambiguous Outer Joins message. I've tried copying the SQL from one and pasting it into the other and that didn't help. I've checked the table used and they are all properly linked in the second db. Any ideas about what could be going on?

View 4 Replies View Related

Cant Get 'Like' To Work

Apr 4, 2007

I have created a query thats initiated by a command button from a form and one of the criteria for the query is a 'Like' command.

On the form, various option buttons and combi-boxes determine the search criteria and put it into a hidden textbox. Then, the query is run based on the contents of that hidden textbox using 'Like'.

However, I cant seem to get the 'Like' command to work with the contents of the hidden [forms]![frmSearch].[txtSearchcriteria] field.

Do I need to edit the VB code on the form to format the text to include the Like '* prefix and *' suffix, or should my search box remain basic text and have the Like command in the query ??

I seem to have tried loads of variations incorporating the various components of the Like command (the asterisks, single quote marks and even the Like command itself) on either the Form field or query but nothing seems to work. Anyone have any ideas ??

Thanks chaps.

View 2 Replies View Related

Why Does It Not Work?

May 30, 2006

The on click event, for a Report, has the following:

Sub DateEntry()

Dim Start_Date As Date
Dim End_Date As Date

Start_Date = InputBox("Enter Start Date mm/dd/yyyy")
End_Date = InputBox("Enter End Date mm/dd/yyyy")

End Sub

This works fine and allows for Input. I added the sub below, but it does not work and the report opens:

Sub CheckEntry()

If Start_Date Is Null Then
MsgBox "No Date was Entered"
DoCmd.Close acReport, "Summary Action Report"
Exit Sub
End If


If End_Date Is Null Then
MsgBox "No Date was Entered"
DoCmd.Close acReport, "Summary Action Report"
End If
End Sub

View 5 Replies View Related

Dlookup Should Work?

Aug 5, 2005

I thought I understood Dlookup – but I am not able to make it work!

Here’s my scenario:

tbl_Details (GroupID, and other misc fields)
tbl_GroupList (AutoKey, GroupID, GroupName)
rpt_Report (GroupID, and other misc fields)

I would like my report to show the GroupName instead of GroupID (Data is entered as GroupID – hence, I created the look-up table “tbl_GroupList.”

I created a text box on my report:

=DLookup(“[GroupName]”,”[tbl_GroupList]”,”[GroupID] = Reports![rpt_Report]![GroupID]

I think my syntax is correct – I just can’t figure out why it won’t work. Do I need to link the tables?

I even tried DLookup in a query (changing the above code to fit the query fields) and can’t seem to make it work. Please help!

PS -- I don't think it matters, but I am trying to do this in a sub report.

View 3 Replies View Related







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