Recently I had a requirement in one of my project. I am using JQuery UI Tabed view and what I required was to send an Ajax call when a tab is selected. At the start I find it tough to capture onClick or onSelect event of tabs. But later on I got the solution, I would like to share it with all of you. In below given example I put both solutions that I found to capture if a tab is clicked or selected.
Search This Blog
09 September 2011
26 May 2011
Creating a scrollable table with fixed row and column
To create a Scrollable Table you will need to download JQuery library and jquery.fixer plugging from http://plugins.jquery.com/project/fixer
On this page when you click on download link, a zipped folder will get downloaded. Unzip that folder and then copy "jquery.js" and "jquery.fixer.js" files into the folder where your webpage exist.
To create a scrollable table into your webpage, all you need to do is include "jquery.js" and "jquery.fixer.js" files in your webpage and then on document.ready event, for the table on which you want to enable scrolling call fixer function from "jquery.fixer.js" file. For more detail, see the demo code given below.
On this page when you click on download link, a zipped folder will get downloaded. Unzip that folder and then copy "jquery.js" and "jquery.fixer.js" files into the folder where your webpage exist.
To create a scrollable table into your webpage, all you need to do is include "jquery.js" and "jquery.fixer.js" files in your webpage and then on document.ready event, for the table on which you want to enable scrolling call fixer function from "jquery.fixer.js" file. For more detail, see the demo code given below.
Labels:
HTML,
Javascript,
JQuery
16 May 2011
How to set the focus to a child window without refreshing it?
Recently I had a requirement, in my web page which contain four links, each link open a popup window. I am using a common JavaScript function to open popup window as given below,
Now when click on a link, it opens a popup window, which contain a data entry form, I entered some information into that form. Then I need to review other information, from other popup window, so I go back to the main window, click on another link, a new popup window get open which contain the information I need to review. I get the information and close this popup window, so now I am on the main window, then again I click on the link for that data entry form, so the popup window comes up but I lost the information that I have entered, that's because I am relodiing the popup window once again. So here the question arise,

Let us see how it works,
Now when click on a link, it opens a popup window, which contain a data entry form, I entered some information into that form. Then I need to review other information, from other popup window, so I go back to the main window, click on another link, a new popup window get open which contain the information I need to review. I get the information and close this popup window, so now I am on the main window, then again I click on the link for that data entry form, so the popup window comes up but I lost the information that I have entered, that's because I am relodiing the popup window once again. So here the question arise,
- Is their any way, I can check out the if popup window is already open from parent window, without having the object of popup window just by the name?
- If the popup window is already open how can I just set the focus to it, rather then reloading it?
- Can I refer a popup window from a parent window, even after refreshing the parent window?

Let us see how it works,
- When attempt to open the window again with the same name in the second parameter of the windows open method, you will to get the windows handle. If the window is already open, it will return the handle of the opened window or it will open a new window and return it's handle
- The first parameter (the url) is passed as an empty string, so the page will not get redirected which will result in the contents of the window remaining unchanged.
Note : You cannot get the handle if the page is not on the same host as its opener
Labels:
Javascript
13 March 2011
Add & Remove values to a Multi Select list box using JQuery
This control is used to add value to a multiselect list box. And to remove multiple values fron this list box.
Where this control can be useful?
Consider the requirement for adding attributes along with it values (eg. attribute colour with values like red, green, blue... where the number of attribute values are not fixed). Is's good to use this control for adding multiple attribute value, rather then having a seperate screen to add the values.
Where this control can be useful?
Consider the requirement for adding attributes along with it values (eg. attribute colour with values like red, green, blue... where the number of attribute values are not fixed). Is's good to use this control for adding multiple attribute value, rather then having a seperate screen to add the values.
Labels:
JQuery
24 February 2011
New to Jquery?
First step to learn JQuery is, quickly go through following simple JQuery Tutorial http://www.w3schools.com/jquery/ Here are few other really good resources to learn JQuery, http://net.tutsplus.com/articles/web-roundups/jquery-for-absolute-beginners-video-series/ http://www.bennadel.com/resources/presentations/jquery/video/index.htm Here are some really good JQuery plugins http://plugins.jquery.com/ http://jursza.net/dev/jjmenu/# http://datatables.net/examples/basic_init/scroll_y_theme.html http://plugins.jquery.com/project/fixer
Labels:
JQuery
13 February 2011
What is a temporary table?
A temporary table is an object that is created and stored temporarily by SQL Server in the tempdb database. The table can be created by any user by using either the CREATE TABLE statement or SELECT…INTO statement. Temporary tables are of the following two types:
1. Local: A local temporary table is created by prefixing the table name with a single hash(#) sign. The table is visible only to the user who created it.
2. Global: A global temporary table is created by prefixing the table name with a double hash(##) sign. The table is visible to all the users who are connected to the database engine.
The syntax of creating a temporary table is as follows:
To create a local temporary table.
1. Local: A local temporary table is created by prefixing the table name with a single hash(#) sign. The table is visible only to the user who created it.
2. Global: A global temporary table is created by prefixing the table name with a double hash(##) sign. The table is visible to all the users who are connected to the database engine.
The syntax of creating a temporary table is as follows:
To create a local temporary table.
- CREATE TABLE #temporary_table ( column1 datatype, column2 datatype)
- SELECT * INTO #temporary_table FROM original_table
- CREATE TABLE ##temporary_table (column1 datatype, column2 datatype)
- SELECT * INTO ##temporary_table FROM original_table
Labels:
SQL Server
Subscribe to:
Posts (Atom)



