Zum Hauptinhalt springen
tsecurity.de LIVE
Echtzeit-Radar & Feeds
Alle RSS Feeds
👥 Community & Social
IT Security NachrichtenEU-Gesetz zur Cyber-Resilienz ist in Kraft - Netzpalaver(21.09.2026 um 20:29 Uhr)
Malware / Trojaner / VirenMeta Muse AI app flaw lets local malware redirect dictation traffic(21.09.2026 um 21:59 Uhr)
IT Security NachrichteniPhone 18 Pro (Max): Nutzer melden plötzliche Abstürze durch Face ID(21.09.2026 um 21:18 Uhr)
IT Security DownloadsEs wird Zeit, Word zu löschen(21.09.2026 um 21:53 Uhr)
IT NachrichtenAI can't outprompt a shortage of power, water, and land(21.09.2026 um 18:35 Uhr)
IT NachrichtenLondon neocloud Nscale takes its $1B loss to Wall Street(21.09.2026 um 19:15 Uhr)
IT Security NachrichtenEU-Gesetz zur Cyber-Resilienz ist in Kraft - Netzpalaver(21.09.2026 um 20:29 Uhr)
Malware / Trojaner / VirenMeta Muse AI app flaw lets local malware redirect dictation traffic(21.09.2026 um 21:59 Uhr)
IT Security NachrichteniPhone 18 Pro (Max): Nutzer melden plötzliche Abstürze durch Face ID(21.09.2026 um 21:18 Uhr)
IT Security DownloadsEs wird Zeit, Word zu löschen(21.09.2026 um 21:53 Uhr)
IT NachrichtenAI can't outprompt a shortage of power, water, and land(21.09.2026 um 18:35 Uhr)
IT NachrichtenLondon neocloud Nscale takes its $1B loss to Wall Street(21.09.2026 um 19:15 Uhr)
Intelligence View
⚡ tsecurity.de Intelligence

CodeBehind 4.5 Released; Advanced Async Capability

As we mentioned in previous articles, version 4.5 is the latest version of the CodeBehind framework based on .NET 7, and the next version, 4.6, is developed directly on .NET 10 by the Elanat team. In these versions, the framework…

0
↗ Quelle (dev.to)
Reagiere als Erste:r — dein Feedback zählt!

As we mentioned in previous articles, version 4.5 is the latest version of the CodeBehind framework based on .NET 7, and the next version, 4.6, is developed directly on .NET 10 by the Elanat team.



In these versions, the framework structure has been completely rewritten based on async to be more responsive and perform faster than before.



Elanat's CodeBehind Framework is a full-stack, open-source (MIT licensed) framework for ASP.NET Core, introduced in 2023, with the main goal of combining the simplicity and familiarity of Web Forms (using .aspx files and the Code-Behind pattern) with the power and modern architecture of ASP.NET Core. By introducing WebForms Core as a modern, ViewStateless technology, this framework allows for direct server-side UI management. It also offers the ability to add features dynamically without recompiling the application with its modular architecture. This framework is a competitor to the default ASP.NET frameworks, filling the gap left by Microsoft's former WebForms in .NET Core by solving its problems and presenting itself as a flexible and high-performance alternative for developers looking for greater simplicity and reduced routing complexity.



CodeBehind framework 4.5



In addition to adding the async structure, in this version we have done significant work to increase response performance to make the framework faster than before.






Changes in the structure of controllers



Previously, controllers were defined as follows:




