• RE: URL Creator -- Pass query without Base64 encoding?

    We have solved this using a webservice, because while being able to build an url from a template, our customer's ERP also wasn't able to base64 encode on the fly.

    We have pointed the url template to the webservice instead.
    The ERP is sending the parameters it has available to the webservice which in turn queries the DocuWare System for a result list of of documents meeting the parameter criteria. It then uses the URL Integration API to create the encoded URL.
    Finally, the webservices answers the ERP System with an http redirect giving the encoded URL as a "new" address.

  • RE: .NET API Get List of Fields in File Cabinet or Tray

    The thing with the .Net Api is, that whenever you're dealing with one of the entities of the DocuWare System (FileCabinets, DocumentIndexFields, Documents, etc...) in Your code, You may or may not have the full entity.

    In Your case, You are asking the organization for it's FileCabinets, and then each FileCabinet for it's Fields. The FileCabinet instance you have in Your inner ForEach loop is not the full entity, and it's Fields property (and other properties) have not been filled. That's why You're getting a field Count of 0.

    In order to make sure that You have the full entity of the FileCabinet, call the GetFileCabinetFromSelfRelation() Method on the FileCabinet itself.
    So I guess your first statement in the if-clause should be something like:

    fc = fc.GetFileCabinetFromSelfRelation()

    Although I'm not sure about VB Syntax. After that, the Fields property should hold all IndexFields. 
    BeWare that it will also hold the IndexFields ceated by the System, like DWDOCID, DWEXTENSION, etc. You can filter the Fields for their "Scope" property in order to get only the Fields that are explicitly created in the configuration.

  • RE: Workflow Designer - Wiedervorlage erstellen

    Hallo Nicole,

    Ich nehme an, Sie verfügen über die Information, an welchem Tag die Zahlung fällig ist. Wahrscheinlich steht sie in einem Indexfeld, und wahrscheinlich ist es vom Typ "Datum".

    Die Aktivität "Zeitverzögerung" benötigt, wie Sie bereits feststellen, eine globale Variable, und diese muss vom Typ "Datum mit Zeit" sein. Der Variablentyp "Datum" reicht nicht aus.

    Man kann den Inhalt eines Datums-Indexfelds (z.B. Fälligkeit) mit einer "Daten zuweisen"-Aktivität direkt in eine gloable Variable vom Typ "Datum mit Zeit" schreiben, dann wird aber für den Uhrzeit-teil 12:00 Uhr UTC verwendet, was bei mitteleurop. Winterzeit zu 13:00 Uhr am Datum des Indexfelds führt. Das führt in der Aktivität "Zeitverzögerung" dazu, dass diese erst Mittags auslöst.
    Daher empfehle ich, die Funktion DateTimeAtMidnight zu verwenden, damit dies bereits Nachts passiert.
    Suchen Sie im Partnerportal nach dem Dokument "Workflow Expression Parser" o.ä., um dazu Hilfe zu bekommen.

    Die Aktivität "Zeitverzögerung" dürften Sie dann direkt nach der Aufgabe einsetzen, die den Stempel "gebucht" aufbringt. Wählen Sie in dieser Aktivität "Zeitverzögerung" und die globale Variable mit Datum und Uhrzeit.
    Danach dürfte wohl eine neue Aufgabe "Zahlung" o.ä. anstehen, eventuell eine neue Zuweisung. 


  • RE: REST API - Logon Issue

    Hello @Robby Osting,

    Here are my funtions for Logging in and Logging out, that I like to use in my powershell scripts:

    $cookie = New-Object Microsoft.PowerShell.Commands.WebRequestSession

    function Login{
      Invoke-WebRequest `
      "$($dwurl)/Account/Logon" `
      -Method Post `
      -Headers @{ `
          'Content-Type' = 'application/x-www-form-urlencoded'; `
          'Accept' = 'application/json'; } `
      -Body @{ `
          'UserName' = $($username); `
          'Password' = $($password); `
          'Organization' = $($org_name); `
          'RedirectToMyselfInCaseOfError' = 'false'; `
          'RememberMe' = 'false'; `
          'HostID' = '7b5ed19b-bfd6-46e9-8a3b-efd2a4499666'; `
          'LicenseType' = 'PlatformService'; } `
      -WebSession $cookie

    function Logout{
      Invoke-WebRequest "$($dwurl)/Account/Logoff" `
      -Method Get `
      -WebSession $cookie

    They use a few variables for the url, username, password, etc.

    Please note the variable "$cookie". 
    In between logging in and logging out, I send this with every Invoke-WebRequest that I make to do the actual work I want to do.

    What does the html response aou are receiving contain?
    I suspect there is an issue with licensing?

  • RE: Role or Group as select list

    I agree, however I believe Your second statement (mapping users to roles) is neglecting that users can be members of a role not through direct membership (reflected in table DWUserToRole) but through being a member of a group which in turn is a member of the role "DesiredRoleName".

    However, in 7.3 on-premise systems You can leverage the new possibility to create filtered select lists.

    I create a view on the database that maps users and the roles they are members in. For this,I use a UNION statement to basically combine Your statement with a similar statement that joins users to roles via group memberships.
    Then I create filtered select lists using the view as a data source where I filter for the desired role name to get a select list of all users that have a membership in that role.

  • RE: REST API - Logon Issue

    Hello Adriano,

    > The main problem when I use REST API and I logon and logut several times I get an 401 Unauthorized Exception that makes the API completely unusable.

    Are You sure You are logging out correctly? 
    I mainly use powershell to do my REST API stuff, always resending the cookie I have created on login, like You said, but as long as I log out when my work is done, I can rerun my scripts as often and as fast as I like without getting a 401.

    Logging on several times without logging out will eventually return a 401.
  • RE: Workflow, Daten zuweisen, Belegdatum wird nicht korrekt übergeben, Formatierungsfehler?

    Hallo Frau König,

    Der Fehler liegt im Workflow Designer.

    Leider hat die Testfunktion des Workflow Designers auch für mich nur selten das gehalten, was Sie verspricht. Insbesondere mit Indexfeldern vom Typ Datum oder mit der Archiv-Operation aus der Aktivität "Daten zuweisen".

    Hier bleibt leider nichts anderes übrig als den Workflow zu veröffentlichen und im Archiv zu testen, was i.d.R. die erwarteten Ergebnisse bringt. 
    Mit month(DW_DOCUMENT_DATE) sind Sie aus meiner Sicht auf dem richtigen Weg, um die Monatsziffer zu erhalten. Ein Casting mit CStr sollte gar nicht notwendig sein.
  • RE: Change index field of several documents in workflow

    If this is an On Premise system, You could use a database trigger to do the same thing the AutoIndex would do.