Would like to show some best and most commonly used shortcut keys in Microsoft Excel that can be used in 2003-2010 version. To find all the shortcut key, searching in the “Help” by using the keywords -> Keyboard shortcuts.

Move around the Worksheets

Home Move to the beginning of the row
Ctrl+Home Move to the beginning of the workaheet
Ctrl+End Move to the last cell on the worksheet, in the bottom-most used row of the rightmost used column
Ctrl+Arrow Move to edge of region
Ctrl+Page Up

Ctrl+Page Down

Move to the pervious sheet

Move to the next sheet

Ctrl+Tab Move to next open workbook

Quick Data Selection

Ctrl+* Select current region
Ctrl+A Select all cells
Ctrl+Shift+End Select from active cell to last call in used range
Ctrl+Shift+Home Select from active cell to A1


Select columns

Select rows

Shift+arrow key Extend the selection by one cell
Ctrl+Shift+arrow key Extend the selection to the last nonblank cell in the same column or row as the active cell

Instant Cell Formatting

Ctrl+1 Format Cells
Ctrl+B Bold
Ctrl+U Underline

Efficient Windows Operation

Alt+Tab Switch to the next program
Ctrl+Esc Display the Windows Start menu
PrtScr Copy a picture of the screen to the Clipboard
Ctrl+Print Screen Copy a picture of the selected windows to the of a dialog box
Tab Move to the next option or option group of a dialog box
Shift+Tab Move to the previous option or option group of a dialog box

Introduction of C#

C# has been developed by Microsoft Corporation within the .NET team, and approved as a standard by ECMA and ISO/IEC later. C#, which is one of the programming languages designed for the Common Language Infrastructure, is intended to be a simple, modern, object-oriented and common-purpose programming language

There are some fundamental elements that all C# executable programs have and that’s what the C# programmer need to understand. After reviewing the code in below, I’ll explain the basic concepts that will follow for all C# programs we will develop.

// Namespace Declaration
using System;

// Program start class
class Hello
// Main begins program execution.
static void Main()
// Write to console
Console.WriteLine(“Hello to All C# Programmers”);

First of all, we should talk about case-sensitive of C#. The word “Main” is not as same as its lower case spelling, “main”. They are different identifiers.

The namespace declaration, “using System;”, indicates that we are referencing the System namespace. Namespaces contain groups of code that can be called upon by C# programs. With the “using System;” declaration, we are telling the program that it can reference the code in the System namespace without pre-pending the word System to every reference.

The class declaration, class Hello, contains the data and method definitions that the program uses to execute. A class is one of a few different types of elements that the program can use to describe objects. This particular class has no data, but it does have one method. This method defines the behavior of this class.

The one method within the Hello class present what this class will do when executed. The method name, “Main”, is reserved for the starting point of a program. “Main” is often called the “entry point” and if we ever receive a compiler error message saying that it can’t find the entry point, it means that you tried to compile an executable program without a “Main” method. In addition, every method must have a return type. In this case it is void, which means that Main does not return a value. Every method also has a parameter list following its name with zero or more parameters between parenthesis. For simplicity, we did not add parameters to Main.

The Main method specifies its behavior with the Console.WriteLine(…) statement. Console is a class in the System namespace. WriteLine(…) is a method in the Console class. We use the “.”, dot, operator to separate subordinate program elements. Note that we could also write this statement as System.Console.WriteLine(…). This follows the pattern “namespace.class.method” as a fully qualified statement. Had we left out the using System declaration at the top of the program, it would have been mandatory for us to use the fully qualified form System.Console.WriteLine(…). This statement is what causes the string, “Hello to All C# Programmers” to print on the console screen.

Observe that comments are marked with “//”. These are single line comments, meaning that they are valid until the end-of-line. If you wish to span multiple lines with a comment, begin with “/*” and end with “*/”. Everything in between is part of the comment. Comments are ignored when your program compiles. They are there to document what your program does in plain English (or the native language you speak with every day).

All statements end with a “;”, semi-colon. Classes and methods begin with “{“, left curly brace, and end with a “}”, right curly brace. Any statements within and including “{” and “}” define a block. Blocks define scope (or lifetime and visibility) of program elements.

C# Language Reference, Anders Hejlsberg and Scott Wiltamuth
ECMA C# and Common Language Infrastructure Standards

“How to integrate CKEditor + CKFinder with Session CheckAuthentication into CakePHP”


In the process of web development such as CMS (Content Management System), there are many cases where you may find a WYSIWYG editor or a file manager useful.  However from my experience, I noticed that most web application frameworks provide from crappy to no backend interface for WYSIWYG editors or file managers or uploading functions.

In BeamStyle, we use the CakePHP web application framework.  The CakePHP framework is very easy to use and keeps our code clean.  That’s the reason why we are using it.  But of course, nothing is perfect.  The form filling API is crappy and there is no file management system.

To resolve such an issue, the use of external applications is unavoidable.

In this tutorial, I will introduce the method on how to setup CKEditor (WYSIWYG editor) and CKFinder (File Manager, Upload) with CakePHP with CakePHP Authentication.

== Requirements ==

1) CakePHP has already been setup and working. (http://cakephp.org/)

2) CakePHP Authentication has been setup and working inside CakePHP. (http://book.cakephp.org/view/172/Authentication)

== What you need to get ==

1) Download CKEditor (http://ckeditor.com/)

   – I used CKEditor 3.0.1, released on 16 October 2009

2) Download CKFinder (http://ckfinder.com/)

   – I used CKFinder, updated 02.10.2009


== Instructions ==

1) Extract your CKEditor and CKFinder into your /app/webroot/js/ directory

   It should look like the following:



