PC Review


Reply
Thread Tools Rate Thread

dates linked to data

 
 
Chersie
Guest
Posts: n/a
 
      9th Apr 2008
I have worksheet one set up as a form to gather information. I have twelve
consecutive worksheets for the months of the year.

I would like to link the data from sheet1 to the appropriate month the data
is for. I am not sure how to do this.

I want all input data from January 1st to January 31st from the form to go
to the worksheet January, February 1st to February 29th to go to worksheet
February, etc.

How can I do this?

Thanks in advance for your help!!!
 
Reply With Quote
 
 
 
 
Max
Guest
Posts: n/a
 
      9th Apr 2008
One formulas play which delivers it automatically into respective MthYr
sheets, with lines auto-sorted in chrono order as well ..

Illustrated in this sample:
http://www.freefilehosting.net/download/3f3bc
AutoCopy Data By MthYr To Resp Sheet.xls

In sheet: x (the "master")
Assume data in cols A to C, from row2 down,
with the key col = col A (Dates, containing real dates)

List as *text* in K1 across: Jan08, Feb08, Mar08, etc (in any order)
Put in K2:
=IF($A2="","",IF(TEXT($A2,"mmmyy")=K$1,$A2+ROW()/10^10,""))
Copy K2 across as far as required, then fill down to cover the max expected
extent of source data

Click Insert > Name > Define
Put under "Names in workbook:": WSN
Put in the "Refers to:" box:
=MID(CELL("Filename",INDIRECT("A1")),FIND("]",CELL("Filename",INDIRECT("A1")
))+1,32)
Click OK

The above defines WSN as a name we can use to refer to the sheetname in
formulas. It will auto-extract the sheetname implicitly. Technique came from
a post by Harlan.

In a new sheet named: Jan08
With the same col headers pasted into A1:C1

Put in A2:
=IF(ISERROR(SMALL(OFFSET(x!$J:$J,,MATCH(WSN,x!$K$1:$IV$1,0)),ROWS($1:1))),"",INDEX(x!A:A,MATCH(SMALL(OFFSET(x!$J:$J,,MATCH(WSN,x!$K$1:$IV$1,0)),ROWS($1:1)),OFFSET(x!$J:$J,,MATCH(WSN,x!$K$1:$IV$1,0)),0)))
Copy A2 across to C2, fill down to say, C25 (copy down by the smallest
possible range sufficient to cover the max expected extent for any single
mth/yr). Format col A as date.

Cols A to C will return only the lines for the mth/yr : Jan08 from x,
with all lines neatly bunched at the top, arranged in chronological order by
date. Any lines with identical/duplicate dates will be returned as well, in
relative order.

Then just make a copy of the sheet: Jan08, rename it as: Feb08, and you'd
get the results for Feb08. Repeat the copy > rename sheet process to get the
rest of the 12 mth/yr sheets (a simple one-time job). Adapt to suit ..
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"Chersie" wrote:
> I have worksheet one set up as a form to gather information. I have twelve
> consecutive worksheets for the months of the year.
>
> I would like to link the data from sheet1 to the appropriate month the data
> is for. I am not sure how to do this.
>
> I want all input data from January 1st to January 31st from the form to go
> to the worksheet January, February 1st to February 29th to go to worksheet
> February, etc.
>
> How can I do this?
>
> Thanks in advance for your help!!!

 
Reply With Quote
 
Chersie
Guest
Posts: n/a
 
      11th Apr 2008
Max, this was perfect!!!! I can't thank you enough! I loved the example
project. It helped me immensely in setting up my workbook!

I do have another question for you. I have a spreadsheet in which I want to
write a macro to take a list of names from worksheet1 in column A and have
each consecutive worksheet given the subsequent names in the list A1, A2, A3,
etc.

If you can help me with that, I then have one more question. One at a time
though

Thank you!
Chersie



"Max" wrote:

