Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Microsoft Office > Excel VBA > Excel VBA
|
Excel VBA Discuss using VBA for Excel programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Excel VBA section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 10th, 2008, 11:33 PM
Authorized User
 
Join Date: Mar 2008
Posts: 74
Thanks: 2
Thanked 0 Times in 0 Posts
Send a message via ICQ to sektor
Default "Value2" property of Range object

In "Auto Member" drop down list of Range object I noticed Value2 property.
Question: what's the practical using of this property and in what cases it preferable to use?

 
Old April 11th, 2008, 03:28 AM
Authorized User
 
Join Date: Mar 2008
Posts: 35
Thanks: 0
Thanked 1 Time in 1 Post
Default

Hi sektor,
Here's a piece of documentation from http://www.decisionmodels.com/calcsecretsj.htm
It is faster (15-20%) to use the Range.Value2 property rather than the (default) Range.Value property. The Range.Value property attempts to convert cells formatted as Dates to a variant containg a VBA date type, and cells formatted as currency to a variant containing a VBA Currency type. Range.value2 attempts to convert date and Currency formatted cells into Variants containing Doubles.

What it means in practical terms is that you might as well forget it exists...
I would consider it only on a full-scale scientific project with many thousands of Date and Currency calculations and conversions going back and forth, just to save myself of some extra seconds of waiting...







Similar Threads
Thread Thread Starter Forum Replies Last Post
Error setting Range Value property Keith Smith Excel VBA 3 March 14th, 2008 07:32 AM
How to get Object property using EVAL()? srumberg Access VBA 2 November 20th, 2006 06:07 PM
METHOD 'RANGE' OF OBJECT '_GLOBAL' FAILED CBCHIAM Excel VBA 7 August 31st, 2005 04:08 AM
object property name from variable augustwest General .NET 3 June 9th, 2004 12:11 AM
Error setting Formula Array property for a Range arnowitz Excel VBA 2 February 5th, 2004 02:08 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.