Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
hi All,
How to import a data from a excel workbook without opening the book. lets say book name "mybook" location is:"C:\Documents and Settings\BahadiAkcan\My Documents" using above file can I make a match or vlookup function in a code? thanks for your help -- Regards, Baha |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Here is the basic syntax. Adapt to your vlookup and modify to suit
=SUMPRODUCT(('C:\yourfolder\[yourfile.xls]yoursheet'!$E$7:$E$1000=1)*1) -- Don Guillett SalesAid Software "Baha" wrote in message ... hi All, How to import a data from a excel workbook without opening the book. lets say book name "mybook" location is:"C:\Documents and Settings\BahadiAkcan\My Documents" using above file can I make a match or vlookup function in a code? thanks for your help -- Regards, Baha |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thank you for the tip,but i was trying to put in a VBA code
so far I tried this but couldn`t figure out the proper one sub getTheData() dim x as long x = Application.WorksheetFunction.VLookup(D7, "C:\Documents and Settings\BahadiAkcan\My Documents\Book1hhhfhfh.xls" .Sheet1.Range("a1:d33"), 3, 0) msgbox x end sub can you give me a hint please? -- Regards, Baha "Don Guillett" wrote: Here is the basic syntax. Adapt to your vlookup and modify to suit =SUMPRODUCT(('C:\yourfolder\[yourfile.xls]yoursheet'!$E$7:$E$1000=1)*1) -- Don Guillett SalesAid Software "Baha" wrote in message ... hi All, How to import a data from a excel workbook without opening the book. lets say book name "mybook" location is:"C:\Documents and Settings\BahadiAkcan\My Documents" using above file can I make a match or vlookup function in a code? thanks for your help -- Regards, Baha |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
hi,
i think I get my answer from other site. Thank you any way.Any one intrested this question;here is the link that u can get the answer http://www.rondebruin.nl/copy7.htm -- Regards, Baha "Baha" wrote: Thank you for the tip,but i was trying to put in a VBA code so far I tried this but couldn`t figure out the proper one sub getTheData() dim x as long x = Application.WorksheetFunction.VLookup(D7, "C:\Documents and Settings\BahadiAkcan\My Documents\Book1hhhfhfh.xls" .Sheet1.Range("a1:d33"), 3, 0) msgbox x end sub can you give me a hint please? -- Regards, Baha "Don Guillett" wrote: Here is the basic syntax. Adapt to your vlookup and modify to suit =SUMPRODUCT(('C:\yourfolder\[yourfile.xls]yoursheet'!$E$7:$E$1000=1)*1) -- Don Guillett SalesAid Software "Baha" wrote in message ... hi All, How to import a data from a excel workbook without opening the book. lets say book name "mybook" location is:"C:\Documents and Settings\BahadiAkcan\My Documents" using above file can I make a match or vlookup function in a code? thanks for your help -- Regards, Baha |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Technically, that is putting a formula in a cell and letting the Excel
linking mechanism retrieve the data, not getting it from VBA as you specified. -- Regards, Tom Ogilvy "Baha" wrote in message ... hi, i think I get my answer from other site. Thank you any way.Any one intrested this question;here is the link that u can get the answer http://www.rondebruin.nl/copy7.htm -- Regards, Baha "Baha" wrote: Thank you for the tip,but i was trying to put in a VBA code so far I tried this but couldn`t figure out the proper one sub getTheData() dim x as long x = Application.WorksheetFunction.VLookup(D7, "C:\Documents and Settings\BahadiAkcan\My Documents\Book1hhhfhfh.xls" .Sheet1.Range("a1:d33"), 3, 0) msgbox x end sub can you give me a hint please? -- Regards, Baha "Don Guillett" wrote: Here is the basic syntax. Adapt to your vlookup and modify to suit =SUMPRODUCT(('C:\yourfolder\[yourfile.xls]yoursheet'!$E$7:$E$1000=1)*1) -- Don Guillett SalesAid Software "Baha" wrote in message ... hi All, How to import a data from a excel workbook without opening the book. lets say book name "mybook" location is:"C:\Documents and Settings\BahadiAkcan\My Documents" using above file can I make a match or vlookup function in a code? thanks for your help -- Regards, Baha |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
after I use that code, my problem actually didnt fixed much.As you mentioned
I cannot use a function for closed workbook,so that code put entire column values(cos I have to select A:A),then now I wrote an other code to delete all cells which have "0" values which works very slow.Can u suggest,anything else to delete "0" value? here is my code Application.ScreenUpdating = False Dim cdel cdel = Application.WorksheetFunction.CountIf(Sheet1.Range ("a1:a30000"), "0") Do Until cdel = 0 Cells.Find(What:="0", After:=ActiveCell, LookIn:=xlFormulas _ , LookAt:=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, _ MatchCase:=False, SearchFormat:=False).Activate ActiveCell.EntireRow.Delete Shift:=xlUp cdel = cdel - 1 Loop Application.ScreenUpdating = True is it very ugly?:) -- Regards, Baha "Tom Ogilvy" wrote: Technically, that is putting a formula in a cell and letting the Excel linking mechanism retrieve the data, not getting it from VBA as you specified. -- Regards, Tom Ogilvy "Baha" wrote in message ... hi, i think I get my answer from other site. Thank you any way.Any one intrested this question;here is the link that u can get the answer http://www.rondebruin.nl/copy7.htm -- Regards, Baha "Baha" wrote: Thank you for the tip,but i was trying to put in a VBA code so far I tried this but couldn`t figure out the proper one sub getTheData() dim x as long x = Application.WorksheetFunction.VLookup(D7, "C:\Documents and Settings\BahadiAkcan\My Documents\Book1hhhfhfh.xls" .Sheet1.Range("a1:d33"), 3, 0) msgbox x end sub can you give me a hint please? -- Regards, Baha "Don Guillett" wrote: Here is the basic syntax. Adapt to your vlookup and modify to suit =SUMPRODUCT(('C:\yourfolder\[yourfile.xls]yoursheet'!$E$7:$E$1000=1)*1) -- Don Guillett SalesAid Software "Baha" wrote in message ... hi All, How to import a data from a excel workbook without opening the book. lets say book name "mybook" location is:"C:\Documents and Settings\BahadiAkcan\My Documents" using above file can I make a match or vlookup function in a code? thanks for your help -- Regards, Baha |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thank you very much. That's the code I'm looking for.
This discussion group is wonderful! ...... save me a lot of time in searching and sieving through informative material. Cheers! "Baha" wrote in message ... hi, i think I get my answer from other site. Thank you any way.Any one intrested this question;here is the link that u can get the answer http://www.rondebruin.nl/copy7.htm -- Regards, Baha "Baha" wrote: Thank you for the tip,but i was trying to put in a VBA code so far I tried this but couldn`t figure out the proper one sub getTheData() dim x as long x = Application.WorksheetFunction.VLookup(D7, "C:\Documents and Settings\BahadiAkcan\My Documents\Book1hhhfhfh.xls" .Sheet1.Range("a1:d33"), 3, 0) msgbox x end sub can you give me a hint please? -- Regards, Baha "Don Guillett" wrote: Here is the basic syntax. Adapt to your vlookup and modify to suit =SUMPRODUCT(('C:\yourfolder\[yourfile.xls]yoursheet'!$E$7:$E$1000=1)*1) -- Don Guillett SalesAid Software "Baha" wrote in message ... hi All, How to import a data from a excel workbook without opening the book. lets say book name "mybook" location is:"C:\Documents and Settings\BahadiAkcan\My Documents" using above file can I make a match or vlookup function in a code? thanks for your help -- Regards, Baha |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel 2007:Share Workbook with import live Data | Excel Worksheet Functions | |||
Import/Copy some data from one workbook to a similar workbook | Excel Programming | |||
i want to import data from one workbook to another and add a row | Excel Worksheet Functions | |||
How do I import data from 1 workbook excel sheet into another? | New Users to Excel | |||
Import Excel Data from another workbook or file | Excel Discussion (Misc queries) |