When you use the Datastream Event Study Matching Tool, you can get the error message “Run-time error ‘1004’: Application-defined or object-defined error’. When you click the button Debug you’ll see there is ‘something’ wrong with the dates (but what?).
From what we have seen this error message appears when there is no data or not enough data for a particular company in the requested window, often because the base date of the serie in Datastream is after the event date entered in the tool.
You can solve this by deleting that particular event from your list of events and running the tool again. This can be very time consuming and you have to check for other events as well.
You can also do this: leave all events in your list, but before hitting the button Process Table in the tool, in the sheet REQUEST_TABLE, click the button Options and enter something in the box No data string (for example NA). Datastream will put NA in cells without data, and the macro in the Event Study Matching Tool will return NA’s in the output of the tool. This allows the macro to run with (hopefully) not run-time errors and you can easily find the events you have to delete in the output.