Solved

Array dimensions do not match

Posted on 2004-09-07
6
736 Views
Last Modified: 2012-06-22
I have written this:

Private Sub Command0_Click()
Dim c As clsws_SFlow
Set c = New clsws_SFlow
Dim v As Variant
v = c.wsm_GetInstructionsTest("SSLConvey", "garnys", "courage")
MsgBox (v)
End Sub

Which calls:

Public Function wsm_GetInstructionsTest(ByVal str_sSource As String, ByVal str_sUser As String, ByVal str_sPass As String) As Variant
    '*****************************************************************
    'Proxy function created from http://195.217.202.154/application/cmti/webservice/searchflowws.asmx?wsdl.
    '
    '"wsm_GetInstructionsTest" is an array with elements defined as Variant
    'See Complex Types: Arrays in Microsoft Office 2003 Web Services Toolkit Help
    'for details on implementing arrays.
    '*****************************************************************

    'Error Trap
    On Error GoTo wsm_GetInstructionsTestTrap

    wsm_GetInstructionsTest = sc_SFlow.GetInstructionsTest(str_sSource, str_sUser, str_sPass)

Exit Function
wsm_GetInstructionsTestTrap:
    SFlowErrorHandler "wsm_GetInstructionsTest"
End Function


But i am getting the error "SoapMapper: Array dimensions do not match" from the line "v = c.wsm_GetInstructionsTest("SSLConvey", "garnys", "courage")"....help?
0
Comment
Question by:danBosh
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 18

Expert Comment

by:JR2003
ID: 11995344
Are you sure the error is not coming from this line?

wsm_GetInstructionsTest = sc_SFlow.GetInstructionsTest(str_sSource, str_sUser, str_sPass)
0
 
LVL 7

Expert Comment

by:_agj_
ID: 11995649
the error would be shown on the line as danBOsh says...because the error though generated by a function internal to this wsm_getinstructions function.

I guess you could try out the webservice internally to check if it works. The array might need to be implemented differently.
0
 

Author Comment

by:danBosh
ID: 11995936
What? so are u saying that the error is thrown from the webservice and not the code i have shown above?...
0
 
LVL 18

Accepted Solution

by:
JR2003 earned 50 total points
ID: 11996085
When an error is raised it has a .Source property and a .Desription property and a .ErrorNumber which contains the error number. If you include an error trap in each procedure you write it will be much easier to find the exact reason for the error. Here is some code you could paste into each of your functions:



    On Error GoTo Trap



    'Main body of code here
    '....
    '....
    '....
    '....

    GoTo SkipTrap

Trap:
   
    Dim iResult As VbMsgBoxResult
    With Err
        iResult = MsgBox("Error: " & .Number & vbNewLine & _
                "Description: " & .Description & vbNewLine & _
                "Source: " & .Source, vbAbortRetryIgnore Or vbExclamation, "Error")
        If iResult = vbRetry Then
            Resume
        ElseIf iResult = vbIgnore Then
            Resume Next
        End If
    End With

SkipTrap:

0
 
LVL 45

Expert Comment

by:patrickab
ID: 12683691
Today it is 26th November so I guess those 4 days have well and truly passed!
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
How to Add / Edit Windows Menu 4 73
Set email body to html using vbscript 6 70
Export Data to Different .csv Files 26 121
Fastest way to find and count same items VB6 16 43
There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
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…

740 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