Excel cell data as plain desktop text ?

Is there a way to script an object that will read say cells a1-a3 in an excel .xls and have them written in plain text on the desk top without actually opening excel ? I'm looking for a way to create 26 objects one for a-z and line them up along a vert bar so i can quickly look up a contact name and phone number for all contacts with the last name "A something" then a second for "B something" without opening the Alist.xls or Blist.xls (i.e. 26 diff spreadsheets)


I'm pretty dumb about scripting but i can usually stumble my way thru cloning one example or modifying existing script.


Thanx


 

5,078 views 3 replies
Reply #1 Top
Perhaps this can help: http://cis.stvincent.edu/wsh/ss.html

It's the first result from google http://www.google.co.uk/search?sourceid=navclient-ff&ie=UTF-8&rls=GGGL,GGGL:2005-09,GGGL:en&q=wscript+excel on "wscript excel". Try that if you need more examples.
Reply #2 Top

I did check on dogpile and a few others with "vb+script+excel+cell" in the search engine and got some like that. I actually had trouble with even the diff between a " ' " and  a "rem" (to show as a remark. which shows how bad off I am learning this script stuff but looking at the one you link looks not to be too long. I'll letcha know


Thanks again !


 

Reply #3 Top

I did get a heck of a good hit on this script.


 


Set cnn = CreateObject("ADODB.Connection")


cnn.Open "Provider=Microsoft.Jet.OLEDB.4.0;" & _


               "Data Source=" & "[path to spreadsheet file]" & _


               "Extended Properties=""Excel 8.0;HDR=NO;IMEX=1"""


Set rst = cnn.Execute("Select * from [Sheet1$E785:E785]")


MsgBox rst.GetString


rst.Close


cnn.Close


Set cnn = Nothing


Set rst = Nothing


But I'm still no clue other than  : New object/edit script/copy/paste/try looking at other VB stuff within the desktopx world/smash head against wall/take valium.