Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP 3 Classic ASP Active Server Pages 3.0 > Classic ASP Components
Password Reminder
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Classic ASP Components Discussions specific to components in ASP 3.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Components section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old March 27th, 2013, 10:45 AM
Registered User
Points: 5, Level: 1
Points: 5, Level: 1 Points: 5, Level: 1 Points: 5, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Mar 2013
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default ClassicASP C# COM VBScript runtime error: Invalid procedure call or argument

Hi Classic ASP Experts,

I am new to VBScript, COM and Classic ASP. I am getting Microsoft VBScript runtime error: Invalid procedure call or argument, while trying to pass an argument of type class to the COM method call. Although the object is created and the Visual Studio intellisense shows the method name along with parameter. I am not able make procedure call or argument.

What am I missing?

Please help.

Here's my VBScript (ClassicASPHome.asp):

response.write("My first ASP script!")

set co = Server.CreateObject("ClassicASPCOM.ComplexObject")
co.Message = "Messi"
co.Number = 100

Dim ccom
Set ccom = Server.CreateObject("ClassicASPCOM.ClassCOM")


'---------------Works fine till here

Dim ret

' ---------------The following statement throws error

ret = ccom.PaymentDetails(co)


Code Snippet:

// C# Code (ClassicASPCOM.dll) built with Strong Name and Registered for COM Interop:

// Executed the following in Visual Studio Command Prompt in bin\Release folder
// Regasm ClassicASPCOM.dll

// Regasm ClassicASPCOM.dll /codebase

// Regasm ClassicASPCOM.dll /tlb

// gacutil/i ClassicASPCOM.dll

using System;
using System.Runtime.InteropServices;

namespace ClassicASPCOM
public interface IComplexObject
int Number {get; set;}
string Message { get; set; }
DateTime Dtime { get; set; }

public class ComplexObject : IComplexObject
int Nmbr;
public int Number
return Nmbr;
Nmbr = value;

string Msg;
public string Message
return Msg;
Msg = value;

DateTime Dt;
public DateTime Dtime
return Dt;
Dt = value;

public interface IGetMessage
string GetMessage(string Message);
string PaymentDetails(ComplexObject cObject);

public class ClassCOM : IGetMessage
public string GetMessage(string Message)
return "Your Message: " + Message;

public string PaymentDetails(ComplexObject cObject)
return " Message: " + cObject.Message + " Number: " + cObject.Number;


Last edited by recherche; March 28th, 2013 at 04:36 AM..

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Invalid Procedure Call dlandolin Access VBA 4 June 9th, 2011 08:52 AM
Error: Invalid postback or call back argument kalyanykk ASP.NET 2.0 Basics 0 August 26th, 2008 06:03 AM
java.sql.SQLException: Invalid argument(s) in call dharmendra_rh Java Databases 1 May 5th, 2005 02:58 AM
Invalid procedure call Error pavel Pro VB 6 2 January 30th, 2004 10:00 AM
Invalid procedure call or argument: 'AscB' harish3699 VBScript 1 January 28th, 2004 01:29 PM

All times are GMT -4. The time now is 05:32 PM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.