I'm developing an ATL C++ COM object, and have created a function to be
called from an ASP page called:
GenerateNewOrder([in] BSTR uniqueID)
In this function all I want to do is insert a new record in the access
table name ORDERS, and fill in a particular field with the uniqueID (this
is the ONLY field set). None of the fields are required, and all can be
zero length; and there are no autonumber fields (1 date field, 2 currency,
1 memo, 17 text fields). I added an ATL Database Consumer to the project,
and can use it fine so far (when retrieving data).
In the function, if I use the consumer, following the guidelines
in "Beginning Components for ASP, Chapter 13 page 524", I get an error#
80004005. There is no further error information, it just doesn't add the
record. I'm using Personal Web Server for development.
If, in the function, I just open the datasource and use a SQL statement,
no error is generated (this is using an SQL insert statement).
Why does this happen? I really want to use the consumer templates, but
they don't seem to work for inserting.