Solved

VB Script on Win XP    .Parameters.Append .CreateParameter("@FirstName", adVarChar, adParamInput, 255)     bombs

Posted on 2006-06-13
8
1,559 Views
Last Modified: 2008-01-09
I think something might have changed in the way VBS is interpreted by WSH or ???

The line in the question title
.Parameters.Append .CreateParameter("@FirstName", adVarChar, adParamInput, 255)
bombs with the error "arguments of the wrong type, out of range or are in conflict with each other"

Any ideas???  Thanks,
0
Comment
Question by:FatalErr
  • 4
  • 3
8 Comments
 
LVL 35

Expert Comment

by:[ fanpages ]
ID: 16898670
What makes you believe this to be the case?

Have you upgraded your operating system, or version of Windows Scripting Host?

Or has the database structure changed & your parameter data type now does not match the database column?

BFN,

fp.
0
 
LVL 1

Author Comment

by:FatalErr
ID: 16898835
It used to run before I started working here (supposedly).  It doesn't work now and no modifications I make to it prevent the error from occuring.  That's why I suspect the WSH change.  It matches my database column.  I made a table with 1 column and edited the stored proc to have only one parameter.
0
 
LVL 35

Expert Comment

by:[ fanpages ]
ID: 16898845
Which version of WSH are you now using, and which version where you using prior to your current location?
0
 
LVL 1

Author Comment

by:FatalErr
ID: 16898859
How can I tell what version of WSH I'm using?   I have no info about the history.
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 16

Accepted Solution

by:
CWS (haripriya) earned 500 total points
ID: 16900666
Replace your code with this:

.Parameters.Append .CreateParameter("FirstName", adVarChar, adParamInput, 255,variable1)
0
 
LVL 35

Expert Comment

by:[ fanpages ]
ID: 16901396
What's "variable1"?
0
 
LVL 1

Author Comment

by:FatalErr
ID: 16904912
WSH (or whatever is handling this) won't evaluate the enums.  I used .Parameters.Append .CreateParameter("FirstName", 200, 3, 255) and it worked.  I went with the syntax suggestion because it was a syntax problem.  Thanks both of you for your help.  

0
 
LVL 35

Expert Comment

by:[ fanpages ]
ID: 16907758
Odd it worked before, and now it doesn't, in any respect.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now