.NET
349 TopicsWindows Server 2019 and .NET 4.8?
Hello, On a fully updated Windows Server 2019, roles and features allow me to install only .NET 4.7. One of the solution we are using require .NET 4.8 (Adaxes). When I install .NET 4.8 using the installer available here https://support.microsoft.com/en-us/topic/microsoft-net-framework-4-8-offline-installer-for-windows-9d23f658-3b97-68ab-d013-aa3c3e7495e0 It works, I can install Adaxes, but it break ServerManager as well as Azure AD Connect. What's the correct procedure to install .NET 4.8 on Server 2019 without breaking anything else? Thanks a lot196KViews5likes32CommentsDo more with Copilot and agents
For February, we’re delving deep into Copilots and AI agents. We have live events and learning resources that will help developers get started and do more so you can take your productivity to a new level. Learn about tools for creating agents, find out how to use GitHub Copilot to develop apps more quickly, build intelligent apps with .NET, start creating customized experiences for Microsoft Teams, and more. GitHub Copilot Bootcamp Join the GitHub Copilot Bootcamp to deep dive into the tools and skills you need to supercharge your development productivity and with GitHub Copilot. This is a 4-part live series happening February 4–13, 2025. AI agents — what they are, and how they’ll change the way we work What are AI agents? Discover what agents are, how they work autonomously around-the-clock, and how you can build agents specific to your business needs. Microsoft 365 Copilot Developer Camp Start building agents for Microsoft 365 Copilot. Watch Microsoft 365 Copilot Developer Camp videos on demand, work through guided hands-on labs, and explore more resources to help you learn how to build your own agents. Getting started with AI Agents Azure AI Agent Service lets you build software that will work to achieve a specified goal without you knowing exactly what steps it will take. Join this session to learn how you can automate tasks that were previously too complex to be easily automated. Preview the GitHub Copilot extension for Teams Toolkit Discover a more powerful way to build Microsoft Teams apps and customize Microsoft 365 Copilot. Introducing the GitHub Copilot for Teams Toolkit (preview)—your new companion in VS Code, Visual Studio, and GitHub.com. Find practical resources on the Copilot learning hub on Microsoft Learn We’ve got curated content on Microsoft Copilot for technical professionals. Learn how to use AI technology, create custom experiences, and increase productivity. Generative AI Level Up Explore the cutting edge of app development with the Microsoft Reactor “Generative AI Level Up Tuesdays” series. Delve into the basics of Gen AI, learn about building AI agents, find out how responsible AI tooling helps mitigate risks, and more. Simplify development with the new Microsoft 365 Agents SDK Want to simplify your agent development? The Microsoft 365 Agents SDK brings together core components making it easier to build agents and publish them to Microsoft 365 Copilot, Teams, the web, and other channels. Learn, collaborate, and build your skills with Microsoft Fabric experts and peers The Microsoft Fabric Community Conference (FabCon) returns to Las Vegas March 31 to April 2, 2025, packed with breakout sessions and technical deep dives covering data, analytics, and AI. Sign up now with code MCUST to save $150. Introducing the new .NET AI Applications page Have you seen the new .NET AI Applications page? Explore videos, documentation, SDKs, AI libraries and other essential resources to help you build intelligent solutions using C#, OpenAI, and Azure. AI learning hub Visit the AI learning hub, a place to learn new AI skills. Get started with curated plans and resources designed around business and technical roles. Build AI agents, learn best practices, explore basic concepts, and dig into more advanced topics. Build AI Agents & Apps FAST with Azure AI Foundry Looking for a fast way to start building AI agents and applications? This video shows how to use Azure AI Foundry for super fast results. Learn about AI Foundry, AI app templates, the decision tree, and how to get started. What is Azure AI Agent Service? Learn about Azure AI Agent Service, a fully managed service designed for securely building, deploying, and scaling AI agents without needing to manage compute and storage resources. Discover what you can do with just a few lines of code. AI agents in Azure Cosmos DB Explore conceptual overviews and detailed implementation samples for AI agents. This Microsoft Learn article offers a deep-dive overview, looking at types of agents, frameworks, and code samples. Microsoft JDConf 2025 Register for JDConf 2025 and get ready to code the future with AI. Microsoft's annual event for Java developers will take place April 9-10, offering three separate live streams to cover different regions. Explore tools and skills for building modern apps in the cloud and integrating AI. Other news and resources from around Microsoft Architecture Recipes for AI-Powered Applications https://aka.ms/DevCal_Feb25_05 What’s new in AI Toolkit for Visual Studio Code January 2025 Updates https://aka.ms/DevCal_Feb25_18 On demand webinar: Secure Software Development from Code to Cloud with DevSecOps and AI https://aka.ms/DevCal_Feb25_17515Views0likes0CommentsNew Features in Azure Container Apps VS Code extension
👆 Install VS Code extension Summary of Major Changes New Managed Identity Support for connecting container apps to container registries. This is now the preferred method for securing these resources, provided you have sufficient privileges. New Container View: Introduced with several commands for easier editing of container images and environment variables. One-Click Deployment: Deploy to Container App... added to the top-level container app node. This supports deployments from a workspace project or container registry. To manage multiple applications in a workspace project or enable faster deployments with saved settings, use Deploy Project from Workspace. It can be accessed via the workspace view. Improved Activity Log Output: All major commands now include improved activity log outputs, making it easier to track and manage your activities. Quickstart Image for Container App Creation: The "Create container app..." command now initializes with a quickstart image, simplifying the setup process. New Commands and Enhancements Managed Identity support for new connections to container registries New command Deploy to Container App... found on the container app item. This one-click deploy command allows deploying from a workspace project or container registry while in single revision mode. New Container view under the container app item allows direct access to the container's image and environment variables. New command Edit Container Image... allows editing of container images without prompting to update environment variables. Environment Variable CRUD Commands: Multiple new commands for creating, reading, updating, and deleting environment variables. Convert Environment Variable to Secret: Quickly turn an environment variable into a container app secret with this new command. Changes and Improvements Command Create Container App... now always starts with a quickstart image. Renamed the Update Container Image... command to Edit Container.... This command is now found on the container item. When running Deploy Project from Workspace..., if remote environment variables conflict with saved settings, prompt for update. Add new envPath option useRemoteConfiguration. Deploying an image with the Docker extension now allows targeting specific revisions and containers. When deploying a new image to a container app, only show ingress prompt when more than the image tag is changed. Improved ACR selection dropdowns, providing better pick recommendations and sorting by resource group. Improved activity log outputs for major commands. Changed draft deploy prompt to be a quick pick instead of a pop-up window. We hope these new features and improvements will simplify deployments and make your Azure Container Apps experience even better. Stay tuned for more updates, and as always, we appreciate your feedback! Try out these new features today and let us know what you think! Your feedback is invaluable in helping us continue to improve and innovate. Azure Container Apps VS Code Extension Full changelog:474Views1like0Comments[Suggestion 1][Allow Language Selection During .NET Installation]
Hi, 1. Context: Currently, when installing the .NET SDK or runtime, multiple language resource folders are automatically included in the installation directory. 2. Problem: Many developers only require a single language, typically English and the additional localization files take up unnecessary disk space and clutter the installation directory. Currently, the installer does not provide an option to select which languages should be installed. Removing these manually is time-consuming and could potentially break application dependencies if done incorrectly. 3. Proposed Solution: Introduce an option in the .NET installer that allows users to select or deselect language packs during installation. This feature could be similar to the "Individual components" selection available in the Visual Studio Installer, where users can choose exactly what they need, ensuring a more streamlined installation. This would help: Reduce disk space usage. Improve installation customization. Provide a cleaner development environment. 4. What do you think about this suggestion ? Thank you for considering this request and I’m happy to provide additional details or insights if needed.19Views0likes0CommentsConnection between .NET and AUTOCAD ELECTRICAL
I want to connect .NET with Autocad Electrical . i am using , AutoCAD Electrical 2025.0.2 , Product Version : 22.0.81.0 , Built on: V.154.0.0 AutoCAD 2025.1.1 Visual Studio Community 2022 - 17.12.3 my system is x64 bit I am creating a console application in .NET 8.0 Runtime with C# language , Added dll accoremgd , acdbmgd, acmgd, Autodesk.AutoCAD.Interop . Also in .NET in Solution Explorer , in project references , i have made "Copy Local" property as False. using System; using Autodesk.AutoCAD.Interop; using Autodesk.AutoCAD.Runtime; using System.Runtime.InteropServices; using Autodesk.AutoCAD.ApplicationServices; namespace AutoCADElecDemo { class Program { static void Main(string[] args) { AcadApplication acadApp = null; const string progId = "AutoCAD.Application.25"; // Adjust for your AutoCAD version try { // Get a running instance of AutoCAD acadApp = GetActiveAutoCAD(progId); } catch (System.Exception ex) { Console.WriteLine($"Error initializing AutoCAD: {ex.Message}"); return; } try { // Ensure AutoCAD is visible acadApp.Visible = true; Console.WriteLine("AutoCAD is now running."); // Register for the BeginQuit event Application.BeginQuit += OnBeginQuit; // Keep the application running to monitor AutoCAD's state Console.WriteLine("Press Enter to exit..."); Console.ReadLine(); } catch (System.Exception ex) { Console.WriteLine($"An error occurred: {ex.Message}"); } finally { // Unregister the event handler before exiting Application.BeginQuit -= OnBeginQuit; } } static AcadApplication GetActiveAutoCAD(string progId) { try { var comObject = Marshal.GetActiveObject(progId); Console.WriteLine($"Connected to AutoCAD: {progId}"); return (AcadApplication)comObject; } catch (System.Exception ex) { Console.WriteLine($"Error accessing AutoCAD: {ex.Message}"); throw; } } static void OnBeginQuit(object sender, EventArgs e) { Console.WriteLine("AutoCAD is being closed."); } } } For above code, my application comes in break mode "Your app has entered a break state, but no code is currently executing that is supported by the selected debug engine (e.g. only native runtime code is executing)." and i am getting below error : System.IO.FileNotFoundException: 'Could not load file or assembly 'accoremgd, Version=25.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.' dll path is also correct. i also tried same code with .NET Framework 4.7.2 and 4.8 targeting pack , but getting same error. How to load accoremgd.dll properly so that this application can use autocad accoremgd functions properly.28Views0likes0CommentsSeamless File Management in ASP.NET Core: Azure Blob Storage with Configurable Local Mode
Setting up the Project Before we dive into the implementation, let’s set up the basic structure: Create an ASP.NET Core Web API project. Add the Azure.Storage.BlobsNuGet Package for Azure Blob Storage integration. Update appsettings.json to include storage configurations: "Storage": { "Mode": "Local", "BlobStorage": { "ConnectionString": "YourAzureBlobStorageConnectionString", "ContainerName": "YourContainerName" } } Mode: Determines whether to use Local or Azure Blob Storage. ConnectionString and ContainerName: Azure Blob Storage details. Implementing the Storage Service Here is a custom StorageService that handles file uploads, deletions, and downloads. It dynamically decides the storage location based on the configuration mode. public class StorageService : IStorageService { private readonly IConfiguration _configuration; private readonly IHttpContextAccessor _httpContextAccessor; private readonly string _storageMode; public StorageService(IConfiguration configuration, IHttpContextAccessor httpContextAccessor) { _configuration = configuration; _httpContextAccessor = httpContextAccessor; _storageMode = _configuration["Storage:Mode"]; } public async Task<string> UploadFile(IFormFile file) { try { if (_storageMode == "Local") { var uploads = Path.Combine(Directory.GetCurrentDirectory(), "wwwroot", "uploads"); var fileName = $"{DateTime.Now:MMddss}-{file.FileName}"; var filePath = Path.Combine(uploads, fileName); if (!Directory.Exists(uploads)) Directory.CreateDirectory(uploads); using (var fileStream = new FileStream(filePath, FileMode.Create)) { await file.CopyToAsync(fileStream); } var host = string.Format("{0}{1}", _httpContextAccessor.HttpContext!.Request.IsHttps ? "https://" : "http://", _httpContextAccessor.HttpContext.Request.Host); return $"{host}/uploads/{fileName}"; } else { var container = new BlobContainerClient(_configuration["Storage:BlobStorage:ConnectionString"], _configuration["Storage:BlobStorage:ContainerName"]); await container.CreateIfNotExistsAsync(PublicAccessType.Blob); var blob = container.GetBlobClient(file.FileName); using (var fileStream = file.OpenReadStream()) { await blob.UploadAsync(fileStream, new BlobHttpHeaders { ContentType = file.ContentType }); } return blob.Uri.ToString(); } } catch (Exception ex) { throw; } } public async Task<bool> DeleteFile(string fileName) { try { if (_storageMode == "Local") { var uploads = Path.Combine(Directory.GetCurrentDirectory(), "wwwroot", "uploads"); var filePath = Path.Combine(uploads, fileName); if (File.Exists(filePath)) { File.Delete(filePath); return true; } } else { var container = new BlobContainerClient(_configuration["Storage:BlobStorage:ConnectionString"],_configuration["Storage:BlobStorage:ContainerName"]); var blob = container.GetBlobClient(fileName); await blob.DeleteIfExistsAsync(); return true; } } catch (Exception ex) { return false; } } public byte[] DownloadFile(string fileName) { var blobServiceClient = new BlobServiceClient(_configuration["Storage:BlobStorage:ConnectionString"]); var container = blobServiceClient.GetBlobContainerClient(_configuration["Storage:BlobStorage:ContainerName"]); var blobClient = container.GetBlobClient(fileName); using (var memoryStream = new MemoryStream()) { blobClient.DownloadTo(memoryStream); return memoryStream.ToArray(); } } } Static File Middleware Add app.UseStaticFiles(); in Program.cs to serve local files. Usage Example Here’s how to use the UploadFile method in a Web API: public async Task<ServiceResponse<List<ProductPicture>>> UploadImages(List<IFormFile> images) { ServiceResponse<List<ProductPicture>> response = new(); try { List<ProductPicture> pictures = new(); foreach (var file in images) { var imageUrl = await _storageService.UploadFile(file); pictures.Add(new ProductPicture { Url = imageUrl, FileName = Path.GetFileName(imageUrl) }); } response.Data = pictures; } catch (Exception ex) { response.Success = false; response.Message = ex.Message; } return response; } Conclusion By integrating Azure Blob Storage and providing a configurable local storage mode, this approach ensures flexibility for both development and production environments. It reduces development friction while leveraging Azure’s scalability when deployed. For further details, explore the Azure Blob Storage Documentation and Quickstart: Azure Blob Storage.177Views0likes0Commentsfeature request: please add liblibgdiplus packages to DOTNET .. (linux)
feature request: please add liblibgdiplus packages (deb,rpm) to dotnet 9.xx description Libgdiplus is the Mono library that provides a GDI+-compatible API on non-Windows operating systems. need it to run .NET code on linux.. i know, most linux flavors provide a liblibgdiplus package, but adding it to dotnet prevents issues with running dotnet.. André7Views0likes0Comments