# Document Editor with ASP.NET Core and Docker Support with Linux Containers using Visual Studio 2026 and .NET 10

> This article shows how to create a Document Editor ASP.NET Core application using Docker with Linux containers in Visual Studio 2026 and .NET 10. We will create a simple web application that allows users to edit documents directly in their web browser using the Document Editor component from Text Control.

- **Author:** Bjoern Meyer
- **Published:** 2025-12-30
- **Modified:** 2026-07-17
- **Description:** This article shows how to create a Document Editor ASP.NET Core application using Docker with Linux containers in Visual Studio 2026 and .NET 10. We will create a simple web application that allows users to edit documents directly in their web browser using the Document Editor component from Text Control.
- **5 min read** (935 words)
- **Tags:**
  - ASP.NET
  - ASP.NET Core
- **Web URL:** https://www.textcontrol.com/blog/2025/12/30/document-editor-aspnet-core-docker-linux-visual-studio-2026-dotnet-10/
- **LLMs URL:** https://www.textcontrol.com/blog/2025/12/30/document-editor-aspnet-core-docker-linux-visual-studio-2026-dotnet-10/llms.txt
- **LLMs-Full URL:** https://www.textcontrol.com/blog/2025/12/30/document-editor-aspnet-core-docker-linux-visual-studio-2026-dotnet-10/llms-full.txt

---

