+ Reply to Thread
Results 1 to 2 of 2

Command an entry to appear in a cell based on another's contents

Hybrid View

  1. #1
    Registered User
    Join Date
    07-07-2014
    Location
    Pittsburgh, PA
    MS-Off Ver
    2007
    Posts
    3

    Command an entry to appear in a cell based on another's contents

    7-17-14

    The answer to this question may be that I need to use the vlookup function. I just tried to familiarize myself with this process and I can see immediately it's complicated and poses a fairly steep learning curve for me. IF ANYONE SEEING THIS POST KNOWS A SIMPLER WAY TO DEAL WITH THIS, PLEASE LET ME KNOW. Otherwise tell me there is no alternative--that I need to learn my way around the
    vlookup function. Here's the problem:

    How do I command Excel (what function(s) can I use) to enter a specific piece of data-- numerical or text-- into a cell depending on what is found in a neighboring cell in another column?

    For example, suppose I have a column containing a long series of last names-- Smith, Jones, Green, Brown, etc. How do I command Excel to search through that column, row by row, and every time it encounters the name Smith, enter the sum $1000.00 in a cell in a neighboring column;
    every time it encounters the name Jones, enter $5,000.00 in the neighboring column; for Green, enter $3000.00 and so forth. Alternatively, enter text data instead, for example an entry like Consultation:Urology for every entry containing Smith, Consultation:Orthopedics for every entry containing Jones, etc.

    Is there a straightforward way to accomplish this without using vlookup?

    Thanks in advance to anyone who sees this and can help.

  2. #2
    Forum Expert
    Join Date
    12-14-2012
    Location
    London England
    MS-Off Ver
    MS 365 Office Suite.
    Posts
    8,448

    Re: Command an entry to appear in a cell based on another's contents

    I prefer to use match and offset.

    eg:-

    =OFFSET(L$1,MATCH(A1,K$1:K$3,0)-1,0)
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Shortcut command converting cell entry
    By plum in forum Excel General
    Replies: 6
    Last Post: 05-08-2011, 04:13 AM
  2. Split cell contents over multiple rows based on cell contents
    By naigy in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-17-2011, 05:38 PM
  3. [SOLVED] dos command for es\xcel to add an entry in cell
    By pswapnil007@gmail.com in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-13-2006, 02:10 AM
  4. [SOLVED] Changing Command Button Based on Data Entry
    By Bill in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-20-2006, 06:35 PM
  5. [SOLVED] Command for posting entry to the next empty cell
    By Confused Scripter in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-04-2005, 12:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1