Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default getting values without using "select"

hello all
I have a question:
I'm trying to use values from different worksheets but I don't know ho
to do it without using the "select" command, I don't even know if it'
possible.

Here is an example:

Sheets("january").Select
Range("A12").Select
Selection.copy

Can I get the value without "selecting" it first?

thank

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default getting values without using "select"

It is almost always unnecessary to Select a range before using
it. For example,

Dim Var As Variant
Var = Worksheets("January").Range("A12").Value
' or
Worksheets("January").Range("A12").Copy


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"ornit " wrote in message
...
hello all
I have a question:
I'm trying to use values from different worksheets but I don't

know how
to do it without using the "select" command, I don't even know

if it's
possible.

Here is an example:

Sheets("january").Select
Range("A12").Select
Selection.copy

Can I get the value without "selecting" it first?

thanks


---
Message posted from http://www.ExcelForum.com/



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default getting values without using "select"

Sheets("January").Range("A12").Copy _
Destination:=Sheets("February").Range("M9")

--
Regards,
Tom Ogilvy

"ornit " wrote in message
...
hello all
I have a question:
I'm trying to use values from different worksheets but I don't know how
to do it without using the "select" command, I don't even know if it's
possible.

Here is an example:

Sheets("january").Select
Range("A12").Select
Selection.copy

Can I get the value without "selecting" it first?

thanks


---
Message posted from http://www.ExcelForum.com/



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 22,906
Default getting values without using "select"

ornit

Range(Range("A1"), Range("A1").End(xlDown)).Select
Selection.Copy
Sheets("Sheet2").Select
Range("A1").Select
Selection.Paste

is equal to.....

Range(Range("A1"), Range("A1").End(xlDown)).Copy _
Destination:=Sheets("Sheet2").Range("A1")

Instead of......

Dim actSht As Worksheet
Set actSht = ActiveSheet
Worksheets("Sheet2").Activate
Range("A1:J10").Select
Selection.Copy
actSht.Activate
Range("K43").Select
ActiveSheet.Paste

use.......

Worksheets("Sheet2").Range("A1:J10").Copy _
Destination:=ActiveSheet.Range("K43")

or, if you just want to copy values:

Range("K43").Resize(10, 10).Value = _
Worksheets("Sheet2").Range("A1:J10").Value

which bypasses using the Clipboard (and is analogous to Paste
Special/Values)

Gord Dibben Excel MVP

On Tue, 1 Jun 2004 11:07:20 -0500, ornit
wrote:

hello all
I have a question:
I'm trying to use values from different worksheets but I don't know how
to do it without using the "select" command, I don't even know if it's
possible.

Here is an example:

Sheets("january").Select
Range("A12").Select
Selection.copy

Can I get the value without "selecting" it first?

thanks


---
Message posted from http://www.ExcelForum.com/


  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default getting values without using "select"

you can try =sheet!A1 (the cell you will use as reference)
or vlookup.

--
Message posted from http://www.ExcelForum.com



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 displays "l" instead of "‚¬" symbol for Euro values lex63 Excel Discussion (Misc queries) 1 April 17th 09 10:10 AM
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
"Control" plus "click" doesn't allow me to select multiple cells Ken Cooke New Users to Excel 0 September 25th 06 04:46 PM
Questionnaire sheet: Select "yes" or "no," and only one can be selected bpatterson Excel Worksheet Functions 2 April 13th 06 11:04 PM
Changing "returned" values from "0" to "blank" LATATC Excel Worksheet Functions 2 October 20th 05 04:41 PM


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

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

About Us

"It's about Microsoft Excel"