public partial class home : CodeBehindController
{
public void PageLoad(HttpContext context)
{
...






But depending on the type of framework configuration, the new structure of controllers is different:



1- Controller configuration in Route

In this case, you can use async Task instead of void automatically:




public async Task PageLoad(HttpContext context)
{
...






Here you need to configure "Program.cs" using the app.UseCodeBehindRouteAsync(); middleware.



2- Default configuration (first-view MVC based on aspx pages)



In this case, to perform async processing in the controller, you must use the await keyword and specify it in the view controller metadata section.



Razor syntax example:




@page
@controller await MyController
<!DOCTYPE html>
<html>
...






Standard syntax example:




<%@ Page Controller="await MyController" %>
<!DOCTYPE html>
<html>
...






Here you need to configure "Program.cs" using the app.UseCodeBehindAsync(); middleware.






Practical example



View




@page
@controller await MyController
<h1>Test Async</h1>






Explanation:




  • This view is defined using Razor syntax.


  • @controller await MyController specifies that the MyController should run asynchronously (async).



Controller




using CodeBehind;

public partial class MyController : CodeBehindController
{
public async Task PageLoad(HttpContext context)
{
string result = await DoSomethingAsync();
Write(result);
}

private async Task<string> DoSomethingAsync()
{
await Task.Delay(2000);

return "Hello CodeBehind! (after async work)";
}
}






Explanation:





  • MyController inherits from CodeBehindController.

  • The PageLoad method is now async and returns a Task, not void.

  • Inside PageLoad, the DoSomethingAsync method is called, and we await its result.


  • DoSomethingAsync simulates an asynchronous operation (Task.Delay(2000) waits for 2 seconds) and then returns a string.


  • Write(result) prints the result to the view.



In other words: This controller processes data asynchronously and then displays it on the page, without blocking the entire application.



Program.cs




var builder = WebApplication.CreateBuilder(args);

builder.Services.AddCodeBehind();

var app = builder.Build();

app.UseCodeBehindAsync();

app.Run();






Explanation:




  • In Program.cs, the CodeBehind service is added to the application.


  • app.UseCodeBehindAsync(); tells the app to handle controllers asynchronously.

  • The application is then started with app.Run().



Together, these three components demonstrate how CodeBehind 4.5 processes a web page asynchronously, improving performance and responsiveness without blocking the app.






Summary



CodeBehind 4.5 brings full async support to both route-based and ASPX-based MVC controllers, improving responsiveness and performance. Developers can now implement async operations easily using await without adding complexity to their code.






Related links



CodeBehind on GitHub:

https://github.com/elanatframework/Code_behind



Get CodeBehind from NuGet:

https://www.nuget.org/packages/CodeBehind/



CodeBehind page:

https://elanat.net/page_content/code_behind

Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten CodeBehind 4.5 Released; Advanced Async Capability

Thematisch verwandte Begriffe: CodeBehind, Released, Advanced, Async · 6 Treffer

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Zum Aktualisieren ziehen
ZERO-DAY CVE-2026-94494 | jshERP through 3.6 contains a tenant isolation bypass vulnerability that…
Advisory →
TTS Reader • tsecurity.de Voice
tsecurity.de Icon
tsecurity.de App
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag
Themen-Radar & Intelligence Matrix
Echtzeit-Taxonomie nach Angriffsvektoren & Plattformen

tsecurity.de Live Threat Radar

🔴 LIVE RADAR
MONITORING
AKTIV
CVE-DATENBANK
LIVE
🔍
Community Radar & Live Chat
Sentinel Bot online • Live-Stream
Dein Cluster: Security Explorer
Match:
lädt…
Verbindung zum Community-Stream wird aufgebaut...
Bearbeitungsmodus — Senden überschreibt deine Nachricht
Community-Puls — was gerade passiert
lädt…
Aktivitäten deiner Analysten
lädt…
Neues Thema oder Eilmeldung einreichen

Reiche interessante Links, Zero-Days oder Debatten ein. Die Community entscheidet per Upvote über die Veröffentlichung.

Heiß diskutierte Einreichungen
🔖 Gespeicherte Artikel
📂 Keine gespeicherten Artikel vorhanden.
Zurück Ziehen Vor
Links: vorheriger Artikel Rechts: nächster Artikel unten: schließen
News NIS-2 Frühwarnung Tier-1 Intel ⏱️ 3 Min vor 10 Min
Artikeldaten werden geladen...

Zurück: vorheriger Vor: nächster
↗ Original-Quelle
Social Reaktionen Deine Reaktion zählt
Einstufung & Relevanz-Poll 0 Stimmen
In sozialen Netzwerken teilen 1-Klick