Banner Ad

Friday, October 25, 2013

Visual Studio Tips & Tricks - 5 : Class Library – An Introduction

By Francis   Posted at   3:47 PM   Visual Studio Tips and Tricks No comments
                      Class Library is a one of the project type offered in Visual Studio. Normally a class library contains class definition or interface. If we use the class library in projects we can gain the below advantages:

  •             Provide a single DLL regardless of class files. That is a class library contains number of class files. But the output of the class library is a Single “DLL” (Dynamic Link Library) File.
  •        The main purpose of the class library comes into picture in a layered architecture projects.For example, a web project contains various layers (such as Business and Data Access Layers). If we use a separate class library for each layer, in this case if any layer changed we just compiled that particular layer and get the dll and replace it in Production environment.  At these times, class library project type are best option.


Readers do you have any tip? Please use comment.

Thursday, October 24, 2013

My Blogging Journey So For

By Francis   Posted at   12:29 PM   Blog Status 2 comments
                            Few years ago, around 2011, at one night I decided and started blogging about ASP.Net technologies. I’m diehard fan of WWE (World Wrestling Entertainment), as of now I’m a huge fan of John Cena. From his slogan “The Champ Is Here” I pick up the name “Champ” and put it my blog. This is how I named my blog.

The Champ Is Here!

                At Initial stage I’m not a serious blogger. But from the year 2013, onwards I decided to do something to the ASP.Net community. So that I decided to post article in a regular basis. As of now I’m serious about this.
Since its starting, my blog goes up and down. As of now I have crossed over 8000+ views. (thanks to everyone who helped to achieve this height.
               Apart from blogging, I’m a member of the ASP.Net forums where I can contribute to the community directly as much as I can.
               My blog traffic also increased during this year after I post in a regular intervals. You can see the result in the below figure. Recently i have changed the UI of this website and mapped from blogger to the custom website.

Overall Growth of my website

              Normally I got nearly 1000+ page views per month, which is very low compare to other blogs, but I’m happy with my work.

In future also I really want to do the same to the ASP.Net community.

Wednesday, October 23, 2013

IIS Tips & Tricks # 2: Set Default page for a website in IIS

By Francis   Posted at   3:24 PM   IIS Tips and Tricks No comments
                         In few websites, if we type the website name, (like www.someurl.com) it will automatically loaded the page www.someurl.com/index.aspx . This is because of the setting of the “Default Document” feature of IIS. 

                           In this post we are going to discuss about this feature of IIS.

  1. Open IIS, by type the command “inetmgr” in Run window.
  2. Select “Default Document” and click.
  3. In the feature view, we can see some type of Document orderly kept.

IIS - Default Document
Default Document - Feature View

          The top most had the high priority and the last one had least priority.
As per the above figure, the document “Default.htm” had the high priority, the file “Default.aspx” had the lowest priority. Which means whenever the user types a url (like www.someurl.com) then IIS look any one of the file exist in the above order on that Virtual Directory. If it finds any one of the file, it will load that page.

         IIS also allow, add/remove the custom default document per website. For example if we are specify a page (say home.htm) as the default document which does not exist in the website then IIS will look into that website and Alert the user as shown below, which explicitly state that that each time when we type the url IIS will look in that order. 

IIS - Add Custom Default Document
Add Custom Default Document
            So as per the alert, it is advisable to move the default document at the top level, which will increase the performance in the sense IIS can avoid to go further down in the list.

Readers, do you have any other tip, please comment me.

Hope this helps!







Monday, October 14, 2013

Visual Studio Tips & Tricks: 5 - Hexa Decimal values displayed during Debug the application

By Francis   Posted at   9:27 AM   Visual Studio Tips and Tricks No comments
                  Recently, I had a wired problem in Visual studio. In this post i’m going to discuss about it. The problem is, when I try to debug my application in Visual Studio 2010, the values are displayed in Hexadecimal format. Please take a look into the below picture.
Hexa Decimal values displayed during Debug the application
Values of Variable Displayed in Hexa Decimal Format
The reason is somehow the “Hexadecimal Display” option has been checked in the “Watch” window.
“Hexadecimal Display” option in Watch Window
“Hexadecimal Display” option in Watch Window

So that all the values are displayed in Hexadecimal form in watch window too.
So just disable the “Hexadecimal Display” in the watch window’s float menu. The display will correctly display in the decimal form.
Values of Variable Displayed in Decimal Format
Values of Variable Displayed in Decimal Format


Hope this helps someone!

Thursday, October 10, 2013

VB.Net : A Word about “Nothing”!

By Francis   Posted at   2:14 PM   VB.Net Tips and Tricks No comments


                              It’s a common misunderstand of a new programmer in vb.net about the keyword “Nothing”. The main purpose of this keyword is set the default value for an variable type. For example,the default value  for  the  Boolean type variable is “False”. In some cases, we may want to set the default value of that type of the variable. At that time, Nothing keyword comes into picture.

Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
        Dim strString As String = "Sample String"
        Dim intVar As Integer = 100
        Dim decVar As Decimal = 100.01
        Dim dblVar As Double = 100.233
        Dim blnVar As Boolean = True
        ' Set the variable's Default value by using Nothing 
        strString = Nothing
        intVar = Nothing
        decVar = Nothing
        dblVar = Nothing
        blnVar = Nothing
        lblResult.Text = "Default value of String variable: " & strString & vbCrLf & _
                        "Default value of Integer variable: " & intVar & vbCrLf & _
                        "Default value of Decimal variable: " & decVar & vbCrLf & _
                        "Default value of Double variable: " & dblVar & vbCrLf & _
                        "Default value of Boolean variable: " & blnVar & vbCrLf

    End Sub

Just copy the above code under the Button's click event. Hope this hepls a bit!

Monday, October 7, 2013

VB.Net ByRef Variable : A Small Warning

By Francis   Posted at   12:44 PM   VB.Net No comments
In VB.Net, programmers often used the variable by reference using the keyword ByRef. Normally, reference variables not copied like Value type variables. There are some scenarios arise to use or pass a variable as reference to another function/subroutine and change them within the function/subroutine.

Connect with Us