Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Problem with MATCH function

Hi,

i try to use match to search some value. When i run it, excel displays an
error 13 : type mismatch.

Here is my code:

Set rngCrit1 = ThisWorkbook.Sheets("Backup").Range("G1:G65536")
Set rngCrit2 = ThisWorkbook.Sheets("Backup").Range("H1:H65536")
Set rngCrit3 = ThisWorkbook.Sheets("Backup").Range("K1:K65536")

Dim varTest As Variant
varTest = WorksheetFunction.Match(ThisWorkbook.Sheets("Progr ams").Range("G"
& iCounter).Value & ThisWorkbook.Sheets("Programs").Range("H" &
iCounter).Value & ThisWorkbook.Sheets("Programs").Range("K" &
iCounter).Value, rngCrit1 & rngCrit2 & rngCrit3, 0)

i do not understand where is the problem.
please, could you help me ?
thx,
Maileen
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,339
Default Problem with MATCH function

You are trying to match a concatenation of three cells with 3 ranges
(Columns); match works on one column only.

Can you explain what you are trying to do in your code. If your search
values are 1,2 and 3 I ssume you looking for 1 in column G, 2 in H and 3 in K?

"Maileen" wrote:

Hi,

i try to use match to search some value. When i run it, excel displays an
error 13 : type mismatch.

Here is my code:

Set rngCrit1 = ThisWorkbook.Sheets("Backup").Range("G1:G65536")
Set rngCrit2 = ThisWorkbook.Sheets("Backup").Range("H1:H65536")
Set rngCrit3 = ThisWorkbook.Sheets("Backup").Range("K1:K65536")

Dim varTest As Variant
varTest = WorksheetFunction.Match(ThisWorkbook.Sheets("Progr ams").Range("G"
& iCounter).Value & ThisWorkbook.Sheets("Programs").Range("H" &
iCounter).Value & ThisWorkbook.Sheets("Programs").Range("K" &
iCounter).Value, rngCrit1 & rngCrit2 & rngCrit3, 0)

i do not understand where is the problem.
please, could you help me ?
thx,
Maileen

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
Problem with MATCH function DoubleZ Excel Discussion (Misc queries) 5 March 9th 09 06:39 PM
Problem with using match function Montu Excel Worksheet Functions 1 December 29th 07 06:12 PM
Match function problem [email protected] Excel Worksheet Functions 3 October 4th 06 07:39 PM
MATCH function problem LACA Excel Discussion (Misc queries) 10 May 22nd 06 01:39 AM
Problem with match function nander Excel Discussion (Misc queries) 4 April 18th 06 10:08 PM


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