Sign In
SharePoint Comic
Tags
ASP.NET
Certification
Errors
Miscellaneous
News
Office 365
RMS
SharePoint
SharePoint Comic
SQL Server
Tips
Visual Studio
Windows 7
Windows 8
Windows Phone 7
Windows Server 2008
Browse by Tags
TechNet Blogs
>
SharePoint Comic
>
All Tags
>
asp.net
Tagged Content List
Blog Post:
Check to see if a string is empty
SharePoint Comic
There are several ways to check a string to see if it’s empty. However, you should try to always use the following method. It’s faster, and uses less resources. This may seem like a minimal piece of code - but if you were checking strings through out your application, it all adds up...
on
20 Sep 2007
Blog Post:
Adding a ListItem to a dynamic dropdown list
SharePoint Comic
If you manually add a listitem to a dynamic dropdown list, ensure that you set the appenddatabounditems attribute to true. If you don’t, the dynamic items will overwrite the ones you manually added. < asp : dropdownlist id ="DevelopmentCycleDropDown" runat ="server" appenddatabounditems...
on
10 Aug 2007
Blog Post:
Including a file in a Web Deployment Project
SharePoint Comic
Argh Argh. I’m precompiling a website (msbuild) and then building an installer for deploying it. For the build, I’m use WDP. However; for whatever silly reason Visual Studio ignores file types of .lic So I have a license file that won’t get built, and to be honest I don...
on
11 May 2007
Blog Post:
Compiler Error Message: CS0030: Cannot convert type ‘ASP.login_aspx’ to ‘System.Web.UI.WebControls.Login’
SharePoint Comic
Argh. What a silly error this is. There are a couple of things that need to happen for this to happen in .net. 1. You precompiled your app (2.0) 2. You publish your site as ‘updateable’ 3. You named a page that is the same as a Class in .net Most developers call their login page: Login.aspx. When you...
on
8 May 2007
Blog Post:
Activating ActiveX Controls
SharePoint Comic
Since Microsoft has released their new security around ActiveX Controls, you may have noticed that Internet Explorer isn’t too friendly torwards Flash anymore. For more detailed information on the new security and how Control Activation works here, Activating ActiveX Controls . Here is a quick example...
on
2 Apr 2007
Blog Post:
Allow Only Numbers In A String - C#
SharePoint Comic
Often you may have user input that needs to only be numbers, and the input doesn’t allow characters. There is javascript that you can put on the front end to limit what keystrokes can be made in an input field; however, there are still ways around it. Here’s a good filter method that you...
on
30 Aug 2006
Blog Post:
Difference between two Dates
SharePoint Comic
Here’s some useful code if you need to know how much time has elapsed between two days. DateTime oldDate = new DateTime (2005, 7, 31); DateTime newDate = DateTime .Now; ...
on
31 Jul 2006
Blog Post:
Regular Expression Library
SharePoint Comic
Regular Expressions. Joy oh Joy. Here’s a great site to help ease the pain in writing one: Regular Expression Library . They have over a thousand indexed expressions and it even has an online tool to help you test expressions: http://www.regexlib.com/RETester.aspx I used it to help...
on
18 Jul 2006
Blog Post:
Use an Image in a HyperLinkColumn
SharePoint Comic
I’ve seen a lot of posts on boards of people inquiring how to utilize an image in a hyperlinkcolumn. I found those posts, because I was trying to do the same thing. In my codebehind, I had some custom things going on for the link, and really didn’t feel like comprimising any of that by calling...
on
9 May 2006
Blog Post:
Formatting Strings in a DataGrid
SharePoint Comic
In my opinion, one of the coolest .net controls is the DataGrid. There is sooo much you can do with this puppy. One of the things I like most about it is how you can choose to control or not control how data is rendered. Which brings me to the topic of this post, how to format a string...
on
14 Apr 2006
Blog Post:
Determine how many records are in a DataSet
SharePoint Comic
To determine how many records are in a dataset, you can use the Count method of the Rows in a table (last line in code). // New DataSet DataSet dbSet = new DataSet (); ...
on
13 Apr 2006
Blog Post:
Close Registry Keys After Use
SharePoint Comic
To open a windows registry key using C#, the code would look something like this: RegistryKey rk = Microsoft.Win32. Registry .LocalMachine.OpenSubKey( "Software\\TWC\\Applications" , true ); The RegistryKey object has lots of methods on it to CreateSubKey, DeleteSubKey, SetValue, DeleteValue...
on
5 Apr 2006
Blog Post:
How to swap two strings
SharePoint Comic
using System; class SwappinStrings { static void SwapStrings( ref string s1, ref string s2) // The string parameter x is passed by reference. // Any changes on parameters will affect the original variables. { ...
on
31 Mar 2006
Blog Post:
ImageButton in DataGrid and DataGrid.ItemCommand Event
SharePoint Comic
I recently had an ImageButton in a DataGrid, and for whatever reason it wouldn’t fire the DataGrid.ItemCommand event. After beating my head on the keyboard for an entire day, I finally found the problem. When you are binding the grid (or calling the method that handles the binding) in the page_load...
on
20 Mar 2006
Blog Post:
Convert VB to C#
SharePoint Comic
Ever find a tutorial or code sample that will resolve your current issue…. and Argh! It’s in VB. It’s happened to me a thousand times. This experimental web app can convert that foreign language for you: http://www.developerfusion.co.uk/utilities/convertvbtocsharp.aspx . I’ve had some...
on
3 Jul 2005
Page 1 of 1 (15 items)