Archive for January 2018

Clean up IIS log files from web server using PowerShell
Avoid low disk space because of IIS logs with PowerShell Scheduled Task
Microsoft IIS Server is by default logging every request that reaches it. This can be pretty useful for tracking down the issue which my occur over time, but it is also pilling up log files on server's disk which eventually can cause low disk space... read more
Setting up IIS ASP.NET WebApplication using PowerShell
Setup ASP.NET web application hosted on IIS using PowerShell
PowerShell is the best option for automation on Windows platform. Regardless of which platform and how you organize Continous Deployment, you will always need to introduce certain level of customization during the deployment process... read more
Setting permissions for ASP.NET application on IIS with PowerShell
Setting the write permission for IIS AppPool using PowerShell
Very often you need to setup ASP.NET Web application on IIS server, you need to setup file and folder permission for your application on order to access content of specific folder. This can be easily done through Windows Explorer Properties window in the Security tab... read more
JavaScript base64 image to Bitmap in C#
Converting base64 image string to Bitmap in C#
Base64 serialized images are useful in many cases for serving images on page. It is also a format of image that JavaScript can generate on the fly... read more
Separate configuration files per build config in Visual Studio IDE
Generating different configuration files on the build time in VS IDE
It is an often case that application configuration is different for each environment. Most often this is the case for database connection string where developer has connection string to dev environment database or it's local database and quality assurance (qa) and production have different connection strings wile the rest of the config... read more
Managing current IIS websites from ASP.NET code
Controlling the current ASP.NET application running on IIS from the code
Microsoft made IIS management from the ASP.NET code itself much easer and accessible right out of the box by introducing Microsoft.Web.Administration library. Simply by adding the reference in your project to Microsoft.Web.Administration library you are getting options to manage websites hosted on the IIS where application is running. One of the requirements beside referencing Microsoft.Web.Administration library is setting your Application Pool to run under LocalSystem account... read more