Skip to content

Commit

Permalink
v5.6.16439.0
Browse files Browse the repository at this point in the history
  • Loading branch information
ITHitBuild committed Jul 16, 2022
1 parent c0983a8 commit ba06158
Show file tree
Hide file tree
Showing 20 changed files with 43 additions and 372 deletions.
2 changes: 1 addition & 1 deletion Common/Common.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@
<Platforms>AnyCPU;x64</Platforms>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="ITHit.FileSystem" Version="5.6.16427.0" />
<PackageReference Include="ITHit.FileSystem" Version="5.6.16439.0" />
</ItemGroup>
</Project>
4 changes: 2 additions & 2 deletions Windows/Common/Core/Common.Windows.Core.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
<PackageReference Include="Microsoft.Windows.SDK.Contracts" Version="10.0.19041.1" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ITHit.FileSystem.Windows.Package" Version="5.6.16427.0" />
<PackageReference Include="ITHit.FileSystem.Windows" Version="5.6.16427.0" />
<PackageReference Include="ITHit.FileSystem.Windows.Package" Version="5.6.16439.0" />
<PackageReference Include="ITHit.FileSystem.Windows" Version="5.6.16439.0" />
<ProjectReference Include="..\..\..\Common\Common.csproj" />
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<Platforms>AnyCPU;x64</Platforms>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="ITHit.FileSystem.Windows" Version="5.6.16427.0" />
<PackageReference Include="ITHit.FileSystem.Windows" Version="5.6.16439.0" />
<ProjectReference Include="..\..\..\Common\Common.csproj" />
<ProjectReference Include="..\Core\Common.Windows.Core.csproj" />
</ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<PackageReference Include="System.Drawing.Common" Version="6.0.0" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ITHit.FileSystem.Windows.ShellExtension" Version="5.6.16427.0" />
<PackageReference Include="ITHit.FileSystem.Windows.ShellExtension" Version="5.6.16439.0" />
</ItemGroup>
<ItemGroup>
<None Update="log4net.config">
Expand Down
5 changes: 1 addition & 4 deletions Windows/VirtualDrive/VirtualDrive/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -364,10 +364,7 @@ private static async Task CleanupAppFoldersAsync()

try
{
if (Engine != null)
{
await Engine.UninstallCleanupAsync();
}
await Engine?.UninstallCleanupAsync();
}
catch (Exception ex)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ namespace VirtualDrive.ShellExtension
[Guid("000562AA-2879-4CF1-89E8-0AEC9596FE19")]
public class CustomStateProviderIntegrated : CustomStateHandlerIntegratedBase
{
public CustomStateProviderIntegrated() : base(Program.Engine, Program.Engine.IconsFolderPath)
public CustomStateProviderIntegrated() : base(Program.Engine)
{
}
}
Expand Down
4 changes: 2 additions & 2 deletions Windows/VirtualDrive/VirtualDrive/VirtualDrive.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ This is an advanced project with ETags support, Microsoft Office documents editi
<PackageReference Include="System.Drawing.Common" Version="6.0.0" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="ITHit.FileSystem.Windows.Package" Version="5.6.16427.0" />
<PackageReference Include="ITHit.FileSystem.Windows.ShellExtension" Version="5.6.16427.0" />
<PackageReference Include="ITHit.FileSystem.Windows.Package" Version="5.6.16439.0" />
<PackageReference Include="ITHit.FileSystem.Windows.ShellExtension" Version="5.6.16439.0" />
<ProjectReference Include="..\..\..\Common\Common.csproj" />
<ProjectReference Include="..\..\Common\VirtualDrive\Common.Windows.VirtualDrive.csproj" />
<ProjectReference Include="..\VirtualDrive.ShellExtension\VirtualDrive.ShellExtension.csproj" />
Expand Down
2 changes: 1 addition & 1 deletion Windows/VirtualFileSystem/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ private static async Task CleanupAppFoldersAsync()

