+ Reply to Thread
Results 1 to 4 of 4

Get stored value from existing item in dictionary

  1. #1
    Forum Expert
    Join Date
    04-23-2009
    Location
    Matrouh, Egypt
    MS-Off Ver
    Excel 2013
    Posts
    6,892

    Get stored value from existing item in dictionary

    Hello everyone

    I am trying the following code
    Please Login or Register  to view this content.
    What I need to add in this code is to detect if the item existing in the dictionary or not
    If new then some calculations will be done ..on columns M to U
    And if it is already exists, there is no need to do the calculations again .. just bring the results from the existing

    run the above code and have a look at a(7), you will find it empty as it is already existed before
    What I need for a(7) for example [This is a duplicate one] >> So I need to take the results in a(7,3) to a(7,11) from existing item
    The exisitng item or the first instance of 20/04/2009 and "N" was in a(6)
    So I would like to fill a(7,3) to a(7,11) with the same values in a(6,3) to a(6,11)

    Posted at this link too
    Attached Files Attached Files
    < ----- Please click the little star * next to add reputation if my post helps you
    Visit Forum : From Here

  2. #2
    Forum Expert MickG's Avatar
    Join Date
    11-23-2007
    Location
    Banbury,Oxfordshire
    Posts
    2,650

    Re: Get stored value from existing item in dictionary

    I'm not sure exactly what the results should be, but if you store the row number "i" as the item, instead of the key then you can use that row as the Datum for copying down, based on each "Key", as shown in the "Else" statement.
    Try the code below for results on sheet2.
    Please Login or Register  to view this content.
    Regards Mick

  3. #3
    Forum Expert
    Join Date
    04-23-2009
    Location
    Matrouh, Egypt
    MS-Off Ver
    Excel 2013
    Posts
    6,892

    Re: Get stored value from existing item in dictionary

    That's great Mr. Mick
    I got your point and I learned something new

    Thank you very much

    ** What if I need to populate the data to the same sheet ("Sheet1") which has the raw data but I don't want to touch the columns from A to L ..
    I mean I need to populate the result of the array from the third column of the array to the last one and put those results in sheet1 in column M to U

    Thanks a lot for great help

  4. #4
    Forum Expert
    Join Date
    04-23-2009
    Location
    Matrouh, Egypt
    MS-Off Ver
    Excel 2013
    Posts
    6,892

    Re: Get stored value from existing item in dictionary

    Thanks a lot (it seems I can't think well because I didn't sleep well)
    What I have asked from last reply is too simple but I am not in a good mood
    Please Login or Register  to view this content.
    Thank you very much for awesome help

+ 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. [SOLVED] Sort key and item in dictionary using arraylist
    By daboho in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 10-24-2018, 07:48 AM
  2. Multiple and variant item of dictionary
    By daboho in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 09-27-2018, 11:51 AM
  3. [SOLVED] Finding corresponding key in dictionary based on item value
    By jaryszek in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-12-2018, 07:38 AM
  4. [SOLVED] Get total of an item in dictionary
    By YasserKhalil in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-24-2017, 07:02 PM
  5. [SOLVED] Can a dictionary key hold more than one item?
    By dwx in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-17-2015, 07:00 AM
  6. [SOLVED] Can a dictionary key hold more than one item?
    By dwx in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-17-2015, 04:37 AM
  7. [SOLVED] If dictionary key exists add new item to existing item array
    By strud in forum Excel Programming / VBA / Macros
    Replies: 18
    Last Post: 11-25-2014, 01:54 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