Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 87
Default Create Summary then export

I have a table of columns, some titles, others costs.

Think I may need to email the files to someone to better demonstrate it.

Is it possible to create a macro button that will create an additional sheet
that summarises all the headings in column 1 and sums their respective costs

Then another button on the new sheet that will export the data into a
template in their correct columns.

I would greatly appreciate anyone's help


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 130
Default Create Summary then export

Make sure the columns have headers and create a Pivot Table? Or do you mean
something else?

"Freddy" wrote:

I have a table of columns, some titles, others costs.

Think I may need to email the files to someone to better demonstrate it.

Is it possible to create a macro button that will create an additional sheet
that summarises all the headings in column 1 and sums their respective costs

Then another button on the new sheet that will export the data into a
template in their correct columns.

I would greatly appreciate anyone's help


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 87
Default Create Summary then export

Yeah I mean something that is automated.

I am trying to build a template that will be sent out to various people all
year round for population.

The macro buttons are to speed things up for them as they seem incapable of
doing anything themselves.

"PaulW" wrote:

Make sure the columns have headers and create a Pivot Table? Or do you mean
something else?

"Freddy" wrote:

I have a table of columns, some titles, others costs.

Think I may need to email the files to someone to better demonstrate it.

Is it possible to create a macro button that will create an additional sheet
that summarises all the headings in column 1 and sums their respective costs

Then another button on the new sheet that will export the data into a
template in their correct columns.

I would greatly appreciate anyone's help


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 130
Default Create Summary then export

Off the top of my head, something like this?

sub create_totals()
dim i,n,x as integer

i = 2

do until sheets("Sheet1").cells(i,1) = ""

n = 2
x = 1

do until sheets("Sheet2").cells(n,2) = ""
if sheets("Sheet2").cells(n,2) = Sheets("Sheet1").cells(i,1)
then x = n
n = n + 1
n = n + 1

if x = 1 then x = n
sheets("sheet2").cells(x,2) = sheets("Sheet1").cells(i,1)
sheets("Sheet2").cells(x,3) = sheets("Sheet2").cells(x,3) +
sheets("Sheet1").cells(i,2)

i = i + 1

loop

end sub

That will look down column A of "Sheet1" and add all the names to column B
of "Sheet2" and in column C of "Sheet2" add in whatever is in column B of
"Sheet1" so

Job1 100
Job2 50
Job1 60
Job3 15
Job2 70

will end up as

Job1 160
Job2 120
Job3 15

"Freddy" wrote:

Yeah I mean something that is automated.

I am trying to build a template that will be sent out to various people all
year round for population.

The macro buttons are to speed things up for them as they seem incapable of
doing anything themselves.

"PaulW" wrote:

Make sure the columns have headers and create a Pivot Table? Or do you mean
something else?

"Freddy" wrote:

I have a table of columns, some titles, others costs.

Think I may need to email the files to someone to better demonstrate it.

Is it possible to create a macro button that will create an additional sheet
that summarises all the headings in column 1 and sums their respective costs

Then another button on the new sheet that will export the data into a
template in their correct columns.

I would greatly appreciate anyone's help


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
create a summary record vcff Excel Discussion (Misc queries) 6 August 29th 08 03:14 AM
Create summary WB GregR Excel Programming 2 June 8th 06 03:56 PM
Create Summary WB GregR Excel Programming 2 April 25th 06 07:39 PM
Userform then export to summary to spreadsheet w. ability to edit Adam Excel Programming 1 March 2nd 05 10:08 PM


All times are GMT +1. The time now is 04:17 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"