You can’t fully protect your code from reverse engineering, especially .NET (managed) code. However, you can make it harder to understand by using an obfuscator. An obfuscator replaces certain parts of your code (such as string literals) with an encrypted version so they don’t make sense to the person that tries to reverse engineer your […]
What is the .NET Framework composed of?
When you install the .NET Framework (be it version 1.0, 1.1 or 2.0) on a computer, you are installing a Common Language Runtime (CLR), a set of DLLs and the ASP.NET integration with IIS if your operating system has Internet Information Services installed. These are the most important three components of the .NET Framework redistributable.The […]
The operation could not be completed. Not enough storage is available to complete this operation.
When you try to execute a query on a SQL Server database, such as creating a stored procedure, a table or adding data to one, and you are receiving the error The operation could not be completed. Not enough storage is available to complete this operation. the cause may be one of the following: – The “Enable […]
The file web.sitemap required by XmlSiteMapProvider does not exist.
The most common case when the “The file web.sitemap required by XmlSiteMapProvider does not exist” error is received is when a SiteMap control was added to a WebForm, however you don’t have a mandatory Web.sitemap file in the root of your web application.To fix this error, make sure you have this file in the root directory, and that it is a […]
At compile I get error error CS0131: The left-hand side of an assignment must be a variable, property or indexer
You are trying to change the value of a constant or of a read-only property.
How to dump a MySQL database to another server in Unix
The following line will allow you to dump a MySQL database from the current machine to another machine, for as long as you have access to the dd command on the remote machine: mysqldump -u USERNAME-HERE -p’PASSWORD-HERE’ DB-NAME-HERE | ssh user@remote-server-address.com “dd of=/mysql/$(date +’%d-%m-%y’)”
How do I prevent a console application from closing immediately?
You have two options.You run the application without debugging (instead of F5 pressCTRL+F5). Or, if you don’t want to run the application without the debugger, at the end of the application code add: Console.ReadLine() Then you end the program by pressing Enter.
How to import the content of a CSS file into another CSS file
If you would like to place the content of a CSS file into another CSS file, copying and pasting is not the only way you can do it. You can easily use @import to include all the content of an existing CSS file into your current CSS file: @import “myOtherStylesheet.css“;
How to find duplicate rows using SQL
The following SQL query will return all the rows that have a duplicate value for the column someColumn. The number of duplicates is stored in the OccurCount variable. SELECT someColumn COUNT(someColumn) AS OccurCount FROM someTable GROUP BY someColumn HAVING (COUNT(someColumn) > 1);
How to get all logical drives on a system?
By calling a static method from System.Environment called GetLogicalDrives(). This returns a string array that you can easily iterate.Suppose you have a ListBox and a button: private void btnPopulate_Click(object sender, System.EventArgs e) { // Store in a string array string[] drives = Environment.GetLogicalDrives(); // Loop into the string array foreach(string strDrive in drives) { // Add […]