Home |
Search |
Today's Posts |
#10
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
First of all, thanks for all your help guys. I've got some very useful stuff
to try now. TK - I would love to see any code that you've got. You can never have to many different examples of ways to do things I always say! As an aside I'll give you the brief of what I'm trying to accomplish. My data is split with details of Business Sector (Food, Electronics, Clothing for example), Stage (completed, outside deadline, outstanding), Source (Annual Report, News Item), Source Date (Now - 365) and Research Type (eg In house). I was going to use a recordset to set up a kind of pivot table that would provide me with a summary of the data. EG this macro would produce this table for all in house research: Source: Annual Report (date used to find latest) Sector Completed Outside Deadline Food 1 3 Electronics 7 0 Clothing 9 1 etc. This table would be produced for each sector/source and the figures are a count satisfying the 5 mentioned criteria. Does that make any sense? Hope so! If anyone can think of a better way to do it then I'd love to hear it? Thanks Paul "TK" wrote: Hi Paul: I played around with this and have some neet stuff if you are still working on it. Post back if you would like the code. Good Luck TK --------------------------------- "Paul" wrote in message ... Hi All, I could really use some help. I'm writing some VBA code in Excel and I want to use an ADO connection to the data to populate a number of recordsets but I'm having some trouble defining the connection. Does anyone know if there is an Excel equivilent of Access's CurrentProject? I can define a connection to the current database in Access like this: Dim conGlobalConnection as new ADODB.Connection conGlobalConnection.Open CurrentProject This is much like DAO's Currentdb. I would like to use the same in Excel but CurrentProject doesn't work and I can't find what it should be. I haven't tried just using the path as I'm not sure where the SSheet will end up and so would like to avoid declaring it that way, also I think the only time I've tried this in the past I got read only errors. Any help would be appreciated Many Thanks Paul |