Find Jobs
Hire Freelancers

Macro needed to append data to cell in selected column with input string

$2-3 USD / hour

Completed
Posted almost 3 years ago

$2-3 USD / hour

I can pay $2 for the first working solution that I test. 'If the row contains "a specific string" of characters then that specific string of characters should be appended to the end of the cell in the currently selected column. 'This should occur only if the cell in the selected column for the row in question does not already contain that string of characters. 'Also, if the specific string of characters is not found anywhere on the row, then it should not be appended. I have also included the sample sheet with the macro included. When I tried to run it, I got this error. When I tried the code, I got this error [login to view URL] So it needs to be modified to accomplish my objective. [code] Option Explicit Sub findAndAppend() Dim tcell As Range Dim lookFor As String, firstaddress Dim fnd As Range ' union of all found cells lookFor = "craig" ' InputBox("What to find") If lookFor = "" Then Exit Sub ' \\\\\\\\\\\\\\\ BEGIN "Standard Find All" code finds ALMOST ALL occurances \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ With [login to view URL] Set tcell = .Find(What:=lookFor, LookIn:=xlValues, LookAt:=xlPart, _ MatchCase:=False, searchOrder:=xlByRows) If tcell Is Nothing Then MsgBox "not found" Exit Sub End If If Not tcell Is Nothing Then firstaddress = [login to view URL] Do Dim addit As Boolean ' under some weird circumstances the loop can hit the same cell more than once. If fnd Is Nothing Then Set fnd = tcell addit = True ElseIf Intersect(fnd, tcell) Is Nothing Then Set fnd = Union(fnd, tcell) addit = True Else addit = False End If If [login to view URL] = 13 Then Stop If addit Then If [login to view URL] > 1 Then With [login to view URL](1) If InStr(1, .Value, tcell, 1) = 0 Then .Value = .Value & " " & tcell End If End With End If End If Set tcell = .FindNext(tcell) Loop While [login to view URL] <> firstaddress End If End With ' /////////////// END "STANDARD FIND ALL CODE" /////////////////////////////////////////////////////////// MsgBox "done" End Sub [/code]
Project ID: 30684149

About the project

3 proposals
Remote project
Active 3 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
Awarded to:
User Avatar
Hi I am Sajib, From Bangladesh. I done this project for you. Thanks for posting this project. Award me I will accept.
$2 USD in 40 days
5.0 (86 reviews)
5.9
5.9
3 freelancers are bidding on average $4 USD/hour for this job
User Avatar
Hi I have good knowledge of advance excel and Macros since I am working in this field past 6+ years. Works with great potential
$3 USD in 40 days
0.0 (0 reviews)
0.0
0.0
User Avatar
i am a professional Software engineer i am a professional Software engineer? i am a professional Software engineer
$6 USD in 1 day
0.0 (0 reviews)
0.0
0.0

About the client

Flag of UNITED STATES
Waco, United States
4.9
82
Payment method verified
Member since Feb 13, 2009

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.