Consulting

Results 1 to 5 of 5

Thread: VBA to grab data from other .XLS file

  1. #1
    VBAX Newbie
    Joined
    Sep 2007
    Posts
    4
    Location

    VBA to grab data from other .XLS file

    i i have two files and i would like one sheet to grab data from the other one by using keywords, basicly if someone types in kitchen or bathroom the number that are associated with that are automaticly entered into the right collums same fields on the other file, at the moment i am using a formula like this
    VLOOKUP(A6,'/Users/TheDirectoryItIsIn/[Roomsizes.xls]Rooms'!masterdims,(COLUMN(B6:F6)),FALSE)
    Rooms is the name of the array i made on the sheet i wanted it to get the data from. But i would like to do it in VBA becuse i want a option where when i load up the script it will open up a inputbox or a openfile windows where u can select a file for it to read from is his possible, if so how???

  2. #2
    VBAX Newbie
    Joined
    Sep 2007
    Posts
    4
    Location
    Bump

  3. #3
    VBAX Newbie
    Joined
    Sep 2007
    Posts
    4
    Location
    cant u atleast tell me if it is possible or not?!?!?!

  4. #4
    Moderator VBAX Wizard lucas's Avatar
    Joined
    Jun 2004
    Location
    Tulsa, Oklahoma
    Posts
    7,323
    Location
    I would say that it is possible but your explaination is vague. It might help if you would post example workbooks with a better explaination.

    Sounds like you're trying to use a closed workbook for a database of products, etc. and fill in forms on an open workbook....
    Steve
    "Nearly all men can stand adversity, but if you want to test a man's character, give him power."
    -Abraham Lincoln

  5. #5
    VBAX Newbie
    Joined
    Sep 2007
    Posts
    4
    Location
    ok well i show you the two work books i am working with the first one is building 1.xls
    (http)download.yousendit.com/1D636EA57AAC972A
    and the second file is roomsizes.xls
    (http)download.yousendit.com/DA1D53182AD93323

    replace (http) with http in your adress bar

    basicly i want to grab data off one xls file and put it into certain fields on the second but not all the fields. And it would also be extremly usefull if when u open up the spread sheet a open file box apears and you select a file you would like to grab the data off so when you type in keywords it will look on the second sheet that you specified at the start up of the spread sheet scans for the keyword once it find the keyword it would fill in the row of which you type the keyword.

    (in other words. The first file you specify at start up will have all the keywords and data on the second file will be blank so when you type in a keyworkd such as Bathroom on the second file it will check the first sheet and then see the keyword and fill in the rows of data on the second file)
    hopefully you can understand it now
    and also one more question would it be possible to select multiple closed workbooks at the start up so one open workbook could search for keyworkd say between 3 closed workbooks?
    many many many thanks.
    Def.

Posting Permissions

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