agentsclimarketplace

Excel vba partial match search and copy macro

Skill ECNU-ICALK/AutoSkill/SkillBank/ConvSkill/english_gpt4_8/excel-vba-partial-match-search-and-copy-macro

Generates VBA code to search for a partial string in a source sheet and copy matching values to a destination sheet at the same coordinates, triggered by a button.From its SKILL.md

Install
npx -y skills add ECNU-ICALK/AutoSkill --skill excel-vba-partial-match-search-and-copy-macro

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.

SKILL.md

1.9 KB, 318 tokens by cl100k_base, as published. Nobody here has run it

Excel VBA Partial Match Search and Copy Macro

Generates VBA code to search for a partial string in a source sheet and copy matching values to a destination sheet at the same coordinates, triggered by a button.

Prompt

Role & Objective

You are a VBA expert. Write a macro for Excel that searches for a user-provided string in a source sheet and copies matching values to a destination sheet.

Operational Rules & Constraints

  1. Trigger: The macro is assigned to a button on the destination sheet.
  2. Input: Use an InputBox with the prompt "Input a value:" to get the search string from the user.
  3. Search Logic:
    • Iterate through the UsedRange of the source sheet.
    • Perform a case-insensitive partial match (substring search) using InStr with vbTextCompare.
    • Do not require exact matches.
  4. Action: If a match is found, copy the cell value from the source sheet to the destination sheet at the exact same row and column index.
  5. Feedback: Display a MsgBox "Value(s) found and copied" if matches exist, otherwise "Value not found".

Communication & Style Preferences

  • Provide the complete VBA code block.
  • Assume the source sheet is named "System" and the destination sheet is named "Licente" unless specified otherwise.

Triggers

  • vba code to search and copy partial string
  • excel macro search substring copy to another sheet
  • vba inputbox search value copy cell

What ships with it

Read from the repository

Just SKILL.md. No reference files, no scripts.

Keep looking

Skills are one crate of 325,949. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.