> **Prerequisites**
> 
> You need to download and install the trial version of TX Text Control .NET Server to host the Document Editor backend:
> 
> - [Download Trial Version](https://www.textcontrol.com/product/tx-text-control-dotnet-server/download/)  
>     Setup download and installation required.

### Introduction

This tutorial will walk you through the process of building a simple ASP.NET Core web application that hosts the TX Text Control .NET Server backend. This will enable in-browser document rendering and editing with the TX Text Control Document Editor.

Version 34.0 of TX Text Control provides full support for Visual Studio 2026 and .NET 10. This ensures seamless integration and compatibility with the latest tools, as well as a smooth development experience on the newest Microsoft platform.

#### Container and Linux Distributions

TX Text Control is compatible with all major Linux distributions and can be deployed in virtual machines, Docker containers, and hyperscaler environments, including **Azure App Services**, **AWS Elastic Beanstalk**, and **Google Cloud Run**. This tutorial will demonstrate how to create an ASP.NET Core web application that hosts TX Text Control in a standard Linux container using the default Visual Studio template.

### Creating the Application

Make sure that you have installed the latest version of Visual Studio 2026, including the [.NET 10 SDK](https://dotnet.microsoft.com/en-us/download/dotnet/10.0).

1. In Visual Studio 2026, create a new project by choosing *Create a new project*.
2. Select *ASP.NET Core Web App (Model-View-Controller)* as the project template and confirm with *Next*.
3. Enter a project name and choose a location to save the project. Confirm with *Next*.
4. Choose *.NET 10.0 (Long Term Support)* as the *Framework*.
5. Enable the *Enable container support* checkbox and choose *Linux* as the *Container OS*.
6. Choose *Dockerfile* for the *Container build type* option and confirm with *Create*.
    
    ![Creating the .NET 10 project](https://s1-www.textcontrol.com/assets/dist/blog/2025/12/30/a/assets/visualstudio1.webp "Creating the .NET 10 project")

#### Adding the Web Server Backend

7. Create a new class by right-clicking the project in the *Solution Explorer* and choose *Add -> Class...*. Name the class *TXWebServerProcess.cs* and confirm with *Add*. Replace the complete content with the following code:
    
    ```
    using System.Diagnostics;
    using System.Reflection;
    
    public class TXWebServerProcess : IHostedService
    {
        private readonly ILogger<TXWebServerProcess> _logger;
    
        public TXWebServerProcess(ILogger<TXWebServerProcess> logger) => _logger = logger;
    
        public Task StartAsync(CancellationToken cancellationToken)
        {
            try
            {
                string? path = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
                string dllPath = Path.Combine(path ?? "", "TXTextControl.Web.Server.Core.dll");
    
                if (string.IsNullOrEmpty(path) || !File.Exists(dllPath))
                    _logger.LogWarning("TX Web Server process could not be started.");
                else
                {
                    Process.Start(new ProcessStartInfo("dotnet", $"\"{dllPath}\" &") { UseShellExecute = true, WorkingDirectory = path });
                    _logger.LogInformation("TX Web Server process started.");
                }
            }
            catch (Exception ex) { _logger.LogError(ex, "Error starting TX Web Server."); }
    
            return Task.CompletedTask;
        }
    
        public Task StopAsync(CancellationToken cancellationToken)
        {
            _logger.LogInformation("Stopping TX Web Server process...");
            return Task.CompletedTask;
        }
    }
    ```
8. Right-click the project in *Solution Explorer*, select *Add → Existing Item…*, and then browse to the TX Text Control .NET Server installation directory.
    
    *C:\\Program Files\\Text Control GmbH\\TX Text Control 34.0.NET Server for ASP.NET\\Assembly\\net8.0*
    
    Set the file filter to *All Files (\*.\*)* and select the following files:
    
    
    - *TXTextControl.Web.Server.Core.deps.json*
    - *TXTextControl.Web.Server.Core.dll*
    - *TXTextControl.Web.Server.Core.Process.deps.json*
    - *TXTextControl.Web.Server.Core.Process.dll*
    - *TXTextControl.Web.Server.Core.Process.runtimeconfig.json*
    - *TXTextControl.Web.Server.Core.runtimeconfig.json*
    - *TXTextControl.Web.Server.Core.config.json*
    
    Confirm with *Add*.
9. Select the added files in the *Solution Explorer* and set the *Copy to Output Directory* property to *Copy always*.

#### Adding the NuGet Packages

10. In *Solution Explorer*, select your project and choose *Manage NuGet Packages…* from the *Project* menu. Then set **Text Control Offline Packages** as the package source.
    
    Install the following packages:
    
    
    - **TXTextControl.Web**
    - **TXTextControl.TextControl.Core.SDK**
    
    ![ASP.NET Core Web Application](https://s1-www.textcontrol.com/assets/dist/blog/2025/12/30/a/assets/visualstudio2.webp "ASP.NET Core Web Application")

#### Configure the Application

11. Open the *Program.cs* file located in the project's root folder.
    
    After *builder.Services.AddControllersWithViews();*, add the following code:
    
    ```
    builder.Services.AddHostedService<TXWebServerProcess>();
    ```
    
    At the very top of the file, insert the following code:
    
    ```
    using TXTextControl.Web;
    ```
    
    Add the following code before the entry `app.UseRouting();`:
    
    ```
    // enable Web Sockets
    app.UseWebSockets();
    
    // attach the Text Control WebSocketHandler middleware
    app.UseTXWebSocketMiddleware();
    ```
    
    The overall *Program.cs* file should look like this:
    
    ```
    using TXTextControl.Web;
    
    var builder = WebApplication.CreateBuilder(args);
    
    // Add services to the container.
    builder.Services.AddControllersWithViews();
    builder.Services.AddHostedService<TXWebServerProcess>();
    
    var app = builder.Build();
    
    // Configure the HTTP request pipeline.
    if (!app.Environment.IsDevelopment())
    {
        app.UseExceptionHandler("/Home/Error");
        // The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
        app.UseHsts();
    }
    
    app.UseHttpsRedirection();
    
    // enable Web Sockets
    app.UseWebSockets();
    
    // attach the Text Control WebSocketHandler middleware
    app.UseTXWebSocketMiddleware();
    
    app.UseRouting();
    
    app.UseAuthorization();
    
    app.MapStaticAssets();
    
    app.MapControllerRoute(
        name: "default",
        pattern: "{controller=Home}/{action=Index}/{id?}")
        .WithStaticAssets();
    
    
    app.Run();
    ```

#### Adding the Control to the View

12. Find the *Index.cshtml* file in the *Views -> Home* folder. Replace the complete content with the following code to add the document editor to the view:
    
    ```
    @using TXTextControl.Web.MVC
        
    @{
        var sDocument = "<html><body><p>Welcome to <strong>Text Control</strong></p></body></html>";
    }
    
    @Html.TXTextControl().TextControl(settings => {
        settings.UserNames = new string[] { "Tim Typer" };
    }).LoadText(sDocument, TXTextControl.Web.StringStreamType.HTMLFormat).Render()
    
    <input type="button" onclick="insertTable()" value="Insert Table" />
    
    <script>
        function insertTable() {
            TXTextControl.tables.add(5, 5, 10, function(e) {
              if (e === true) { // if added
                TXTextControl.tables.getItem(function(table) {
                  table.cells.forEach(function(cell) {
    
                    cell.setText("Cell text");
    
                  });
                }, null, 10);
              }
            })
        }
    </script>
    ```

#### Starting the Application

We will use the Dockerfile as provided and rely on the default Visual Studio template, which targets a Linux container based on the [official Docker Hub image](https://hub.docker.com/_/microsoft-dotnet-aspnet).

13. Start the application by pressing *F5* or by choosing *Debug -> Start Debugging* from the main menu.

---

## About Bjoern Meyer

As CEO, Bjoern is the visionary behind our strategic direction and business development, bridging the gap between our customers and engineering teams. His deep passion for coding and web technologies drives the creation of innovative products. If you're at a tech conference, be sure to stop by our booth - you'll most likely meet Bjoern in person. With an advanced graduate degree (Dipl. Inf.) in Computer Science, specializing in AI, from the University of Bremen, Bjoern brings significant expertise to his role. In his spare time, Bjoern enjoys running, paragliding, mountain biking, and playing the piano.

- [LinkedIn](https://www.linkedin.com/in/bjoernmeyer/)
- [X](https://x.com/txbjoern)
- [GitHub](https://github.com/bjoerntx)

---

## Related Posts

- [Silicon Valley, Here We Come!](https://www.textcontrol.com/blog/2026/08/10/silicon-valley-here-we-come/llms.txt)
- [Against the Trend: Why We Still Believe in Transparent, Perpetual Software Licensing. And Why You Should Too](https://www.textcontrol.com/blog/2026/08/06/against-the-trend-transparent-perpetual-software-licensing/llms.txt)
- [Unlock the Full Value of Your TX Text Control License](https://www.textcontrol.com/blog/2026/08/06/unlock-the-full-value-of-your-tx-text-control-license/llms.txt)
- [Introducing TX Text Control Web Collaboration Preview for ASP.NET Core](https://www.textcontrol.com/blog/2026/08/05/introducing-tx-text-control-web-collaboration-preview-for-asp-net-core-document-editors/llms.txt)
- [Building Long-Term Trust with Digital Signatures and Timestamps in C# .NET](https://www.textcontrol.com/blog/2026/08/04/building-long-term-trust-with-digital-signatures-and-timestamps-in-c-sharp-dot-net/llms.txt)
- [AI Natural Language Document Generation with MCP and TX Text Control .NET](https://www.textcontrol.com/blog/2026/07/16/ai-natural-language-document-generation-with-mcp-server-and-tx-text-control-dotnet/llms.txt)
- [WeAreDevelopers World Congress Europe 2026 Wrap Up: Record Breaking Days in Berlin](https://www.textcontrol.com/blog/2026/07/13/wearedevelopers-world-congress-europe-2026-wrap-up-record-breaking-days-in-berlin/llms.txt)
- [C# Document Generation: A Developer's Guide for .NET](https://www.textcontrol.com/blog/2026/07/08/csharp-document-generation-developer-guide-for-dotnet/llms.txt)
- [Validating PDF/UA Documents in .NET C#: A Practical Guide](https://www.textcontrol.com/blog/2026/07/06/validating-pdf-ua-documents-in-dotnet-csharp/llms.txt)
- [See Text Control at WeAreDevelopers World Congress Europe 2026 in Berlin](https://www.textcontrol.com/blog/2026/07/06/see-text-control-at-wearedevelopers-world-congress-europe-2026-in-berlin/llms.txt)
- [DWX 2026 Wrap-Up: Four Days of Innovation, Conversations, and Enterprise Document Solutions](https://www.textcontrol.com/blog/2026/07/03/dwx-2026-wrap-up-four-days-of-innovation-conversations-and-enterprise-document-solutions/llms.txt)
- [Create SignFabric Envelopes from Mail Merge Templates in .NET C#](https://www.textcontrol.com/blog/2026/06/23/create-signfabric-envelopes-from-mail-merge-templates-using-dotnet-csharp/llms.txt)
- [Convert SSRS RDL Reports to DOCX and TX Text Control Templates in .NET C#](https://www.textcontrol.com/blog/2026/06/22/convert-ssrs-rdl-reports-to-docx-and-tx-text-control-templates-in-dotnet-csharp/llms.txt)
- [Export Document Tables to CSV in .NET C#](https://www.textcontrol.com/blog/2026/06/19/export-document-tables-to-csv-in-dotnet-csharp/llms.txt)
- [Major SignFabric Updates: Stronger Audit Trails, Validation, and Recipient Workflows](https://www.textcontrol.com/blog/2026/06/17/major-signfabric-updates-stronger-audit-trails-validation-and-recipient-workflows/llms.txt)
- [Text Control Expands North American Conference Presence with WeAreDevelopers World Congress North America](https://www.textcontrol.com/blog/2026/06/12/text-control-expands-north-american-conference-presence-with-wearedevelopers-world-congress-north-america/llms.txt)
- [Converting HTML to Markdown in C# .NET](https://www.textcontrol.com/blog/2026/06/11/converting-html-to-markdown-in-csharp-dot-net/llms.txt)
- [Beyond WebSockets: A Glimpse into the Future of Document Editing with WebAssembly](https://www.textcontrol.com/blog/2026/06/10/beyond-websockets-glimpse-future-document-editing-webassembly/llms.txt)
- [Showcasing the Future of Document Processing at Developer World DWX 2026](https://www.textcontrol.com/blog/2026/06/08/showcasing-the-future-of-document-processing-at-dwx-developer-week-2026/llms.txt)
- [PDF Security Explained: Passwords, Permissions, Encryption and Digital Signatures in C# .NET](https://www.textcontrol.com/blog/2026/06/08/pdf-security-explained-passwords-permissions-encryption-and-digital-signatures-in-csharp-dotnet/llms.txt)
- [NDC Copenhagen 2026: Great Days in the Heart of Copenhagen's Developer Community](https://www.textcontrol.com/blog/2026/06/05/ndc-copenhagen-2026-great-days-in-the-heart-of-copenhagens-developer-community/llms.txt)
- [Automatically Mapping TX Text Control Form Fields to JSON Data in .NET C#](https://www.textcontrol.com/blog/2026/06/03/automatically-mapping-tx-text-control-form-fields-to-json-data-in-dotnet-csharp/llms.txt)
- [Getting Started with SignFabric: From Clone to Your First Signature Envelope](https://www.textcontrol.com/blog/2026/06/02/getting-started-with-signfabric-from-clone-to-your-first-signature-envelope/llms.txt)
- [We Never Pause - Join Us at NDC Copenhagen 2026](https://www.textcontrol.com/blog/2026/05/27/we-never-pause-join-us-at-ndc-copenhagen-2026/llms.txt)
- [MD DevDays 2026: Record Attendance, Packed Expo Hall, and Three Great Days in Magdeburg](https://www.textcontrol.com/blog/2026/05/21/md-devdays-2026-record-attendance-packed-expo-hall-and-three-great-days-in-magdeburg/llms.txt)
