Welcome
  Your Account | Cart Cart | Wish List | Help |
10 new deals await you in your Gold Box
Gold Box
Program
Overview
MarketplaceAssociatesAdvantageWeb
Services
Paid
Placements
Search     
Web Search
 
Amazon.com 
View CartWish ListYour AccountHelp

Amazon.com Associates: XML Developers


Back To Discussion List

 
Launch of new Amazon Web Services forums |  AWS Blog  |  AWS FAQs  
 General (Read-Only Folder) -  ECS4 WSDL & .NET Compatibility Issues 
 
From: Amazon Web Services  Staff 10/28/2004 8:12 pm 
To: ALL  (1 of 12) 
 6777.1 

Hi everyone,

The 4.0 version of the ECS WSDL is not compatible with Microsoft’s Visual Studio.NET 2003. We are working with Microsoft to fix these issues. In the meantime, we have provided workarounds that you can implement within your application to help you build your VS.NET application

CustomerReviews unique name issue:

When you run your application, Microsoft’s runtime framework will display the following error.

"Server Error in /XXX Application
Types XXX.WebReference.CustomerReviews1 and XXX.WebReference.CustomerReviews both use the XML type name, CustomerReviews, from namespace
http://webservices.amazon.com/AWSECommerceService/2004-10-19 Use XML attributes to specify a unique XML name and/or namespace for the type."

Workaround:

  1. Double click on "Web References" in your VS.NET solution.
  2. Double click on the "WebReference" object and the Object Browser window should open up.
  3. In the Object Browser window’s left pane, double click on the object with the same name as your application. This should expand the list tree. Double click on the <YourAppNameHere>.WebReference object and this should expand to a list of objects starting with "AccessoriesAccessory".
  4. In this list of objects, double click on AWSECommerceService. This should open up the source code file that VS.NET generates when it parses the WSDL. Search for "public class CustomerReviews1". You should see the following lines of code.

    [System.Xml.Serialization.XmlTypeAttribute(TypeName="CustomerReviews", Namespace="http://webservices.amazon.com/AWSECommerceService/2004-10-19")]

    public class CustomerReviews1 {
     
  5. Replace the TypeName="CustomerReviews" with TypeName="CustomerReviews1".
  6. Save this file.

 

Dependencies not found issue:

On running your application, Microsoft’s runtime framework will display the following error.

"Server Error in /XXX Application
File or Assembly name yyy.dll, or one of its dependencies, was not found."

(The name of the file (yyy) is not fixed and will vary for every execution run.)

Workaround:

  1. Follow the instructions above to open the AWSECommerceService class generated by VS.NET.
  2. Search for "public string[][] Request;". You should see the following lines of code.

    [System.Xml.Serialization.XmlArrayItemAttribute("BrowseNodeId", typeof(string), IsNullable=false)]

    public string[][] Request;

  3. Modify these lines to

    [System.Xml.Serialization.XmlArrayItemAttribute("BrowseNodeId", IsNullable=false)]
    public string[] Request;

  4. Save this file.

 

 
   Options 
  

 
From: nomolos2  10/29/2004 9:33 am 
To: Amazon Web Services  (2 of 12) 
 6777.2 in reply to 6777.1 

Thanks for the help with the .net issue, it is greatly appreciated.  Is there any way you could paste just a very small piece of code that returns 1 value from the ECS feed using XPATH?  Preferably the large request type. 

I have spent over 20 hours trying to figure out what's wrong with my code.  At this point, I doubt my code is the problem.

 
   Options 
  

 
From: elena-d  10/29/2004 12:38 pm 
To: nomolos2 unread  (3 of 12) 
 6777.3 in reply to 6777.2 

Hi nomolos2,

I just answered your question here:

http://forums.prospero.com/n/mb/message.asp?webtag=am-assocdevxml&msg=6784.2&ctx=0

Please post back if this does not work for you!

-elena

 
   Options 
  

 
From: mallsocket  11/8/2004 1:46 am 
To: Amazon Web Services  (4 of 12) 
 6777.4 in reply to 6777.1 
Actually, I can't get that fixed the way you have it outlined, at least not in VS 2003. Saving the files does nothing.

Here's how I do it: Add the web reference by importing the WSDL in VS 2003. Make a note of the name that VS gives to the web reference. Open Solution Explorer in your VS 2003 project and click the Show All Files icon.

Click Web References and keep opening nodes until you find the file Reference.cs that appears below Reference.map under the Version 4 WSDl that you just imported.

Then search for and replace the strings just as given in the title article in this thread.

Then compile the application. If you get an error, and Undo doesn't help, delete the web reference and reimport it and try again. You should get no compile errors if you replace the code exactly as specified.

Compiling the application also saves the file.

John

 
   Options 
  

 
From: Amazon Web Services  Staff 11/8/2004 2:38 am 
To: mallsocket  (5 of 12) 
 6777.5 in reply to 6777.4 

John,

Thanks so much for clarifying the workaround for VS 2003! Greatly appreciated!

-elena

 

 
   Options 
  

 
From: salim  11/8/2004 9:15 am 
To: Amazon Web Services  (6 of 12) 
 6777.6 in reply to 6777.1 
CAN SAVE THE FILE DO YOU KNOW WHY
 
   Options 
  

 
From: shrenik4you  11/18/2004 5:02 am 
To: Amazon Web Services  (7 of 12) 
 6777.7 in reply to 6777.1 

Hello AWS Team,

Error Observed: Method AWSECommerceService.CustomerContentSearch can not be reflected.

To my understanding, the above error appears on Visual Studio .NET 2003 when an instance of AWSECommerceService is being created.

The problem seems to be a bit more than that. The error appears ONLY in Windows Application and Web Application projects.

I added a Web Reference to a Smart Device Application project, and the thing worked perfectly fine. So, it is not just a VS.NET issue. Anyways, I hope this helps someone.

Shrenik

 
   Options 
  

 
From: tamebooks  12/2/2004 12:55 pm 
To: Amazon Web Services  (8 of 12) 
 6777.8 in reply to 6777.1 

Okay, I got these workarounds to work.

TypeName:=CustomerReviews1

But in ESC4 2004-11-10 there is no public string()() request, it's

public request()() as string  -- instead (below BrowseNodeId).

Change to:  public request() as string.

I did those two fixes and ESC4 now works in a VB.Net Windows application.

Or maybe elena just made a typo in the first place. :-) But I thought I'd post the correction to the correction, because I just spent about two hours figuring it out (well, an hour and a quarter). Save the generated Amazonproxyclass.vb and recompile your app and it should work.

