ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Worksheet Question (https://www.excelbanter.com/excel-programming/344816-worksheet-question.html)

Greg B[_6_]

Worksheet Question
 
I have a workbook that is volitile and I would like for a macro to look up
value j13 and copy each one onto a worksheet. I need it to be volitle so I
dont need to change it each time a new person is put on the database.

Any ideas would be great

Thanks

Greg



Barb Reinhardt

Worksheet Question
 
How many worksheets do you have and where do you want to copy it?

"Greg B" wrote in message
...
I have a workbook that is volitile and I would like for a macro to look up
value j13 and copy each one onto a worksheet. I need it to be volitle so I
dont need to change it each time a new person is put on the database.

Any ideas would be great

Thanks

Greg




Greg B[_6_]

Worksheet Question
 
Thats the thing I have not a limit of worksheets. Here is the idea I have.

The two cells i need from all sheets are

"b3" and "j15"

the thing is when I have a new person I have an automatic page setup where I
get their details and a new worksheet is added. I just want to collect this
information from these sheets and place them on a worksheet called "details"

Hope this is a little bit more helpful

Thanks
Greg
"Barb Reinhardt" wrote in message
...
How many worksheets do you have and where do you want to copy it?

"Greg B" wrote in message
...
I have a workbook that is volitile and I would like for a macro to look up
value j13 and copy each one onto a worksheet. I need it to be volitle so
I dont need to change it each time a new person is put on the database.

Any ideas would be great

Thanks

Greg






Bob Phillips[_6_]

Worksheet Question
 
Greg,

There are a number of difficulties here.

The obvious thing is to trap the NewSheet event and code into there, but the
two cells will not be populated by then.

Then there is the possibility that you will rename the default name
allocated to the sheet.

Does the details sheet have to know the source of the data?

Could the code prompt and load those two values?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Greg B" wrote in message
...
Thats the thing I have not a limit of worksheets. Here is the idea I

have.

The two cells i need from all sheets are

"b3" and "j15"

the thing is when I have a new person I have an automatic page setup where

I
get their details and a new worksheet is added. I just want to collect

this
information from these sheets and place them on a worksheet called

"details"

Hope this is a little bit more helpful

Thanks
Greg
"Barb Reinhardt" wrote in message
...
How many worksheets do you have and where do you want to copy it?

"Greg B" wrote in message
...
I have a workbook that is volitile and I would like for a macro to look

up
value j13 and copy each one onto a worksheet. I need it to be volitle

so
I dont need to change it each time a new person is put on the database.

Any ideas would be great

Thanks

Greg








Greg B[_6_]

Worksheet Question
 
I never thought of That I have code to add the sheet I could just extend it
a little bit more. Thanks for that
Just was too blind to see it that way.
\
Thanks
Greg
"Bob Phillips" wrote in message
...
Greg,

There are a number of difficulties here.

The obvious thing is to trap the NewSheet event and code into there, but
the
two cells will not be populated by then.

Then there is the possibility that you will rename the default name
allocated to the sheet.

Does the details sheet have to know the source of the data?

Could the code prompt and load those two values?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Greg B" wrote in message
...
Thats the thing I have not a limit of worksheets. Here is the idea I

have.

The two cells i need from all sheets are

"b3" and "j15"

the thing is when I have a new person I have an automatic page setup
where

I
get their details and a new worksheet is added. I just want to collect

this
information from these sheets and place them on a worksheet called

"details"

Hope this is a little bit more helpful

Thanks
Greg
"Barb Reinhardt" wrote in message
...
How many worksheets do you have and where do you want to copy it?

"Greg B" wrote in message
...
I have a workbook that is volitile and I would like for a macro to look

up
value j13 and copy each one onto a worksheet. I need it to be volitle

so
I dont need to change it each time a new person is put on the database.

Any ideas would be great

Thanks

Greg










Tom Ogilvy

Worksheet Question
 
Dim rw as Long, sStr as String
Dim sh as Worksheet
Worksheets("Details").Cells.ClearContents
rw = 1
for each sh in Worksheets
sStr = lcase(sh.Name)
if sStr < "details" and sStr < "setup" then
rw = rw + 1
With Worksheets("Details")
.cells(rw,1).Value = sh.Range("B3")
.Cells(rw,2).Value = sh.Range("J15")
End with
end if
Next

--
Regards,
Tom Ogilvy


"Greg B" wrote in message
...
Thats the thing I have not a limit of worksheets. Here is the idea I

have.

The two cells i need from all sheets are

"b3" and "j15"

the thing is when I have a new person I have an automatic page setup where

I
get their details and a new worksheet is added. I just want to collect

this
information from these sheets and place them on a worksheet called

"details"

Hope this is a little bit more helpful

Thanks
Greg
"Barb Reinhardt" wrote in message
...
How many worksheets do you have and where do you want to copy it?

"Greg B" wrote in message
...
I have a workbook that is volitile and I would like for a macro to look

up
value j13 and copy each one onto a worksheet. I need it to be volitle

so
I dont need to change it each time a new person is put on the database.

Any ideas would be great

Thanks

Greg








Greg B[_6_]

Worksheet Question
 
Thankyou Tom much easier than me trying to get it running. Works Great I was
definately going in the wrong direction

Thankyou Again

Greg
"Tom Ogilvy" wrote in message
...
Dim rw as Long, sStr as String
Dim sh as Worksheet
Worksheets("Details").Cells.ClearContents
rw = 1
for each sh in Worksheets
sStr = lcase(sh.Name)
if sStr < "details" and sStr < "setup" then
rw = rw + 1
With Worksheets("Details")
.cells(rw,1).Value = sh.Range("B3")
.Cells(rw,2).Value = sh.Range("J15")
End with
end if
Next

--
Regards,
Tom Ogilvy


"Greg B" wrote in message
...
Thats the thing I have not a limit of worksheets. Here is the idea I

have.

The two cells i need from all sheets are

"b3" and "j15"

the thing is when I have a new person I have an automatic page setup
where

I
get their details and a new worksheet is added. I just want to collect

this
information from these sheets and place them on a worksheet called

"details"

Hope this is a little bit more helpful

Thanks
Greg
"Barb Reinhardt" wrote in message
...
How many worksheets do you have and where do you want to copy it?

"Greg B" wrote in message
...
I have a workbook that is volitile and I would like for a macro to look

up
value j13 and copy each one onto a worksheet. I need it to be volitle

so
I dont need to change it each time a new person is put on the database.

Any ideas would be great

Thanks

Greg











All times are GMT +1. The time now is 05:14 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com