PDA

View Full Version : [SOLVED] Is it possible to code this !!!!



mercmannick
07-28-2005, 11:16 AM
:dunno

i have a shared workbook on a networked drive,

i would like to be able to grab some specific dat from this file without opening it ?

the data i require though is only identifiable as interior colour red , any other data in this col i would like to ignore,

would like to be able to copy entire row and put in new workbook.

basically this sheet (networked one) i would normally put a autofilter on and on col c pick which section i am looking at at time, ie: workcentres "S17", filter to just these , then look in col j and if it is highlighted red then copy this row to a new workbook and so on,


any help would be appreciated

Merc

:banghead:

OBP
07-28-2005, 03:13 PM
You can code it, but as far as I know the Code would have to open the file. You would not have to be involved in this action.

Bob Phillips
07-28-2005, 05:02 PM
:dunno

i have a shared workbook on a networked drive,

i would like to be able to grab some specific dat from this file without opening it ?

the data i require though is only identifiable as interior colour red , any other data in this col i would like to ignore,

would like to be able to copy entire row and put in new workbook.

basically this sheet (networked one) i would normally put a autofilter on and on col c pick which section i am looking at at time, ie: workcentres "S17", filter to just these , then look in col j and if it is highlighted red then copy this row to a new workbook and so on,

You could use ADO to read the workbook even if closed, but this only reads data, it won't get presentational attributes.

mercmannick
07-28-2005, 10:28 PM
can you show me an example of code to get me started ?

Merc

Marcster
07-29-2005, 01:42 AM
Have a look at these links to see if they help you:

http://www.j-walk.com/ss/excel/tips/tip82.htm
http://www.rondebruin.nl/ado.htm

Justinlabenne
07-29-2005, 06:41 AM
Just out of curiousity, why do you want to avoid opening it?

here is the kb entry for what you are asking. Link (http://www.vbaexpress.com/kb/getarticle.php?kb_id=454)



Also for clarity: Cross-Posted here (http://www.mrexcel.com/board2/viewtopic.php?t=159933)

mercmannick
07-29-2005, 07:45 AM
to be honest i am not bothered if i have to open workbook get data then close just not sure on coding the autofilter bit and the interior cell bit

any help would be good

Merc