|
-
Aug 8th, 2003, 10:19 AM
#1
Thread Starter
Junior Member
Really need help - ADODB problem when application implemented
Hi,
I have a client/server application that uses ADODB to communicate with an IBM iSeries server. It works fine at the office under either Win XP or Win2K, but when I installed the application on the client site for a demonstration, I got the following error:
System.InvalidCastException: QueryInterface for interface ADODB._Command failed at ADODB.CommandClass.set_CommandType (CommandTypeEnum plCmdType).
The error seems to be occurring when the ADO command object is set to a stored procedure command, as follows.
cmd.CommandType = CommandTypeEnum.adCmdStoredProc
Or at least that's where I think it's happenning, I don't have a log of exactly where the failure is. BUT the code works fine at the ranch, so it must be a PC config or deployment or DLL problem??
I installed the .Net Framework prior to installing the application, and the adodb.dll is deployed with the project, and I've verified that the dll is there, and at the same version as my development environment.
Please please help! I need to demo this app to the client on Monday morning!
Thanks in advance,
Liam.
-
Aug 8th, 2003, 04:51 PM
#2
Make sure they both have the same MDAC version. I don't know how to check the version but you can install MDAC 2.7 (I think that is the most recent version) on both or the one that is failing and see if that helps. Invalid cast kind of sounds like it is trying to use something from a newer version of MDAC than the one it has.
-
Aug 8th, 2003, 06:27 PM
#3
Thread Starter
Junior Member
Hi,
Good idea, but I already checked the MDAC, downloaded the latest version, and the installed said it was already at that version.
I'm in a helluva lot of trouble if I can't sort this by 9am Monday!
Regards,
Liam
-
Aug 9th, 2003, 05:51 PM
#4
Thread Starter
Junior Member
Please! Can anyone help me with this?
Folks,
I really need your help with this! I'm in a big jam - truly I am!
I need to sort this by Monday or my ass is on the line...
Please, if there are any ideas out there, let me know.
Hopefully yours,
Liam.
-
Aug 10th, 2003, 06:32 PM
#5
Hyperactive Member
just a thought try a simple test using an sql select without involivng stored procedure at least that way you know whether the problem is a general one rather than stored procedure specific.
-
Aug 11th, 2003, 04:58 AM
#6
Thread Starter
Junior Member
Hi,
Great idea, I'll give that a try.
The demo was postponed cos "I'm not feeling well today", which buys me some time.
I've managed to determine that the app will perfectly on a machine that has Visual Studio installed on it.
When I installed it on an office machine (Win2k Professional) that doesn't have VS on it, it gave me the same failure as on site. I installed the .Net Framework from the original VS CD prior to installing the app on the PC.
So the problem seems to be a deployment one - something is missing or not correctly installed when the app looks for it. The error is on ADO as posted in my original message, but the adodb.dll is deployed with the project, and I can see it there on the hard drive. So I haven't a clue what else could be missing!
Any ideas are appreciated!
Best regards,
Liam.
-
Aug 11th, 2003, 12:46 PM
#7
Thread Starter
Junior Member
Edneeis, you were absolutely right! I should have taken the time to read your posting more clearly.
I installed MDAC 2.7 and that fixed the problem. I thought on Friday that it was already at that version, but I was mentally fogged up at that time of the day & week.
Found the following at MSDN which might help next time someone has the same problem.
http://support.microsoft.com/default...b;en-us;815117
Many many thinaks for your help!
Best regards,
Liam.
-
Aug 11th, 2003, 12:50 PM
#8
Those deployment problem can be tricky I'm glad it was just the MDAC version.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|