#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 20
Default Curiosity

So just a thought. I am making an estimating program/spreasheet. Now there
can be one or more phases to a project and I was wondering is there anyway so
that when this workbook is opened to be asked for the amount of phases and
then automatically create that many copies of the master sheet and then add
their to totals to a totals sheet. Or is this far to crazy to be done
without years of computer programming.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7,247
Default Curiosity

Something like the following may do what you want:

Sub Auto_Open()
Dim N As Long
Dim M As Long
N = Application.InputBox(prompt:="Number Of Phases", Type:=1)
If N 0 Then
With ThisWorkbook.Worksheets
For M = 1 To N
.Item("Master").Copy after:=.Item(.Count)
.Item(.Count).Name = "Phase " & CStr(M)
Next M
End With
End If
End Sub


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting
www.cpearson.com
(email on the web site)

"Excluxe" wrote in message
...
So just a thought. I am making an estimating program/spreasheet. Now
there
can be one or more phases to a project and I was wondering is there anyway
so
that when this workbook is opened to be asked for the amount of phases and
then automatically create that many copies of the master sheet and then
add
their to totals to a totals sheet. Or is this far to crazy to be done
without years of computer programming.


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 20
Default Curiosity

So i think it might want to work something poped about macros and security
aslo i am new to this code part of excell so i really don't have a clue want
exactly to do with this formula. I entered it in the code part of excell
hence getting the thing about macros. The sheet I need to duplicate is HVAC
PRICING. I am assuming I need to place this in the formula but quite no
where.
Appreciate any help you can give me thanks.

P.S. Oh yeah and technical jargon just dumbed down a little is fine. I
have played with this stuff but not since I was 9-10 so I remember little if
anything. Thanks

"Chip Pearson" wrote:

Something like the following may do what you want:

Sub Auto_Open()
Dim N As Long
Dim M As Long
N = Application.InputBox(prompt:="Number Of Phases", Type:=1)
If N 0 Then
With ThisWorkbook.Worksheets
For M = 1 To N
.Item("Master").Copy after:=.Item(.Count)
.Item(.Count).Name = "Phase " & CStr(M)
Next M
End With
End If
End Sub


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting
www.cpearson.com
(email on the web site)

"Excluxe" wrote in message
...
So just a thought. I am making an estimating program/spreasheet. Now
there
can be one or more phases to a project and I was wondering is there anyway
so
that when this workbook is opened to be asked for the amount of phases and
then automatically create that many copies of the master sheet and then
add
their to totals to a totals sheet. Or is this far to crazy to be done
without years of computer programming.


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
Excel 12, er, 2007 - Semi-idle Curiosity Harlan Grove Excel Worksheet Functions 7 May 30th 06 10:33 AM
MegaFormula curiosity Sige Excel Worksheet Functions 2 March 2nd 06 04:54 PM
Public Curiosity BillCPA Excel Discussion (Misc queries) 1 December 5th 05 10:33 PM


All times are GMT +1. The time now is 09:54 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"