2) Setup CKEditor in your view:

 a) Assuming that you already have your form and Javascript enabled in your controller, and your controller is named AdminController, and your Admin view is already password protected by CakePHP’s Authentication method (http://book.cakephp.org/view/172/Authentication), first you need to tell your view about the classname for CKEditor.  Let’s use the controller to tell the view about it because we want to follow some engineering ethics and the rules of MVC.


  class AdminController extends AppController {


   var $helpers = array('Form', 'Html', 'Javascript', 'Time');


   $ckeditorClass = 'CKEDITOR';

   $this->set('ckeditorClass', $ckeditorClass);



 b) Since you will be integrating the CKFinder very soon when CKEditor is complete, let’s also define what’s required by CKFinder now, so we save some trouble later :p  The following specifies the path to the CKFinder application.


  class AdminController extends AppController {


   var $helpers = array('Form', 'Html', 'Javascript', 'Time');


   $ckeditorClass = 'CKEDITOR';

   $this->set('ckeditorClass', $ckeditorClass);


   $ckfinderPath = 'js/ckfinder/'

   $this->set('ckfinderPath', $ckfinderPath);



c1) Now you need to link the javascript libraries for CKEditor and CKFinder into your template (for this example, let’s use the default template -> default.ctp)

 echo $javascript->link('ckeditor/ckeditor.js');

 echo $javascript->link('ckfinder/ckfinder.js'); 

 c2) Now you need to add a CakePHP textarea in your view.  So add it!  And let’s call it “newsContent” for now



  <?php echo $form->textarea('newsContent', array('class'=>$ckeditorClass)) ?>

c3) Now let’s edit the ckfinder’s config.php file so that everything will link perfectly 😉

$baseUrl = ‘upload/’;

$baseDir = '/home/cakeroot/app/webroot/upload/';

 d) If you give a load on that page, you will see a crappy textarea in your page.

    You want to need to convert that into the trendy CKEditor!  And let’s add some default text to it too! XD

    So what you do is you assign a javascript variable to represent ur newsContent, and we called it “ck_newsContent”.

    After that, we set the contents of it using that variable.



  <?php echo $form->textarea('newsContent', array('class'=>$ckeditorClass)) ?>


  <script type="text/javascript">

  var ck_newsContent = CKEDITOR.replace( 'newsContent' );

  ck_newsContent.setData( '<p>Just click the <b>Image</b> or <b>Link</b> button, and then <b>&quot;Browse Server&quot;</b>.</p>' );




 e)  Now, if you just load the page and click on the image icon (circled in red in the above image), u will see Image Properties window showing up like below (Except without the “Server Browser” button)


f) So what is that server browser button?  Well, that is in fact the CKFinder.  Let’s add that!



  <?php echo $form->textarea('newsContent', array('class'=>$ckeditorClass)) ?>


  <script type="text/javascript">

  var ck_newsContent = CKEDITOR.replace( 'newsContent' );

  ck_newsContent.setData( '<p>Just click the <b>Image</b> or <b>Link</b> button, and then <b>&quot;Browse Server&quot;</b>.</p>' );

  CKFinder.SetupCKEditor( ck_newsContent, '<?php echo $ckfinderPath ?>') ;


g) After you add the above code and try again and you will see the button.  If you click on the button, you may find the following restriction screen >__<


h) Yes that’s right.  You need authentication check!  Let’s do that!

 Open up app/webroot/js/ckfinder/config.php

And first thing, implement your CheckAuthentication() function, like the following:

function CheckAuthentication()


 if( isset($_SESSION['Auth']['User']) )


  return true;


 return false;


i) Now, because CakePHP uses a different session name (Not the default name), we gotta tell CKFinder to look inside THAT CAKEPHP SESSION!


 Add the following at the very top of the config.php file, right below <?php


// Start CakePHP Session



j) Let’s but not least, let’s add an upload folder and grant 757 Permissions to it:

->  app/webroot/upload



k) Now try loading up the Server Browser rom step (g) again and happy surfing!


This is the most important factor when choosing a web hosting service. Nothing else matters when your users simply cannot access your web site. A realiable web hosting service should provide at least 99% server uptime and 24/7 technical support.


If you need services related to email such as mailing list, webmail, auto respond / forward, etc, make sure you check with the web hosting service. Ask for any restrictions or limitations and ensure that it is suitable for your needs.

Disk Space / Data Transfer

Nowadays, more web hosting are fairly generous in terms of disk space and data transfer. If your web site is relatively new then this likely won’t be an issue for you. However, once you have your web site running on your web hosting, you should monitor your disk space and data transfer usage reguarly to ensure that you do not exceed the limits.

Web Language Support

If you plan to run any scripted web pages such as blog, e-commerce, or CMS, find out what your web language and database requirements are and ask if your web hosting service can provide such features in their hosting packages.


If you plan on creating an e-commerce web site or any web site that involves payment, then ensure your web hosting service provides Secure Socket Layer (SSL) support. This allows you to encrypt the data sent between you and your customer such as credit card numbers and other personally identifiable information. You may also want to check if the web hosting service provides any SSL Certificate services.


Your web hosting service location may have an impact on your web site’s user experience.  A web page that takes a long time to load can be very frustrating to your users. Typically, it takes a longer time to load a web page that is hosted in a foreign country than a local one. If your target audience is from Hong Kong, then a Hong Kong based web hosting service would be more suitable. Similarly, if your target audience is from the United States, then you may want to consider an United States based web hosting service.