+ Reply to Thread
Results 1 to 8 of 8

Vlookup solution - probably

  1. #1
    Registered User
    Join Date
    02-25-2014
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    5

    Vlookup solution - probably

    I have attached a sample file
    The main sheet is sheet1
    and the result required is shown in sheet2

    feels like it should be a vlookup solution.
    Tried but all in vain

    If anyone can provide an appropriate solution

    Thanks
    Fraser
    Attached Files Attached Files

  2. #2
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,863

    Re: Vlookup solution - probably

    VLOOKUP or similar functions will not be that easy, beacause of irregular lengths.
    May be try such simple macro:
    Please Login or Register  to view this content.
    PS. Please adhere to forum rules - already in the first one reads:
    Your post title should describe your problem, not your anticipated solution.
    Attached Files Attached Files
    Best Regards,

    Kaper

  3. #3
    Registered User
    Join Date
    02-25-2014
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: Vlookup solution - probably

    Hello Kaper
    What you have tried is perfect but sheet1 has a very huge
    database and I do not want all the data to be converted to that form.
    In sheet2 I will manually enter any one number in column A2 and it matches
    with the number in sheet1 and puts up the data vertically as I have shown.
    Now the data is till fifth row. Next time I will enter number manually in A6.
    The details are till row 7 further I will enter number manually in A8.

    I hope you have got this.
    OR may be if there is a command button wherby after every number I enter
    I should click the command button and the data gets transferred. Even that is
    workable for me.

    Thanks for trying and awaiting for your reply.

    Fraser

  4. #4
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,863

    Re: Vlookup solution - probably

    Have a look if it suits you better?
    Please Login or Register  to view this content.
    or (if you want to have it copied to second sheet):
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    02-25-2014
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: Vlookup solution - probably

    Hi Kaper


    I have checked the code but need to have some more
    clarification. May be there is some mistake in
    my explanation and your understanding.
    I have attached the same file with some more data and the
    result required in sheet2. Test2.xlsx

    If you see sheet2 you will come to know that there is no
    fix sequence of the numbers mentioned in column A.
    From the database in sheet1 I can mention any number
    in any sequence and only that details are placed vertically.
    As I mentioned yesterday of clicking the command button evertime
    you enter a number in column A in sheet2 might work.

    From the database in sheet1 I have not mentioned all the numbers in sheet2
    and also not in the sequence. In sheet2 I have mentioned only four numbers in
    column A whose report or print I require.

    Please let me know if it is clear to you
    Again thanks for the effort and time you are giving

    Fraser
    Attached Files Attached Files

  6. #6
    Registered User
    Join Date
    02-25-2014
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: Vlookup solution - probably

    The database in sheet1 has crossed 8000.
    For every code number I will have to first go to sheet1 and
    search for its row number and then enter the same in sheet2.

    Fraser

  7. #7
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,863

    Re: Vlookup solution - probably

    The "engine" is all the time the same. I changed only way to start it. Now you just write a number in column A in Sheet2. Procedure searches first Sheet1 and identifies row with information requested. Further actions are the same as before.

    The code is now in Sheet2 module (not in general purpose Module 1) as it is the handler of Worksheet_Change event

    Please Login or Register  to view this content.
    Attached Files Attached Files

  8. #8
    Registered User
    Join Date
    02-25-2014
    Location
    India
    MS-Off Ver
    Excel 2007
    Posts
    5

    Re: Vlookup solution - probably

    That was exactly what I required and you made it much easier then I thought.
    Thanks a lot and have a good time.

    Fraser

+ 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. Vlookup? I am sure the solution is here
    By jlfrancis2001 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 07-16-2012, 09:51 AM
  2. Is VLookup the best solution?
    By NickNick in forum Excel General
    Replies: 5
    Last Post: 04-30-2009, 04:29 AM
  3. Solution : Nested IF or VLOOKUP
    By sachinattri in forum Excel General
    Replies: 9
    Last Post: 12-03-2007, 07:56 PM
  4. VLOOKUP Limitation and Solution?
    By KL Cheong in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 03-01-2006, 10:00 AM
  5. Perhaps an IF/VLOOKUP Solution...
    By SamuelT in forum Excel General
    Replies: 2
    Last Post: 09-30-2005, 09:05 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