Category: General

  • Microsoft Excel: The File couldn’t open in Protected View – Security Error Message

    When we receive the error message “The file could not open in Protected View” in Microsoft Excel, it means that Excel application has detected potential security risks in the file. This Protected View is a security feature in the latest version of Microsoft Excel that helps prevent malicious content from running on your computer. This…

  • How to restart remote server / machine using Remote Desktop, Powershell or Command Prompt?

    To restart a remote Windows desktop / laptop or server, there are several methods, which includes remote desktop (RDP), Windows PowerShell, or Command Prompt.Here are some common methods to restart a remote windows machine: Method 1: By using Remote Desktop (RDP) If you have Remote Desktop access to the server, you can use this method…

  • How to use CLR function at SQL Server?

    Creating a CLR function in SQL Server involves the following steps: 1. Define the function as a static method of a class in a language supported by the .NET Framework 2. Register the assembly in SQL Server by using the CREATE ASSEMBLY statement 3. Create the function that references the registered assembly by using the…

  • RDP- Automatically sign out of disconnected users?

    Open the ‘Group Policy Editor’ for your server. Navigate to: Local Computer Policy / Computer Configuration / Administrative Templates / Windows Components / Remote Desktop Services / Remote Desktop Session Host / Session Time Limits. Find the key ‘Set time limit for disconnected sessions’ Enable and set the Time Limit at dropdown, what ever you…

  • Replace Blank CELLs with NULL Value

    SELECT ‘UPDATE table SET [‘ + name + ‘] = NULL WHERE [‘ + name + ‘] = ””;’ FROM syscolumns WHERE id = object_id(‘table’) AND isnullable = 1;

  • Cannot load Counter Name data because an invalid index ” was read from the registry

    Cannot load Counter Name data because an invalid index ” was read from the registry When we are trying to read system performance counters, some time we will get this type of error on machines. “Cannot load Counter Name data because an invalid index ” was read from the registry” To fix the issue: Click…

  • Search in MSSQL tables

    Sometime we need to reverse engineering in the database tables to find a specific values, we can find the column name easily but in large database, to search a specific key value is too hard. From below query we can easily search value in all tables, it will list column with table in the result.…

  • Cannot load MVC4 Web project in VS 2017 or VS 2019

    I have a web project, it could load fine in VS15, but in VS2019 it’s failing, saying the project is incompatible. The migration report contains the following message: ========== .csproj: The application which this project type is based on was not found. Please try this link for further information: http://go.microsoft.com/fwlink/?LinkID=299083&projecttype=E3E379DF-F4C6-4180-9B81-6769533ABE47 To resolve it: 1. Open…

  • How to read DBF to Datatable

    [csharp] OleDbConnection oConn = new OleDbConnection(@”Provider=Microsoft.Jet.OLEDB.4.0; Data Source=C:\Temp;Extended Properties=dBase III”); OleDbCommand command = new OleDbCommand(“SELECT * FROM Test.DBF”, oConn); oConn.Open(); DataTable dt = new DataTable(); dt.Load(command.ExecuteReader()); oConn.Close(); [/csharp]

  • ORA-28001: The password has expired

    The password life of the applications as well as operating systems are limited. To enabling more security we are getting some alert in daily life that we need to chage our passwords regularly on fixed inerval. If we don’t change before the applications limitation, it will expired. The other day when I was opening SQL…