How to add “active” class to menu link / HTML.Actionlink in ASP.NET MVC ?

Well I know many of the developers or UI guys might have come accross the question on how to highlight the menu or add a css class to the menu which is currently active. How to implement such a behavior, how to add “active” class to Html.ActionLink in ASP.NET MVC. Well the solution is simple. Add a MVC HTML helper […]

147 total views, 6 views today

» Read more

What is the difference between String and string in C#?

What is the difference between String and string in C#?

What is the difference between String and string in C#?

  String stands for System.String and it is a .NET Framework type. string is an alias in the C# language for System.String. Both of them are compiled to System.String in IL (Intermediate Language), so there is no difference. Also there are no performance implications either. Choose what you like […]

116 total views, 3 views today

» Read more

Visual studio short cut keys

Visual Studio short cut keys

Visual Studio short cut keys / commands   Following post will help you to get informed about the visual studio short cuts. The short cuts will definitely help you in faster development.   To comment the selected lines i.e. Comment Selection Ctrl+K, Ctrl+C – This shortcut will comment the selected lines with @* commented area *@ or //  To remove the […]

1,541 total views, 4 views today

» Read more

What is a view engine in ASP.NET MVC? What is a Razor view engine in ASP.NET MVC? What is Web form / ASPX view engine in ASP.NET MVC?

ASP.NET MVC View Engines

One of the most common interview question for a ASP.NET MVC Software developer postion is, What is a view engine in ASP.NET MVC?  What is a Razor view engine in ASP.NET MVC? What is Web form / ASPX view engine in ASP.NET MVC? Difference between Web form – ASPX engine and Razor engine? Answer: View engine gives the ability to […]

2,386 total views, no views today

» Read more

How to add javascript in drupal theme & module

How to add javascript file in drupal theme & module? There are 3 ways to add javascipt file into your theme. 1. By using preprocess_page hook To conditionally add js to the theme, you can use this way. To add javascript into your theme you need to call following api inside hook template_preprocess_page. write this function inside themes template.php file. […]

1,126 total views, 2 views today

» Read more

How to upload and save image in custom form in drupal

How to upload and save image in custom form in drupal 1. First Display image upload field on form as follows:-

—————————————————————————————————————- 2. Write below code on form submit using hook form_submit

—————————————————————————————————————- 3. Write below code to save image field value i.e. path and record in db as well as save image in specified location. [write below […]

841 total views, 1 views today

» Read more

Redshift database – How to copy table from one schema to another?

Looking for, Redshift database – How to copy table from one schema to another schema? Or How to copy contents of table from one schema to another in Redshift databse? I recently wanted to copy table from one schema to another schema in Redshift database. I found two queries to help me to create a table from one schema to […]

2,282 total views, 2 views today

» Read more

How to fetch records in drupal

Looking for how to fetch / get records in drupal How to write select query in drupal Drupal uses db_select function for this. db_select($table, $alias = NULL, array $options = array()) Parameters :- $table: The base table for this query. $alias: The alias for the base table of this query. $options: An array of options to control how the query […]

1,942 total views, 9 views today

» Read more

How to import data from Excel file or CSV file to SQL table.

How to import data from Excel file or CSV file to SQL table. Few days back I was in need to import an Excel file to a table in SQL server 2012. I found many posts suggesting how to import it via queries, but I am writing this post to help the ones who want to do it using the […]

1,171 total views, 6 views today

» Read more
1 2