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

i used the find fuction in vba, but its case sensitive. How do make it not
case sensitive heres a sample of the code i have so far.

Set coolName = Worksheets("Promotional").Range("B4")
With Worksheets("USERS").Range("a1:a500")
Set c = .Find(coolName)

If c = coolName Then
Worksheets("Promotional").Range("g10").Value = "test"
c.Offset(columnOffset:=5) = "testing"
End If
End With

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Find Function


Code:
--------------------
Set coolName = Worksheets("Promotional").Range("B4")
With Worksheets("USERS").Range("a1:a500")
Set c = .Find(What:=coolName,MatchCase:=false)

If c = coolName Then
Worksheets("Promotional").Range("g10").Value = "test"
c.Offset(columnOffset:=5) = "testing"
End If
End With


--------------------


should work now ;)


--
moondark
------------------------------------------------------------------------
moondark's Profile: http://www.excelforum.com/member.php...o&userid=27390
View this thread: http://www.excelforum.com/showthread...hreadid=469423

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 30
Default Find Function

ok heres the problem now, it finds the data with no problems, but it wont put
in a specific value next to it(using the offset fuction):

sample code:

Set coolName = Worksheets("Promotional").Range("B4")
With Worksheets("USERS").Range("a1:a500")
Set c = .Find(What:=coolName,MatchCase:=false)


'----------this next part is what its not doing----------

If c = coolName Then
Worksheets("Promotional").Range("g10").Value = "test"
c.Offset(columnOffset:=5) = "testing"
End If
End With


"moondark" wrote:


Code:
--------------------
Set coolName = Worksheets("Promotional").Range("B4")
With Worksheets("USERS").Range("a1:a500")
Set c = .Find(What:=coolName,MatchCase:=false)

If c = coolName Then
Worksheets("Promotional").Range("g10").Value = "test"
c.Offset(columnOffset:=5) = "testing"
End If
End With


--------------------


should work now ;)


--
moondark
------------------------------------------------------------------------
moondark's Profile: http://www.excelforum.com/member.php...o&userid=27390
View this thread: http://www.excelforum.com/showthread...hreadid=469423


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
Trying to find which function to use J4shaw Excel Worksheet Functions 3 August 3rd 09 05:58 AM
Find Function VickiMc Excel Worksheet Functions 1 February 12th 09 02:31 AM
Help with the FIND function Ranger Excel Worksheet Functions 1 February 25th 05 03:24 PM
Find Function via VB John Excel Programming 1 June 6th 04 04:01 PM
backwards find function to find character in a string of text Ashleigh K. Excel Programming 1 January 14th 04 04:36 PM


All times are GMT +1. The time now is 09:08 AM.

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"