{"id":21161,"date":"2022-04-11T13:55:52","date_gmt":"2022-04-11T11:55:52","guid":{"rendered":"https:\/\/help.openbee.com\/open-bee-scan-capture\/administrators-guide\/configuration\/general-setup\/output-setting\/windows-profile-on-premise\/"},"modified":"2022-04-11T13:55:52","modified_gmt":"2022-04-11T11:55:52","slug":"windows-profile-on-premise","status":"publish","type":"page","link":"https:\/\/help.openbee.com\/en\/open-bee-scan-capture\/administrators-guide\/configuration\/general-setup\/output-setting\/windows-profile-on-premise\/","title":{"rendered":"Windows Profile (On Premise)"},"content":{"rendered":"<div id=\"main-content\" class=\"wiki-content group\">\n<p>The Windows output allows Open Bee\u2122 Scan Capture to export the encoded video documents to a file tree. This output allows you to retrieve the pdf document. But it is also possible to generate a file that will contain the information of the document.<\/p>\n<p><span style=\"font-size: revert; color: initial;\">The user running the Open Bee\u2122 Scan Capture server service must have write and read rights to the destination folder in the tree.<\/span><\/p>\n<h2>Export Scheduling<\/h2>\n<p>For more details on how to schedule the output export, you can consult the <a href=\"https:\/\/help.openbee.com\/en\/open-bee-scan-capture\/administrators-guide\/configuration\/general-setup\/output-setting\/batch-export\/\">Batch Export<\/a> page<\/p>\n<h2 id=\"SortieWindows-Documentsenattente\">Pending documents<\/h2>\n<p>When you exit Open Bee\u2122 Scan Capture, you may see the following message. Documents have not been uploaded to Windows output because the document limit has not been reached, or the export is set up manually. If you want to export the documents, click yes to go to the document export page. Otherwise, you can click no to dismiss the message and exit Open Bee\u2122 Scan Capture.<\/p>\n<p><img decoding=\"async\" class=\"confluence-embedded-image image-center\" src=\"https:\/\/help.openbee.com\/wp-content\/uploads\/2022\/04\/264537613.jpg\" data-image-src=\"https:\/\/help.openbee.com\/wp-content\/uploads\/2022\/04\/264537613.jpg\"><\/p>\n<h1 id=\"SortieWindows-Fichierdeconfiguration\">Configuration file<\/h1>\n<p>The configuration of this output is done using the configuration located in <em>About \/ Maintenance \/ Configuration<\/em>.<\/p>\n<p>By default, this configuration contains:<\/p>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: text; gutter: true\" style=\"font-size: 12px;\">OutputRawXSLPath=\nOutputPDFFileNameXSLPath=~\/OutputFolder\/PdfFileName.xsl\nOutputXMLFileNameXSLPath=\ndateFormat=dd\/MM\/yyyy\ndecimalSeparator=.<\/pre>\n<\/div>\n<\/div>\n<p>The first 3 lines indicate xsl files. The following lines contain additional parameters related to the export of the document, such as the date format or the decimal separator.<\/p>\n<h1 id=\"SortieWindows-Destinationdesortie\">Output Destination<\/h1>\n<p>In the previous configuration, the output location is defined by the lines:<\/p>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: text; gutter: true\" style=\"font-size: 12px;\">OutputPDFFileNameXSLPath=~\/OutputFolder\/PdfFileName.xsl\nOutputXMLFileNameXSLPath=<\/pre>\n<\/div>\n<\/div>\n<p>Which respectively indicate the destination of the PDF document and the destination of the generated information file.<\/p>\n<p>The destination is expressed in the form of an xsl file that allows you to create a tree structure based on the information detected on the document by Open Bee\u2122 Scan Capture.<\/p>\n<div class=\"aui-message success shadowed information-macro\">\n<div class=\"message-content\">\n<p>The &#8220;~&#8221; sign at the beginning of the path is used to give the path from the current directory.<\/p>\n<\/div>\n<\/div>\n<h2 id=\"SortieWindows-Fichierd'information\">Information File<\/h2>\n<p>A file containing the document information can be generated by Open Bee\u2122 Scan Capture. To do this, it is necessary to provide a descriptor. This descriptor is also in xsl format.<\/p>\n<p>This file is defined by the line:<\/p>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: text; gutter: true\" style=\"font-size: 12px;\">OutputRawXSLPath=<\/pre>\n<\/div>\n<\/div>\n<p>If no file is populated, a document is still generated. It will contain all the information available on the document in raw form.<\/p>\n<h1 id=\"SortieWindows-DescripteursXSL\">XSL Descriptors<\/h1>\n<p>XSL descriptors are files that allow you to transform the raw information in the document into any other format.<\/p>\n<p><strong>Definition<\/strong> : XSL (eXtensible Stylesheet Language) is the W3C style sheet description language associated with XML. This is a file that describes how XML documents should be transformed.<\/p>\n<p>For more information: <a class=\"external-link\" href=\"https:\/\/www.w3.org\/TR\/xslt\" rel=\"nofollow\">https:\/\/www.w3.org\/TR\/xslt<\/a><\/p>\n<h2 id=\"SortieWindows-Notions\">Notions<\/h2>\n<h3>Simple Text<\/h3>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: xml; gutter: true\" style=\"font-size: 12px;\">&lt;xsl:text&gt;Text simple&lt;\/xsl:text&gt;<\/pre>\n<\/div>\n<\/div>\n<h3>Use a variable<\/h3>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: xml; gutter: true\" style=\"font-size: 12px;\">&lt;xsl:value-of select=\"Invoices\/Invoice\/Buyer\/MasterData\/Data[@Name='CODE_BUDGET']\/@Value\" \/&gt;<\/pre>\n<\/div>\n<\/div>\n<h3>Conditions<\/h3>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: xml; gutter: true\" style=\"font-size: 12px;\">&lt;xsl:if test=\"Invoices\/Invoice\/Buyer\/MasterData\/Data[@Name='CHEMIN_DE_SORTIE']\/@Value != ''\"&gt;\n&lt;\/xsl:if&gt;<\/pre>\n<\/div>\n<\/div>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: xml; gutter: true\" style=\"font-size: 12px;\">&lt;xsl:choose&gt;\n  &lt;xsl:when test=\"Invoices\/Invoice\/Buyer\/MasterData\/Data[@Name='CHEMIN_DE_SORTIE']\/@Value != ''\"&gt;\n    &lt;xsl:text&gt;J'ai un chemin&lt;\/xsl:text&gt;\n  &lt;\/xsl:when&gt;\n  &lt;xsl:otherwise&gt;\n    &lt;xsl:text&gt;Je n'ai pas de chemin&lt;\/xsl:text&gt;\n  &lt;\/xsl:otherwise&gt;\n&lt;\/xsl:choose&gt;<\/pre>\n<\/div>\n<\/div>\n<h3>Loops<\/h3>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: xml; gutter: true\" style=\"font-size: 12px;\">&lt;xsl:for-each select=\"Invoice\/Fields\/Field\"&gt;\n&lt;\/xsl:for-each&gt;<\/pre>\n<\/div>\n<\/div>\n<div class=\"aui-message success shadowed information-macro\">\n<div class=\"message-content\">\n<h3>Encoding issue:<\/h3>\n<p>To solve this problem, simply add as the first child of the Template node:<\/p>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: xml; gutter: true\" style=\"font-size: 12px;\">&lt;xsl:template match=\"\/\"&gt;\n  &lt;xsl:value-of select=\"'&amp;#xFEFF;'\"\/&gt;\n\t&lt;!-- Votre Code ... ---&gt;\n&lt;\/xsl:template&gt;<\/pre>\n<\/div>\n<\/div>\n<p>Or alternative:<\/p>\n<p>Replace<\/p>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: xml; gutter: true\" style=\"font-size: 12px;\">&lt;?xml version=\"1.0\" encoding=\"UTF-8\" ?&gt;<\/pre>\n<\/div>\n<\/div>\n<p>By<\/p>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: xml; gutter: true\" style=\"font-size: 12px;\">&lt;?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?&gt;<\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"aui-message success shadowed information-macro\">\n<div class=\"message-content\">\n<p>To insert a line break into a text-based output file:<\/p>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<h3 class=\"theme: Confluence; brush: xml; gutter: true\" style=\"font-size: 12px;\">&lt;xsl:text&gt;<br \/>\n&lt;\/xsl:text&gt;<\/h3>\n<\/div>\n<\/div>\n<\/div>\n<h3>Replacing a Character<\/h3>\n<p>Sometimes it can be useful to replace a character in a variable on the fly when exporting the document. A common example is the invoice number containing the &#8220;\/&#8221; character when used in the output path generation. In this situation, it is necessary to use a function:<\/p>\n<pre>&lt;xsl:stylesheet version=\"1.0\" xmlns:xsl=\"http:\/\/www.w3.org\/1999\/XSL\/Transform\"&gt;\n&lt;xsl:template name=\"string-replace-all\"&gt;\n&lt;xsl:param name=\"text\" \/&gt;\n&lt;xsl:param name=\"replace\" \/&gt;\n&lt;xsl:param name=\"by\" \/&gt;\n&lt;xsl:choose&gt;\n&lt;xsl:when test=\"$text = '' or $replace = ''or not($replace)\" &gt;&lt;!-- Prevent this routine from hanging --&gt;&lt;xsl:value-of select=\"$text\" \/&gt;&lt;\/xsl:when&gt;\n&lt;xsl:when test=\"contains($text, $replace)\"&gt;&lt;xsl:value-of select=\"substring-before($text,$replace)\" \/&gt;&lt;xsl:value-of select=\"$by\" \/&gt;&lt;xsl:call-template name=\"string-replace-all\"&gt;&lt;xsl:with-param name=\"text\" select=\"substring-after($text,$replace)\" \/&gt;&lt;xsl:with-param name=\"replace\" select=\"$replace\" \/&gt;&lt;xsl:with-param name=\"by\" select=\"$by\" \/&gt;&lt;\/xsl:call-template&gt;&lt;\/xsl:when&gt;\n&lt;xsl:otherwise&gt;&lt;xsl:value-of select=\"$text\" \/&gt;&lt;\/xsl:otherwise&gt;\n&lt;\/xsl:choose&gt;\n&lt;\/xsl:template&gt;\n&lt;xsl:variable name=\"newInvoiceNumber\"&gt;&lt;xsl:call-template name=\"string-replace-all\"&gt;&lt;xsl:with-param name=\"text\" select=\"Invoices\/Invoice\/Fields\/Field[@SubTypeName='INVOICE_NUMBER_INDEX']\/@Value\" \/&gt;&lt;xsl:with-param name=\"replace\" select=\"'\/'\" \/&gt;&lt;xsl:with-param name=\"by\" select=\"'_'\" \/&gt;&lt;\/xsl:call-template&gt;&lt;\/xsl:variable&gt;\n&lt;xsl:template match=\"\/Invoices\"&gt;\n  Nouveau num\u00e9ro : &lt;xsl:copy-of select=\"$newInvoiceNumber\" \/&gt;\n&lt;\/xsl:template&gt;\n&lt;\/xsl:stylesheet&gt;<\/pre>\n<h2 id=\"SortieWindows-Exemplecomplexe\">Complex example<\/h2>\n<p>Put the unique number of a document, 10 digits<\/p>\n<div class=\"code panel pdl\" style=\"border-width: 1px;\">\n<div class=\"codeContent panelContent pdl\">\n<pre class=\"theme: Confluence; brush: xml; gutter: true\" style=\"font-size: 12px;\">&lt;xsl:value-of select=\"substring(concat('0000000000', Invoices\/Invoice\/@ShortId), 1 + string-length(Invoices\/Invoice\/@ShortId), 10)\" \/&gt;<\/pre>\n<\/div>\n<\/div>\n<h2 id=\"SortieWindows-Liensutiles\">Useful links<\/h2>\n<p>To help you build .xsl files, you can use the online editor to test them: <a class=\"external-link\" href=\"https:\/\/www.w3schools.com\/xml\/tryxslt.asp?xmlfile=cdcatalog&amp;xsltfile=cdcatalog_if\" rel=\"nofollow\">https:\/\/www.w3schools.com\/xml\/tryxslt.asp?xmlfile=cdcatalog&amp;xsltfile=cdcatalog_if<\/a><\/p>\n<p>All you have to do is copy\/paste a RAW file into the XML code part and enter the contents of your xslt file in the XSLT part.<\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>The Windows output allows Open Bee\u2122 Scan Capture to export the encoded video documents to a file tree. This output allows you to retrieve the pdf document. But it is also possible to generate a file that will contain the information of the document. The user running the Open Bee\u2122 Scan Capture server service must [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":21152,"menu_order":1,"comment_status":"closed","ping_status":"closed","template":"templates\/ob-help-products.php","meta":{"footnotes":""},"class_list":["post-21161","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/pages\/21161","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/comments?post=21161"}],"version-history":[{"count":0,"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/pages\/21161\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/pages\/21152"}],"wp:attachment":[{"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/media?parent=21161"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}