try
{
await ((EngineWindows)Engine).UninstallCleanupAsync();
await Engine?.UninstallCleanupAsync();
}
catch (Exception ex)
{
Expand Down
19 changes: 9 additions & 10 deletions Windows/WebDAVDrive/README.md
Original file line number Diff line number Diff line change
@@ -1,33 +1,33 @@

<h1 class="d-xl-block d-none">WebDAV Drive Sample in .NET, C#</h1>
<p>This sample implements a virtual file system that displays documents from a WebDAV server. You can edit documents, upload and download documents as well as manage folders structure using Windows File Manager. This sample provides automatic documents locking for Microsoft Office and AutoCAD documents.&nbsp;It supports synchronization, on-demand loading,&nbsp;selective offline files support, upload and download progress. It synchronizes files and folders both from a WebDAV server to the local user file system and from the local user file system to the WebDAV server. This sample is written in .NET Core, C#.&nbsp;&nbsp;</p>
<p>This sample implements a virtual file system that displays documents from a WebDAV server. You can edit documents, upload and download documents as well as manage folders structure using Windows File Manager. This sample provides automatic documents locking for Microsoft Office and AutoCAD documents.&nbsp;It supports synchronization, on-demand loading,&nbsp;selective offline files support as well as upload and download progress. It synchronizes files and folders both from a WebDAV server to the local user file system and from the local user file system to the WebDAV server. This sample is written in .NET, C#.&nbsp;&nbsp;</p>
<p><span>You can use this sample out-of-the-box to manage documents on a WebDAV server, or you can use it as a starting point for your custom virtual drive to create&nbsp;OneDrive-like features for your DMS/CRM/ERP and reprogram it to publish data from your storage.&nbsp;</span></p>
<p><span>This sample is supplied as part of the SDK with <a title=".NET Client" href="https://www.webdavsystem.com/client/">IT Hit WebDAV Client Library for .NET</a> and with <a title="userfilesystem.com" href="https://www.userfilesystem.com/">IT Hit User File System</a>.</span></p>
<p><span>You can download this sample and trial licenses in the&nbsp;<a title="Download" href="https://www.webdavsystem.com/client/download/">IT Hit WebDAV Client Library product download area</a> and in the&nbsp;<a title="Download" href="https://www.userfilesystem.com/download/">IT Hit User File System&nbsp;</a></span><a title="Download" href="https://www.userfilesystem.com/download/">product download area</a><span>. You can also clone it or browse the code on&nbsp;</span><a title="Virtual File System Sample in .NET, C#" href="https://github.com/ITHit/UserFileSystemSamples/tree/master/Windows/WebDAVDrive">GitHub</a><span>.&nbsp;</span><span></span></p>
<h2>Requirements</h2>
<ul>
<li>.NET Core 5.0 or later or .NET Framework 4.8.</li>
<li>.NET 6 or later or .NET Framework 4.8.</li>
<li>Microsoft Windows 10 Creators Update or later version.</li>
<li>NTFS file system.</li>
<li>The sample supports WebDAV servers with cookies authentication, Basic, Digest, NTLM, and Kerberos authentication.</li>
<li>To connect to WebDAV servers with cookies authentication Microsoft Edge&nbsp;is required.&nbsp;</li>
</ul>
<h2>Configuring the Sample</h2>
<p>To specify the WebDAV server URL edit the&nbsp;<code class="code">"WebDAVServerUrl"</code>&nbsp;parameter in&nbsp;<code class="code">appsettings.json</code>. This could be either a server root path (https://server/) or a WebDAV folder on your server (https://server/dav/).</p>
<p>For testing and demo purposes you can use one of the IT Hit demo servers. Navigate to https://webdavserver.net or // https://webdavserver.com in a web browser. Copy the URL or your test folder, that looks like https://webdavserver.net/User123456/ and specify it in the&nbsp;<code class="code">WebDAVServerUrl</code>&nbsp;parameter.</p>
<p>For testing and demo purposes you can use one of the IT Hit demo servers. Navigate to https://webdavserver.net or to https://webdavserver.com in a web browser. Copy the URL or your test folder, that looks like https://webdavserver.net/User123456/ and specify it in the&nbsp;<code class="code">WebDAVServerUrl</code>&nbsp;parameter.</p>
<p>By default, this sample will mount the user file system under the&nbsp;<code class="code">%USERPROFILE%\DAV\</code>&nbsp;folder (typically&nbsp;<code class="code">C:\Users\&lt;username&gt;\DAV\</code>). To specify a different folder edit the&nbsp;<code class="code">"UserFileSystemRootPath"</code>&nbsp;parameter&nbsp;in&nbsp;<code class="code">appsettings.json</code>.</p>
<h2>Setting the License</h2>
<p><span class="warn">Note that to use the sample you need both the IT Hit WebDAV Client Library license and IT Hit User File System license.</span></p>
<p>To run the example, you will need both IT Hit WebDAV Client Library for .NET license and IT Hit User File System Engine for .NET License. You can download <span>a trial license in the&nbsp;<a title="Download" href="https://www.webdavsystem.com/client/download/">IT Hit WebDAV Client Library product download area</a>&nbsp;and in the&nbsp;<a title="Download" href="https://www.userfilesystem.com/download/">IT Hit User File System&nbsp;</a></span><a title="Download" href="https://www.userfilesystem.com/download/">product download area</a>.&nbsp;Note that this sample is fully functional with a trial license and does not have any limitations. The trial licenses are valid for one month will stop working after this. You can check the expiration date inside the license file.&nbsp;Download the licenses file and specify license strings in the&nbsp;<span><code class="code">WebDAVClientLicense</code> and&nbsp;<code class="code">UserFileSystemLicense</code></span>&nbsp;fields respectively in&nbsp;<code class="code">appsettings.json</code>&nbsp;file.&nbsp;Set the license content directly as a value (NOT as a path to the license file). Do not forget to escape quotes: \":</p>
<pre class="brush:xml;auto-links:false;toolbar:false">"UserFileSystemLicense": "&lt;?xml version=\"1.0\" encoding=\"utf-8\"?&gt;&lt;License…</pre>
<p>You can also run the sample&nbsp;without explicitly specifying a license&nbsp;for 5 days. In this case,&nbsp;the&nbsp;Engine will automatically request the trial licenses from the IT Hit website https://www.userfilesystem.com. Make sure it is accessible via firewalls if any. After 5 days the Engine will stop working. To extend the trial period you will need to download trial licenses&nbsp;and specify them in&nbsp;<code class="code">appsettings.json</code></p>
<h2>Running the Sample</h2>
<p>To run the sample open the project in Visual Studio and run the project in debug mode.&nbsp;In the debug mode this sample provides additional support for the development and testing convenience. When starting in the debug mode, it will automatically create a folder in which the virtual file system will reside, register the user file system with the platform and then open&nbsp;an instance of Windows File Manager with a mounted file system as well as will launch a default web browser navigating to the WebDAV server URL specified in your&nbsp;<code class="code">appsettings.json</code>:</p>
<p>To run the sample open the WebDAVDrive project in Visual Studio and run the project in debug mode.&nbsp;In the debug mode this sample provides additional support for the development and testing convenience. When starting in the debug mode, it will automatically create a folder where the virtual file system will reside, register the user file system with the platform and then open&nbsp;an instance of Windows File Manager with a mounted file system as well as will launch a default web browser navigating to the WebDAV server URL specified in your&nbsp;<code class="code">appsettings.json</code>:</p>
<p><img id="__mcenew" alt="WebDAV Drive sample launches Windows File manager with mounted virtual file system displaying content of your WebDAV server" src="https://www.userfilesystem.com/media/2103/mapdrivesample1.png" rel="121895"></p>
<p>You can start managing and editing files on your WebDAV server&nbsp;and will see all changes being propagated to the file system on the client machine. You can also edit documents and manage file structure on the client and all changes will automatically be reflected on the WebDAV server.</p>
<h2 class="heading-link" id="nav_packagingproject">Packaging Project<a class="list-link d-inline" href="https://www.userfilesystem.com/examples/virtual_drive/#nav_packagingproject"></a></h2>
<p><span class="warn">Starting with IT Hit User File System v5 Beta, the WebDAVDrive project supports identity and provides&nbsp;the same functionality as <span>WebDAVDrive</span>.Packaging project. Starting&nbsp;<span>WebDAVDrive</span> project directly registers thumbnails handler shell extension, context menu handler and custom states &amp; columns handler.</span></p>
<p>This sample provides a Windows Application Packaging Project which allows deployment of your application to the Windows Store, simplifies COM components debugging (thumbnails handler and Windows Explorer context menu), as well as your application can be installed without admin privileges. The&nbsp;package can be also used for direct&nbsp;<a href="https://www.youtube.com/watch?v=fJkbYPyd08w&amp;t=73s">deployment to users</a>.</p>
<p>This sample provides a Windows Application Packaging Project which allows deployment of your application to the Windows Store. The&nbsp;package can be also used for direct&nbsp;<a href="https://www.youtube.com/watch?v=fJkbYPyd08w&amp;t=73s">deployment to users</a>.</p>
<p>To start the project with thumbnails and context menu support follow these steps:</p>
<ol>
<li>Set the packaging project as your startup project.</li>
Expand All @@ -46,17 +46,16 @@
<p>When a large file is being downloaded from the WebDAV server, this sample submits progress reports to the operation system, to show a standard Windows "Downloading" dialog. At the same time, the Windows File Manager also shows progress in the files list view:</p>
<p><img id="__mcenew" alt="Large file download from the remote storage show progress reports in Windows File Manager and Files View" src="https://www.userfilesystem.com/media/1984/cloudfiledownloadprogress.png" rel="116804"></p>
<h2>Microsoft Office and AutoCAD Documents Editing</h2>
<p>This sample<span>&nbsp;supports synchronization of the Microsoft Office and AutoCAD documents, avoiding the creation of temporary files in the remote storage as well as it does not rename or delete the document in your remote storage during MS Office/AutoCAD transactional save operation, preserving all data associated with a file in your remote storage.</span></p>
<p><span>This sample automatically locks the Microsoft Office and AutoCAD document in the remote storage when a document is being opened for editing and automatically unlocks the document when the file is closed. When the document is opened you will see the lock icon&nbsp;<img id="__mcenew" alt="Lock icon" src="https://www.userfilesystem.com/media/2071/locked.png" rel="120785"><span>&nbsp;</span>in the Status column in Windows File Manager:</span></p>
<p>This sample<span>&nbsp;supports synchronization of the Microsoft Office and AutoCAD documents, preserving all data associated with a file in your remote storage.</span></p>
<p><span>This sample automatically locks Microsoft Office and AutoCAD documents in the remote storage when a document is being opened for editing and automatically unlocks when the document is closed. When the document is opened you will see the lock icon&nbsp;<img id="__mcenew" alt="Lock icon" src="https://www.userfilesystem.com/media/2071/locked.png" rel="120785"><span>&nbsp;</span>in the Status column in Windows File Manager:</span></p>
<p><img id="__mcenew" alt="WebDAV Drive automatically locks Microsoft office document when it is being opened for editing and unlocks when closed." src="https://www.userfilesystem.com/media/2105/mapdrivesamplemsofficenarrowsmall.png" rel="121897"></p>
<p>Any temporary Microsoft Office and AutoCAD documents (~$docfile.docx, G57BURP.tmp, etc) are stored in the local file system only and are NOT synchronized to the server. Typically temporary Microsoft Office and AutoCAD documents are being automatically deleted by Microsoft office when the document editing is completed.</p>
<p>Locks and eTags are being stored in the application data folder, under the path that corresponds with the mounted drive. For example:&nbsp;<code class="code">C:\Users\&lt;user&gt;\AppData\Local\WebDAV Drive\C\Users\&lt;user&gt;\DAV\ServerData\</code></p>
<h2>File ETags</h2>
<p>When listing folder content the client reads file eTags and saves them in the local file system. When sending modified content to the server, the client attaches the saved eTag to the request. The server compares eTags to ensure the file was not modified on the server since the file was read by the client. In the case of Microsoft Office documents, eTags provide one more level of protection against overwriting server changes in addition to locks.</p>
<p>When listing folder content the client reads file eTags and stores it as part of each placeholder. When sending modified content to the server, the client attaches the saved eTag to the request. The server compares eTags to ensure the file was not modified on the server since the file was read by the client. In the case of Microsoft Office documents, eTags provide one more level of protection against overwriting server changes in addition to locks.</p>
<h2>In-Sync Status and ETag Usage For Synchronization</h2>
<p>Synchronization in this sample is based on In-Sync file status as well as on the eTag received from the server.</p>
<p>The server to client synchronization is performed only if the file on the client is marked as In-Sync&nbsp;with the server (it is marked with<img id="__mcenew" alt="In-Sync icon" src="https://www.userfilesystem.com/media/1986/localfile.png" rel="118449">&nbsp;or&nbsp;<img id="__mcenew" alt="Pinned file" src="https://www.userfilesystem.com/media/1989/pinnedfile.png" rel="118452">&nbsp;or&nbsp;<img id="__mcenew" alt="Cloud file" src="https://www.userfilesystem.com/media/1988/offilefile.png" rel="118451">icon).</p>
<p>When any file or folder on the client is updated, it is marked as not In-Sync<img id="__mcenew" alt="Not in sync icon" src="https://www.userfilesystem.com/media/1987/notinsyncfile.png" rel="118450">, which means the content must be sent to the server. When the updated file is being sent from client to server, the server compares the eTag sent from the client with the ETag stored on the server, to avoid the server changes being overwritten. The file is updated only if the eTags match. Otherwise, the file/folder is considered to be in conflict and marked with the conflict icon.</p>
<p>When any file or folder on the client is updated, it is marked as not In-Sync<img id="__mcenew" alt="Not in sync icon" src="https://www.userfilesystem.com/media/1987/notinsyncfile.png" rel="118450">, which means the content must be sent to the server. When the updated file is being sent from client to server, the server compares the eTag sent from the client with the eTag stored on the server, to avoid the server changes being overwritten. The file is updated only if eTags match. Otherwise, the file/folder is considered to be in conflict and marked with the conflict icon.</p>
<h2>Commands</h2>
<p>For debugging and development purposes this sample provides the following console commands:</p>
<ul>
Expand Down
Loading

0 comments on commit ba06158

Please sign in to comment.