Options

Document webservice page - Assign number Series for new doc

fehstcompfehstcomp Member Posts: 4
edited 2015-03-17 in NAV Three Tier
Hi all,

I have the following scenario:
- Dynamics Nav 2009 Classic client
- Dynamics Nav Web services
- Published a Transfer Header page (Page ID 5740) as a web service.
- We have two different number series for Tranfers, one for internal transfer and other for consignments for customers.

I'm trying to create a Transfer document via the webservice (using a C# application I'm developing, which uses the webservice), but I need the transfer to have a number in the number series for the consignments, and when I call Webservice.Create() it always assigns a number in the internal transfer number series.
I've tried modifying the "No. Series" field via C/SIDE on the Page but it ignores whatever i put in there and keeps assigning the next number from the "wrong" series.
It also ignores whatever is on the object which is passed to the Create method of the webservice.
I have searched mibuso and other sites, but I've been unable to find a way to sort this out. It is the only thing which is preventing me from having a working application, which is needed to streamline consigment generation from the orders, but I need to create a transfer document on the correct number series.

Any ideas?
Thanks in advance for any help.

Regards,
Antonio

[NOTE: I have posted this also in the NAV Classic topic but I've seen now that I should have posted it here.]

Comments

  • Options
    yukonyukon Member Posts: 361
    Hi,

    If i'm not wrong someone already post similar question on forum. Webservice.Create() method is ignore your per-defined value. In order to get your requirement you can do below method.

    1. Separate the page and define the "No. Series" for each type. But it's hard code and it will work for 2 no. series.
    You need to assign the no. series at "On New Record Trigger" in the page and amend the code inside the Table as well.

    2. Use the code unit and create the doc. base on your requirement and read back the doc. in your app and process the other step.


    Best Regards,
    Yukon
    Make Simple & Easy
Sign In or Register to comment.