Can't add a web refence in ASP.NEt 3.5 for a few web service

netblazernetblazer Member Posts: 26
edited 2010-01-18 in NAV Three Tier
I'm working with Nav 2009 SP1. Everything installed locally on XP SP3 32 bit.

I'm able to reference and consume the client page. I'm also able to create a sales order with web services however I have a few web services that I cannot even even add as refference.

One of them is coude unit 396 (NoSeriesManagement).

To duplicate the error :
In VS 2008 in ASP .NET C# web application

Right click on the application
Add web reference
Navigate to exposed services list at http://localhost:7047/DynamicsNAV/WS/Test/services
I see 13 exposed web services which is correct and matches Nav perfectly
When I click on View Service for the Service Noseriesmanagement I get this error and I can't go any further :

- <s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/"&gt;
- <s:Body>
- <s:Fault>
<faultcode xmlns:a="urn:microsoft-dynamics-schemas/error">a:Microsoft.Dynamics.Nav.Service.WebServices.ServiceBrokerException</faultcode>
<faultstring xml:lang="fr-CA">Parameter noSeriesLine of the type INavRecordHandle in method SetNoSeriesLineFilter in service Noseriesmanagement is invalid!</faultstring>
- <detail>
<string xmlns="http://schemas.microsoft.com/2003/10/Serialization/">Parameter noSeriesLine of the type INavRecordHandle in method SetNoSeriesLineFilter in service Noseriesmanagement is invalid!</string>
</detail>
</s:Fault>
</s:Body>
</s:Envelope>


Thanks in advance for any possible solution.

Comments

  • ara3nara3n Member Posts: 9,255
    There are a lot of Codeunits that you cannot add as web service. Main reason is that they contain parameters that are complex type.

    I suggest to create a CU in 50K range that can used for what ever purpose you want and it will reference Number series CU.
    Ahmed Rashed Amini
    Independent Consultant/Developer


    blog: https://dynamicsuser.net/nav/b/ara3n
  • KerbrusKerbrus Member Posts: 2
    The parameters can't be Record type in any function of codeunit, even you don't call those functions in web service. As Rashed mentioned, just copy the function to a new codeunit then it should work fine.
  • netblazernetblazer Member Posts: 26
    Thanks, that does the trick.


    Do you guys know any site with detailed info about Navision services and code units... like a faq and or descriptions of what each code unit does?
  • ara3nara3n Member Posts: 9,255
    Most of the Codeunits are self explanatory.
    I think if you get a hold of a NAV developer, they can give you a 1 hour lecture of a big picture of how Codeunits are structured and get used during posting.


    As for finding where is what referenced, you can use developer toolkit.
    Ahmed Rashed Amini
    Independent Consultant/Developer


    blog: https://dynamicsuser.net/nav/b/ara3n
Sign In or Register to comment.