Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default VB programing

I need a cross check that will verify if several cells on a WB equal (or is +
/ - 2 units)

also that verify in another workbook also.

can some one help me.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 694
Default VB programing

sorry i don't understand what you want.
Could you please be more specific and give an example.
Thanks,
Sebastien

"Mestrella31" wrote:

I need a cross check that will verify if several cells on a WB equal (or is +
/ - 2 units)

also that verify in another workbook also.

can some one help me.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default VB programing


Dim dblCheck as Double

dblCheck = Abs(Range("A1").Value - Range("B1").Value)
If dblCheck 2 Then
'Whatever you want to do if they are out of tolerance
End If

Or if they are on different (open) workbooks

dblCheck
Abs(Workbooks("Book1.xls").Sheets("Sheet1").Range( "A1").Value
Workbooks("Book2.xls").Sheets("Sheet1").Range("B1" ).Value)
If dblCheck 2 Then
'Whatever you want to do if they are out of tolerance
End If

Adapt to fit your circumstances.



--
kkkni
-----------------------------------------------------------------------
kkknie's Profile: http://www.excelforum.com/member.php...nfo&userid=754
View this thread: http://www.excelforum.com/showthread.php?threadid=26781

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default VB programing

Thanks KKKnie, this is going to work

"kkknie" wrote:


Dim dblCheck as Double

dblCheck = Abs(Range("A1").Value - Range("B1").Value)
If dblCheck 2 Then
'Whatever you want to do if they are out of tolerance
End If

Or if they are on different (open) workbooks

dblCheck =
Abs(Workbooks("Book1.xls").Sheets("Sheet1").Range( "A1").Value -
Workbooks("Book2.xls").Sheets("Sheet1").Range("B1" ).Value)
If dblCheck 2 Then
'Whatever you want to do if they are out of tolerance
End If

Adapt to fit your circumstances.

K


--
kkknie
------------------------------------------------------------------------
kkknie's Profile: http://www.excelforum.com/member.php...fo&userid=7543
View this thread: http://www.excelforum.com/showthread...hreadid=267810


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 programing rlenz Excel Discussion (Misc queries) 2 April 18th 06 02:41 PM
Help with VBA programing CyberStorm Excel Programming 3 July 26th 04 07:57 PM
Macro programing Jason Trolian Excel Programming 4 June 5th 04 10:15 PM
Iteration programing namphong Excel Programming 0 February 3rd 04 01:49 PM
help with excel programing drummerboy827[_4_] Excel Programming 1 September 27th 03 03:31 PM


All times are GMT +1. The time now is 06:52 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"