Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello folks,
Looking for some help here, I've tried searching as I suspect this is a common problem, but I haven't been able to come up with an answer. I've inherited an excel file that links to data in access. It's got a macro that runs and it says there's a type mismatch on this command: MinDate = .Cells(3, 1).Value If I go into the debugger and just start the macro up again, it runs fine. So my problem is with that cell. In that cell is this: =Msaccess|'S:\PROD&QA\VA_proj\DATABASE\vaprog.mdb; Table Dateform Table'!All When the macro tries to get the value from that cell, there is a #N/A as the value. After the debugger opens, the value has changed to 12/1/2003, or a date. Any suggestions? thanks, Cameron |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Cameron wrote:
I've inherited an excel file that links to data in access. It's got a macro that runs and it says there's a type mismatch on this command: MinDate = .Cells(3, 1).Value Looks like the macro is running before the data has arrived. Maybe something like this Do While WorksheetFunction.ISNA(.Cells(3,1).Value) DoEvents Loop MinDate = .Cells(3, 1).Value Bill Manville MVP - Microsoft Excel, Oxford, England No email replies please - reply in newsgroup |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
That works, thanks Bill!!
Bill Manville wrote in message Looks like the macro is running before the data has arrived. Maybe something like this Do While WorksheetFunction.ISNA(.Cells(3,1).Value) DoEvents Loop MinDate = .Cells(3, 1).Value Bill Manville MVP - Microsoft Excel, Oxford, England No email replies please - reply in newsgroup |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Type mismatch... | Excel Discussion (Misc queries) | |||
Type Mismatch | Excel Worksheet Functions | |||
Sumif from VBA Type mismatch | Excel Worksheet Functions | |||
type mismatch--how to fix | Excel Discussion (Misc queries) |