When you get this error message, it’s basically a warning that what you are trying to insert into the database could be malicious, so it was blocked. This is the default for ASP.Net.
If you have tried to set the width of a control (like a table) in code, you probably have received an error since it’s expecting an integer/unit. However, it’s very possible to set the width as a percentage, and probably a little easier than you would think.
Sometimes it becomes necessary to create a solution and either you don’t have a solution file for your project, or your solutiion file has been renamed or has become corrupted. At that point, it’s not as straight forward as one would like in order to get it done. However, it’s not a laborious task at […]
You probably know that, in order to retrieve the currently logged in user in ASP.Net, you would use this code snippet: System.Web.HttpContext.Current.User.Identity.Name() This returns the current user in the DOMAIN\USER format. But sometimes, all you want is the user name itself, without the Domain and slash. Here’s a function you can use to do this:
First – don’t panic – I realize you have no information when you get this error and you have no troubleshooting direction at all, but don’t panic. Help is on the way.
Knowing the environment variables in your program can sometimes be a very important aspect of your application. It’s very easy to get a list of and to use any one of the environment variables however you need it.
Most people know that, with a string in ASP.net or WinForms development, you can use the replace function to replace certain characters within a string with others. And, you probably know that you can even remove characters alltogether, using the replace function.
I got this error and it showed that it was in the web.config file of my website. It took me a long time to actually realize that it was NOT THE web.config, but in a folder that Visual Studio did not show as being in the project – – a ‘vti’ folder. The text of […]
I was just going over a few notes, when I had a quick little project in which I needed a SQLDataSource control, and I thought I’d present what I found here.
When you have a hosted site, many sites will just let you run the standard ASP.Net code to send an email, but some hosts now are requiring the login details (credentials) be put in the script you run, so as to authenticate your script.
All Things DotNet Discussed – Winforms/ASP.Net/SharePoint/WPF