Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 64873
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 10, 20262026-05-10T18:51:29+00:00 2026-05-10T18:51:29+00:00

I’m having the problem described here: http://groups.google.com/group/microsoft.public.xml.soap/browse_thread/thread/029ee5b5d4fa2440/0895d73c5c3720a1 I am consuming a Web Service using

  • 0

I’m having the problem described here:

http://groups.google.com/group/microsoft.public.xml.soap/browse_thread/thread/029ee5b5d4fa2440/0895d73c5c3720a1

I am consuming a Web Service using Office 2003 Web Services Toolkit. This generates classes for all the data returned by my web service: one of the classes has a property that is an array which may be empty.

When I call the web service, the Generic Type Mapper raises an error:

array dimensions do not match definition 

Does anyone know of a solution to this problem that allows me to keep using the generated classes (I know I could just consume the raw XML)?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-10T18:51:30+00:00Added an answer on May 10, 2026 at 6:51 pm

    Since there are no takers, I’ll describe what I’ve done to date in case anyone else has a similar issue.

    On my client (using Office 2003 Web Services Toolkit) I want to receive a collection of objects which have a property that itself is a collection of objects. For example, a collection of Customer objects from a C# web service where the Customer class looks something like:

    public class Customer {     public string Name { get; set; }      public Collection<Address> Addresses { get; } } 

    The problem I have is that the Addresses property can sometimes be an empty collection, and the SOAP30 GenericTypeMapper is not able to handle this.

    In my specific case, the client did not actually need the collection of addresses, I just want to be able to get the other properties of the Customer class. So I don’t really care what’s in the ‘Addresses’ variant property that’s created by the Web Services Toolkit.

    What I’ve done is create a VB6 ActiveX DLL with a class with a minimalist implementation of ISoapMapper that always returns an uninitialized object reference:

    Implements ISoapTypeMapper Private Function ISoapTypeMapper_Iid() As String End Function Private Sub ISoapTypeMapper_Init(ByVal par_Factory As MSOSOAPLib30.ISoapTypeMapperFactory, ByVal par_Schema As MSXML2.IXMLDOMNode, ByVal par_WSMLNode As MSXML2.IXMLDOMNode, ByVal par_xsdType As MSOSOAPLib30.enXSDType) End Sub Private Function ISoapTypeMapper_Read(ByVal par_soapreader As MSOSOAPLib30.ISoapReader, ByVal par_Node As MSXML2.IXMLDOMNode, ByVal par_encoding As String, ByVal par_encodingMode As MSOSOAPLib30.enEncodingStyle, ByVal par_flags As Long) As Variant     Set ISoapTypeMapper_Read = Nothing End Function Private Function ISoapTypeMapper_SchemaNode() As MSXML2.IXMLDOMNode  Set ISoapTypeMapper_SchemaNode = Nothing End Function Private Function ISoapTypeMapper_VarType() As Long    ISoapTypeMapper_VarType = vbObject End Function Private Sub ISoapTypeMapper_Write(ByVal par_ISoapSerializer As MSOSOAPLib30.ISoapSerializer, ByVal par_encoding As String, ByVal par_encodingMode As MSOSOAPLib30.enEncodingStyle, ByVal par_flags As Long, par_var As Variant) End Sub Private Function ISoapTypeMapper_XsdType() As MSOSOAPLib30.enXSDType     ISoapTypeMapper_XsdType = enXSDUndefined End Function 

    Then I modified the WSML generated by the Web Services Toolkit to use this implementation for the appropriate property:

    Dim str_WSML As String str_WSML = '<servicemapping>' str_WSML = str_WSML & '<service name='MyService'>' str_WSML = str_WSML & '<using PROGID='MSOSOAP.GenericCustomTypeMapper30' cachable='0' ID='GCTM'/>' str_WSML = str_WSML & '<using PROGID='SoapHelper.EmptyArrayMapper' cachable='0' ID='EATM'/>' ' <== Added this line str_WSML = str_WSML & '<types>' ... str_WSML = str_WSML & '<type name='ArrayOfAddress' targetNamespace='http://...' uses='EATM' targetClassName='struct_Address'/>'  '<== Added this line str_WSML = str_WSML & '<type name='Address' targetNamespace='http://mynamespace.com/myapp/services/data' uses='GCTM' targetClassName='struct_Address'/>' ... 

    This achieved what I needed for this application.

    It seems to me that it may be possible to achieve support for empty arrays more generally by implementing ISoapMapper in such a way that:

    • It detects and handles the case of an empty array.

    • Or if the array is non-empty it delegates to the standard GenericTypeMapper.

    I’d still be interested to hear if anyone has solved the general problem. Possibly not as the SOAP client is obsolete and no longer supported by Microsoft.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 62k
  • Answers 62k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • added an answer You need to specify the full type name to Type.GetType(),… May 11, 2026 at 10:01 am
  • added an answer <TabControl x:Name='_tabControl' ItemsSource='{Binding PageModels}'> <TabControl.ItemContainerStyle> <Style TargetType='TabItem'> <Setter Property='Header' Value='{Binding… May 11, 2026 at 10:01 am
  • added an answer This may work better. [a-zA-Z]+\.Strings\s*=\s*\(([^)])+)\) Also, how are you dealing… May 11, 2026 at 10:01 am

Related Questions

I keep getting tasks that are above my skill level. How can I address this without coming accross as grossly incompetent?
I have a web-service that I will be deploying to dev, staging and production.
I'm thinking of starting a wiki, probably on a low cost LAMP hosting account.
I have the following tables in my database that have a many-to-many relationship, which
I'm using the RESTful authentication Rails plugin for an app I'm developing. I'm having
I recently printed out Jeff Atwood's Understanding The Hardware blog post and plan on
I find that getting Unicode support in my cross-platform apps a real pain in
I would like to test a string containing a path to a file for
I'm getting this problem: PHP Warning: mail() [function.mail]: SMTP server response: 550 5.7.1 Unable
I'm an Information Architect and JavaScript developer by trade nowadays, but recently I've been

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.