tamebooks

 

 

 
   Options 
  

 
From: khanfareedali  12/28/2004 2:19 am 
To: tamebooks unread  (9 of 12) 
 6777.9 in reply to 6777.8 

Hi,

  I got this error after applying your instruction:

Types CustomerReviews1 and CustomerReviews both use the XML type name, CustomerReviews, from namespace http://webservices.amazon.com/AWSECommerceService/2004-11-10. Use XML attributes to specify a unique XML name and/or namespace for the type.

 

 
   Options 
  

 
From: elena-d  Staff 12/28/2004 3:24 pm 
To: khanfareedali unread  (10 of 12) 
 6777.10 in reply to 6777.9 

Umm, looks like XML type CustomerReviews1 is not found. Can you double-check step 5 from 1st message of this thread? Also, make sure you saved and re-compiled generated proxy.

-elena

 

 
   Options 
  

Navigate this discussion:  1-10 11-12
Rate My Interest:
   
Adjust text size:
Is this too complicated? Switch to Basic View

Launch of new Amazon Web Services forums |  AWS Blog  |  AWS FAQs  

Amazon.com Home |  Your Store |  Books |  Music |  DVD  |  Video  |  Movie Showtimes  |  Magazine Subscriptions |  Toys & Games |  Baby |  Electronics |  Camera & Photo |  Computers |  Software |  Computer & Video Games |  Cars |  Cell Phones |  Travel |  Kitchen & Housewares |  Target |  Tools & Hardware |  Outdoor Living |  Health & Beauty  |  Outlet |  Corporate Accounts |  Auctions |  zShops  |  Gifts & Gift Certificates |  e-Cards  |  1-Click Settings
Shopping Cart |  Your Account |  Help |  Sell Items

Our International Sites: United Kingdom, Germany, France, Japan

Conditions of Use | Privacy Notice © 1996-2003, Amazon.com, Inc. or its affiliates