> One formulas play which delivers it automatically into respective MthYr
> sheets, with lines auto-sorted in chrono order as well ..
>
> Illustrated in this sample:
> http://www.freefilehosting.net/download/3f3bc
> AutoCopy Data By MthYr To Resp Sheet.xls
>
> In sheet: x (the "master")
> Assume data in cols A to C, from row2 down,
> with the key col = col A (Dates, containing real dates)
>
> List as *text* in K1 across: Jan08, Feb08, Mar08, etc (in any order)
> Put in K2:
> =IF($A2="","",IF(TEXT($A2,"mmmyy")=K$1,$A2+ROW()/10^10,""))
> Copy K2 across as far as required, then fill down to cover the max expected
> extent of source data
>
> Click Insert > Name > Define
> Put under "Names in workbook:": WSN
> Put in the "Refers to:" box:
> =MID(CELL("Filename",INDIRECT("A1")),FIND("]",CELL("Filename",INDIRECT("A1")
> ))+1,32)
> Click OK
>
> The above defines WSN as a name we can use to refer to the sheetname in
> formulas. It will auto-extract the sheetname implicitly. Technique came from
> a post by Harlan.
>
> In a new sheet named: Jan08
> With the same col headers pasted into A1:C1
>
> Put in A2:
> =IF(ISERROR(SMALL(OFFSET(x!$J:$J,,MATCH(WSN,x!$K$1:$IV$1,0)),ROWS($1:1))),"",INDEX(x!A:A,MATCH(SMALL(OFFSET(x!$J:$J,,MATCH(WSN,x!$K$1:$IV$1,0)),ROWS($1:1)),OFFSET(x!$J:$J,,MATCH(WSN,x!$K$1:$IV$1,0)),0)))
> Copy A2 across to C2, fill down to say, C25 (copy down by the smallest
> possible range sufficient to cover the max expected extent for any single
> mth/yr). Format col A as date.
>
> Cols A to C will return only the lines for the mth/yr : Jan08 from x,
> with all lines neatly bunched at the top, arranged in chronological order by
> date. Any lines with identical/duplicate dates will be returned as well, in
> relative order.
>
> Then just make a copy of the sheet: Jan08, rename it as: Feb08, and you'd
> get the results for Feb08. Repeat the copy > rename sheet process to get the
> rest of the 12 mth/yr sheets (a simple one-time job). Adapt to suit ..
> --
> Max
> Singapore
> http://savefile.com/projects/236895
> xdemechanik
> ---
> "Chersie" wrote:
> > I have worksheet one set up as a form to gather information. I have twelve
> > consecutive worksheets for the months of the year.
> >
> > I would like to link the data from sheet1 to the appropriate month the data
> > is for. I am not sure how to do this.
> >
> > I want all input data from January 1st to January 31st from the form to go
> > to the worksheet January, February 1st to February 29th to go to worksheet
> > February, etc.
> >
> > How can I do this?
> >
> > Thanks in advance for your help!!!

 
Reply With Quote
 
Max
Guest
Posts: n/a
 
      11th Apr 2008
"Chersie" wrote:
> Max, this was perfect!!!! I can't thank you enough! I loved the example
> project. It helped me immensely in setting up my workbook!


Welcome, delighted to hear that.

> I do have another question for you. ..


I'm out, sorry. Suggest you try a fresh posting in .programming
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

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

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Dates linked in Excel files JayDee Microsoft Excel Worksheet Functions 3 27th Jun 2008 05:31 PM
How do I have a linked cell auto-size to fit the linked data? CristinPDX Microsoft Excel Misc 2 24th Jun 2008 10:29 PM
Displaying linked data in excel 2007 when linked file is not avail Eng_19 Microsoft Excel Misc 0 7th Dec 2007 07:27 PM
Excel linked vs non-linked column data Hwalker Microsoft Excel Misc 0 28th Apr 2004 08:43 PM
Excel Dates Linked into Word Doc =?Utf-8?B?RGF3bg==?= Microsoft Access 0 6th Apr 2004 03:21 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:55 AM.