Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 21
Default Selecting Values in Worksheet

Hi,

Have Worksheet = Info Contains Columns A to E

Have Worksheet Called Selected

Have Worksheet Call Choose

That I would like to do is:-

Change a1 on Choose to = "2"

Then Display on Selected Colums A to E from info where Column A = Choose A1

No of colums may very ie 1 = 3 rows, 2 = 10 rows etc

Hope you can help

Trev
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,441
Default Selecting Values in Worksheet

Trever,

Get rid of sheet "Selected", get rid of sheet "Choose", and use Data filters on sheet "Info".
Select the table, use Data / Filter / Autofilter, then select your 1 or 2 or whatever from the
dropdown at the top of column A on "Info" That's the best way to do what you want.

HTH,
Bernie
MS Excel MVP


"Trever B" wrote in message
...
Hi,

Have Worksheet = Info Contains Columns A to E

Have Worksheet Called Selected

Have Worksheet Call Choose

That I would like to do is:-

Change a1 on Choose to = "2"

Then Display on Selected Colums A to E from info where Column A = Choose A1

No of colums may very ie 1 = 3 rows, 2 = 10 rows etc

Hope you can help

Trev



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 21
Default Selecting Values in Worksheet

Thanks Bernie,

Have already been there. Not what I need to do. This is a 40 worksheet
document with graphs. Then automatically export to powerpoint with 40 shops
so automation has to come with it.

What you are suggesting is manual.

Thanks Anyway.

Perhaps someone els can help.

Trev

"Bernie Deitrick" wrote:

Trever,

Get rid of sheet "Selected", get rid of sheet "Choose", and use Data filters on sheet "Info".
Select the table, use Data / Filter / Autofilter, then select your 1 or 2 or whatever from the
dropdown at the top of column A on "Info" That's the best way to do what you want.

HTH,
Bernie
MS Excel MVP


"Trever B" wrote in message
...
Hi,

Have Worksheet = Info Contains Columns A to E

Have Worksheet Called Selected

Have Worksheet Call Choose

That I would like to do is:-

Change a1 on Choose to = "2"

Then Display on Selected Colums A to E from info where Column A = Choose A1

No of colums may very ie 1 = 3 rows, 2 = 10 rows etc

Hope you can help

Trev




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,441
Default Selecting Values in Worksheet

Trev,

Well, I won't comment on your application design, but will help you further along down your chosen
path.

You can use a worksheet change event, for sheet "Choose" - Copy the code below, right-click the
sheet tab of sheet "Choose", select "View Code" and paste the code into the window that appears. It
will do what you had described in your initial post.

HTH,
Bernie
MS Excel MVP


Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count 1 Then Exit Sub
If Target.Address < "$A$1" Then Exit Sub

Application.EnableEvents = False

Worksheets("Selected").Range("A:E").ClearContents
With Worksheets("Info").Range("A1").CurrentRegion
.AutoFilter field:=1, Criteria1:=CStr(Target.Value)
.SpecialCells(xlCellTypeVisible).Copy _
Worksheets("Selected").Cells(1, 1)
.AutoFilter
End With
Application.EnableEvents = True

End Sub


"Trever B" wrote in message
...
Thanks Bernie,

Have already been there. Not what I need to do. This is a 40 worksheet
document with graphs. Then automatically export to powerpoint with 40 shops
so automation has to come with it.

What you are suggesting is manual.

Thanks Anyway.

Perhaps someone els can help.

Trev

"Bernie Deitrick" wrote:

Trever,

Get rid of sheet "Selected", get rid of sheet "Choose", and use Data filters on sheet "Info".
Select the table, use Data / Filter / Autofilter, then select your 1 or 2 or whatever from the
dropdown at the top of column A on "Info" That's the best way to do what you want.

HTH,
Bernie
MS Excel MVP


"Trever B" wrote in message
...
Hi,

Have Worksheet = Info Contains Columns A to E

Have Worksheet Called Selected

Have Worksheet Call Choose

That I would like to do is:-

Change a1 on Choose to = "2"

Then Display on Selected Colums A to E from info where Column A = Choose A1

No of colums may very ie 1 = 3 rows, 2 = 10 rows etc

Hope you can help

Trev






  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 21
Default Selecting Values in Worksheet

Thanks Bernie,

Worked a treat.

Trev

"Bernie Deitrick" wrote:

Trev,

Well, I won't comment on your application design, but will help you further along down your chosen
path.

You can use a worksheet change event, for sheet "Choose" - Copy the code below, right-click the
sheet tab of sheet "Choose", select "View Code" and paste the code into the window that appears. It
will do what you had described in your initial post.

HTH,
Bernie
MS Excel MVP


Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Cells.Count 1 Then Exit Sub
If Target.Address < "$A$1" Then Exit Sub

Application.EnableEvents = False

Worksheets("Selected").Range("A:E").ClearContents
With Worksheets("Info").Range("A1").CurrentRegion
.AutoFilter field:=1, Criteria1:=CStr(Target.Value)
.SpecialCells(xlCellTypeVisible).Copy _
Worksheets("Selected").Cells(1, 1)
.AutoFilter
End With
Application.EnableEvents = True

End Sub


"Trever B" wrote in message
...
Thanks Bernie,

Have already been there. Not what I need to do. This is a 40 worksheet
document with graphs. Then automatically export to powerpoint with 40 shops
so automation has to come with it.

What you are suggesting is manual.

Thanks Anyway.

Perhaps someone els can help.

Trev

"Bernie Deitrick" wrote:

Trever,

Get rid of sheet "Selected", get rid of sheet "Choose", and use Data filters on sheet "Info".
Select the table, use Data / Filter / Autofilter, then select your 1 or 2 or whatever from the
dropdown at the top of column A on "Info" That's the best way to do what you want.

HTH,
Bernie
MS Excel MVP


"Trever B" wrote in message
...
Hi,

Have Worksheet = Info Contains Columns A to E

Have Worksheet Called Selected

Have Worksheet Call Choose

That I would like to do is:-

Change a1 on Choose to = "2"

Then Display on Selected Colums A to E from info where Column A = Choose A1

No of colums may very ie 1 = 3 rows, 2 = 10 rows etc

Hope you can help

Trev






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
selecting 20 closest values from a list of 200 values michele New Users to Excel 1 August 12th 08 04:46 PM
Copy Values from WorkSheet back to Another Workbook Replacing Values in Worksheet bobwilson[_16_] Excel Programming 0 April 3rd 06 09:50 PM
selecting values form multiple excel files into an excel worksheet martha Excel Programming 1 June 27th 05 10:17 AM
selecting cell range in other worksheet without switching to worksheet suzetter[_4_] Excel Programming 4 June 22nd 05 08:55 PM
selecting values monika Excel Programming 2 February 9th 04 11:43 AM


All times are GMT +1. The time now is 01:50 PM.

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"