Show / Hide Table of Contents

    Retrieve Next Sequence Element

    This example shows how to retrieve next element from a predefined sequence.

    Retrieve Next Sequence Element

    In some cases the DocuWare client applications would like to retrieve an element from a predefined sequence. This example shows how this could be done.

    C#

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    using DocuWare.Platform.ServerClient;
    
    namespace DocuWare.PlatformClientExamples
    {
        static partial class ExamplesAsync
        {
            /// <summary>
            /// Retrieves the next sequence element.
            /// </summary>
            /// <param name="cabinet">The file cabinet for which the sequence is created.</param>
            /// <param name="sequenceId">The GUID of the sequence.</param>
            /// <returns>Returns the next sequence element.</returns>
            public static string GetNextSequenceElement(FileCabinet cabinet, string sequenceId)
            {
                SequenceResult result = cabinet.PostToNextSequenceElementRelationForSequenceResult(new SequenceRequest() { SequenceId = sequenceId });
    
                return result.NextElement;
            }
        }
    }
    
    About Us Contact Imprint Terms Data privacy
    © 2024 DocuWare Corporation powered by DocFX Back to top