Re: macro for coding an id number

From: Tom Ogilvy (twogilvy_at_msn.com)
Date: 09/06/04


Date: Mon, 6 Sep 2004 13:09:59 -0400

The only pattern I see is if item and origin are the same use the same first
three digits.

Any other rules.

-- 
Regards,
Tom Ogilvy
"Matthew Kramer" <mkramer110@hotmail.com> wrote in message
news:%23BcfeMDlEHA.324@TK2MSFTNGP11.phx.gbl...
>
> Hi,
>
> I`ve created this simple sample index to code items using a vlookup:
>
> id code item
> 1001 apples
> 7771 oranges
> 4432 pears
> 6767 bananas
> 2722 strawberries
>
> This works using a two column array for the index and data which I`d
> like to code.
>
> Unfortunately, the items are more complex and would really need more
> than a two column array.  Ideally, the reference index needs to be
> multiple columns such as:
>
> idcode item origin size color
> 1001 apples USA large red
> 1002 apples USA large green
> 1003 apples USA large yellow
> 3234 apples Spain large red
> 3235 apples Spain large green
> 3236 apples Spain large yellow
> 7771 oranges France small
> 7772 oranges France medium
> 7773 oranges France large
> 2425 oranges USA small
> 2426 oranges USA medium
> 2427 oranges USA large
>
> Is there some way to do a vlookup using a multi-column array to code the
> items?  If the items meets all of the criterion for item, origin, size
> and color - then it codes the corresponding idcode.
>
> The dataset with the items to be coded have the same field headings as
> above.  All that is missing is the idcode.
>
> Is there some way to adjust the VB code for a simple vlookup procedure
> to do this?  How would be the most effective way to do this?
>
> Looking forward to your suggestions.
>
> Best regards,
>
> Matthew Kramer
>
>
>
>
>
> *** Sent via Developersdex http://www.developersdex.com ***
> Don't just participate in USENET...get rewarded for it!


Relevant Pages

  • Re: Androcless accusations of lying
    ... ct is scalar multiple of x, otherwise it may already be squewed or ... Oranges, and apples, if you like. ... Of course, I'm talking about real physics and sanity, not theoretical ...
    (sci.physics.relativity)
  • Re: Question about light clock and derivation of time dilation
    ... >>> Unfortunately, with morons like Androcles and Wilson, ... >> Indeed there are negative time intervals because measuring a time ... > negative apples or negatove oranges, ...
    (sci.physics.relativity)
  • OT: movie-fan rgpers
    ... Who like apples and oranges equally? ... Blues Brothers ... Zatoichi flics ...
    (rec.gambling.poker)
  • Re: ARod is not clutch
    ... season and a small handful of plate appearances in the playoffs ... is mixing apples and oranges. ... are somehow more relevant today than recent history. ...
    (alt.sports.baseball.ny-yankees)
  • Re: macro for coding an id number
    ... > 1001 apples USA large red ... > 3235 apples Spain large green ... > 7771 oranges France small ... > 7772 oranges France medium ...
    (microsoft.public.excel.programming)