Welcome to the { mindfrost82.com } forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact us.

Go Back   { mindfrost82.com } > Gadget Corner > Tech Newsgroups > Microsoft > MS Office > Access

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 08-12-2008, 08:16 AM
Odeh Naber
 
Posts: n/a
Dividing Two Running Sums on a Report

Greetings all!

I have a report in which I have seven columns:

Column 1: Day number (i.e. Day 1, Day 2, Day 3, etc.).
Column 2: SalesCost for that day.
Column 3: SalesCost to-date (running sum of SalesCost)
Column 4: SalesRevenue for that day.
Column 5: SalesRevenue to-date (running sum of SalesRevenue)
Column 6: CostRatio for that day.
Column 7: CostRatio to-date (value from Column 3 divided by value from
Column 5)

The problem is with Column 7 - I cannot seem to be able to divide the
two numbers and give the result as a percentage. Here is some sample
data to help illustrate what I am trying to achieve - it is the last
column I cannot get to work - RatioTo-Date:

DAY N. CostToday CostTo-Date RevenueToday RevenueTo-
Date RatioToday RatioTo-Date
1 10 10
100 100 10%
10%
2 20 30
50 150 40%
20%
3 15 45
20 170 75%
26,47%

Thank you!

Reply With Quote
  #2 (permalink)  
Old 08-12-2008, 11:07 AM
=?Utf-8?B?S2VuIFNoZXJpZGFu?=
 
Posts: n/a
RE: Dividing Two Running Sums on a Report

Leave the ControlSource property of the Column 7 control blank and in the
detail section's Print event procedure assign a value to the control, e.g.

Me.txtCostRatioTodate = _
Format(Me.txtSalesCostTodate/Me.txtSalesRevenueTodate, "Percent")

Ken Sheridan
Stafford, England

"Odeh Naber" wrote:

> Greetings all!
>
> I have a report in which I have seven columns:
>
> Column 1: Day number (i.e. Day 1, Day 2, Day 3, etc.).
> Column 2: SalesCost for that day.
> Column 3: SalesCost to-date (running sum of SalesCost)
> Column 4: SalesRevenue for that day.
> Column 5: SalesRevenue to-date (running sum of SalesRevenue)
> Column 6: CostRatio for that day.
> Column 7: CostRatio to-date (value from Column 3 divided by value from
> Column 5)
>
> The problem is with Column 7 - I cannot seem to be able to divide the
> two numbers and give the result as a percentage. Here is some sample
> data to help illustrate what I am trying to achieve - it is the last
> column I cannot get to work - RatioTo-Date:
>
> DAY N. CostToday CostTo-Date RevenueToday RevenueTo-
> Date RatioToday RatioTo-Date
> 1 10 10
> 100 100 10%
> 10%
> 2 20 30
> 50 150 40%
> 20%
> 3 15 45
> 20 170 75%
> 26,47%
>
> Thank you!
>
>


Reply With Quote
  #3 (permalink)  
Old 08-12-2008, 04:46 PM
Marshall Barton
 
Posts: n/a
Re: Dividing Two Running Sums on a Report

Odeh Naber wrote:
>I have a report in which I have seven columns:
>
>Column 1: Day number (i.e. Day 1, Day 2, Day 3, etc.).
>Column 2: SalesCost for that day.
>Column 3: SalesCost to-date (running sum of SalesCost)
>Column 4: SalesRevenue for that day.
>Column 5: SalesRevenue to-date (running sum of SalesRevenue)
>Column 6: CostRatio for that day.
>Column 7: CostRatio to-date (value from Column 3 divided by value from
>Column 5)
>
>The problem is with Column 7 - I cannot seem to be able to divide the
>two numbers and give the result as a percentage. Here is some sample
>data to help illustrate what I am trying to achieve - it is the last
>column I cannot get to work - RatioTo-Date:
>
>DAY N. CostToday CostTo-Date RevenueToday RevenueTo-
>Date RatioToday RatioTo-Date
>1 10 10
>100 100 10%
>10%
>2 20 30
>50 150 40%
>20%
>3 15 45
>20 170 75%
>26,47%



Try setting the Ratio to Date text box's Format property to
Percent or 0.0%

--
Marsh
MVP [MS Access]
Reply With Quote
Reply

  { mindfrost82.com } > Gadget Corner > Tech Newsgroups > Microsoft > MS Office > Access


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 04:12 PM.


Powered by vBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0 ©2007, Crawlability, Inc.
© 1999-2008 mindfrost82.com v11.0


Sponsors:
Loans | Loans | Online Loans | Gas Suppliers | Buy Anything On eBay



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114