Puzzle...

Mar 1, 2007

i have this code:

If IsNull(rs![tblFltTotalJobsAE] Or rs![tblFltTotalJobsEI] Or rs![tblFltTotalJobsRC]) = False Then
a = a + rs![tblFltTotalJobsAE]
b = b + rs![tblFltTotalJobsEI]
c = b + rs![tblFltTotalJobsRC]
d = a + b + c


f("test2") = d

End If


the result of the abv code eg:
rs![tblFltTotalJobsAE] <- 2
rs![tblFltTotalJobsEI] <- 3
rs![tblFltTotalJobsEI] <- 4
f("test2") = 9 , the result will be 9 (correct!)

if any of the rs![ ] is a null,
rs![tblFltTotalJobsAE] <- 2
rs![tblFltTotalJobsEI] <-
rs![tblFltTotalJobsEI] <- 4
f("test2") = **empty data** , the result should be 6 but the textbox is blank.

why the abv code doesn't seems to add up records whenever any of the records is empty?

View Replies


ADVERTISEMENT

A Little Puzzle?

Nov 30, 2007

In the UK under certain circumstances you can use the Retail Margin VAT Scheme. There are several ways to apply this scheme, the first, the VAT is calculated on your Gross Profit and you apply this rate as your effective rate of VAT. The second, and the one I use, is per transaction, the amount of VAT you pay depends on the amount of profit received for each sale that the Retail Margin Scheme is applicable. The difference between the UK and some EU countries is the sales tax on art is a fixed but substantially reduced rate.

This worked all very well until Artist Royalties (AR) came along. The wizards at DAC's decided to follow the EU model and use a banded scale based upon the Euro Day Rate which may impact on the bands to calculate Artist Royalty. It would be easy if the sales staff quoted a price plus AR, oh no, they give inclusive prices, this price is binding as it has been accepted.

To calculate the AR you need to know the Profit but to calculate the Profit you need to know the AR. Two unknowns!

The sale is £75,000 inclusive of both VAT and Artist Royalty
The cost is £50,000.

The Euro Rate is 1.3962 based on 16th November 2007
The AR bands are €50,000 @ 4% and €200,000 @ 3%
Vat 17.5% is calculated on the Profit element only
Atist Royalty is exempt from VAT

How much is the Profit?
What is the Vat Payable?
What is the Amount of Artist Royalty due?

This is the link to the AR Calculator.

http://http://resale.dacs.org.uk/ARRCalculator.aspx

I found a way in Excel to work this out but it is less than elegant and to me using Excel is like surrendering.

Simon

View 2 Replies View Related

A97 Lookup Puzzle

Mar 9, 2005

A97. Briefly I've got a training database which I cobbled together from a MS sample dbase. It works fine except there is an intermittent problem.

I have a course management form with a combo box that looks up all courses attended by an employee and displays them in the subform.

On first opening the database and opening this form and selecting an employee from the combo, the subform displays all course records, not the ones filtered for the employee. If I then compact the database the form works correctly. It doesn't happen every time the dbase is opened. Does this behaviour ring any bells?

View 13 Replies View Related

Table Design Puzzle

Oct 7, 2005

Hi
I have been struggling for quite a wee while thinking the design of a part of my Database, it is maybe not that complex but seems quite difficult to me... :o
I have different ASSEMBLIES made of differents PARTS (Bodies, Straps, Hinge, Screws...) and most of them are built on the same models but there is quite a few odd ones.
Most assemblies are made of 1 Body, 2 Straps, 2 Screws and 2 Hinge pins
but some can be made of 1 Bodies, 2Screws and 2Hinge pins only
or 1 Bodies and 4 Screws
there is quite a few configuration and some can be made of really unusual parts that are only gonna be used once or twice.

There is different models for each part So I have created TblStraps, TbleScrews, TblHinge..., Tbl Miscellaneous (regrouping all the odd ones)

This is where I am getting confused because I want to make it easy for the user to fill in a new assembly detail.

Each assembly is defined by is body,

and I could use a query to show the number of parts for each AssemblyModel.
Should I have a table for each assembly model as shown below:

TblModel1:............................TblModel2:.. ...........................................
BodyId (Primary).....................BodyId (Primary)....................................
StrapId (linked to TblSrap)........ScrewId (Linked to TblScrew)..................
ScrewId (Linked to TblScrew)....HingeId (Linked to TblHinge)....................
HingeId (Linked to TblHinge)

and a table for the miscelaneous models who is going to have quite a few fields because some of those models can have 1 or 2 types of srews and Hinge pins and up to 8 more parts, lots of the Records will have blank fields as well. :confused:
Ohhhh, I don't know where to start, I am confused and needs some advice, I feel bad to beg but I am really desperate :(

View 11 Replies View Related

One Form To Another Form Puzzle ???

Feb 22, 2005

Wonder if anyone could help.......

I have an form for creating a new order and this is accompanied by another form which inputs each individual item for that order. For example order number 25 might be an order for item 382 and item 196.

It would be handy if when I open the items form that I don't have to manually enter the order number (primary key of orders table) swo that each item is linked to that particualr order. I tried making the default value of the order number (which is also foreign key on items table) match whatever itr was on the open orders form but the whole database didn't like that and wouldn't save the records I was trying to enter.

So basically any ideas how to make a number (the unique Primary Key) from one opened form appear automatically in another opened form??

It's got me baffled!! Many thanks!!

Paul.

View 1 Replies View Related







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