YouTube is a major video hosting website. IF you want to have videos on your website and you don’t want to host them, you can always use YouTube as a CDN. 1st method is to upload the video on YouTube and embed the code on your website, 2nd method is to make your website directly upload the videos to YouTube and embed them. YouTube provides a .Net Api to do this from your website directly or from your application. Continue reading “YouTube API with Asp.net C#”
iPad Air Revealed
BBM BlackBerry Messenger for Android and iPhone is here
Today RIM decided to release their BBM messenger on Android and iPhone after their fail release on September 22, and asked everything to register on bbm.com to get a notification, since i did, I received this morning an email with title BBM for Android and iPhone is here ! after downloading the app from google play.. I think RIM should have waited more to perfect this service before making a release.
Continue reading “BBM BlackBerry Messenger for Android and iPhone is here”
The New 100 Dollar USD with features
Yesterday the most used bill on the planet had a new face lift. Meet the new 100 Dollar. From the front not a lot of things change except for the additional security features. As for the back of this bill there is a new 100 covering the side of this face and of course additional security features. Continue reading “The New 100 Dollar USD with features”
18 October 2013 penumbral eclipse of the moon
18 of October 2013 the earth will partially shed it’s shadow on the moon. This will Create a penumbra eclipse of the moon. This eclipse can be fully seen in most of Europe, Asia and part of Africa. This is the last of three lunar eclipses in 2013, so if you want the see a lunar eclipse in 2013 better not miss this one. Continue reading “18 October 2013 penumbral eclipse of the moon”
Increasing Performance of ASP.Net web application
While developing large application performance is the major factor. Performance plays crucial role in development of any application. There are many ways to increase the performance of the application.Some of them are discussed below.
- Page Level and Server controls:
- State Management Level:
- Data Access Level:
- Web Application Level:
- Page Level and Server controls:
- Avoid unnecessary round trips to the server.
- use Microsoft Ajax and partial-page rendering to accomplish tasks in browser code.
- use IsPostBack Property of page object to avoid unnecessary processing.
- Avoid executing code on each postback if it only has to run the first time the page is requested.
- while developing custom server controls. design them to render client script for some of their functionality.
- Creating Custom Client Script by Using the Microsoft Ajax Library.
- Use Server.Transfer and cross-page posting to redirect between ASP.NET pages in the same application.(For accessing controls and their values from the source page).
- Leave buffering on unless you have a specific reason to turn it off .
- There is a significant performance cost for disabling buffering of ASP.NET Web pages.
- Avoid unnecessary round trips to the server.
- State Management:
- Use View state of control when it is required.
- By default, view state is enabled for all server controls. Disable it , by setting EnableViewState property to false, as in the following example:
<asp:datagrid enableViewState=”false” datasource=”…” runat=”server”/>
- By default, view state is enabled for all server controls. Disable it , by setting EnableViewState property to false, as in the following example:
- Avoid using view state encryption unless you have to.
- View state encryption prevents users from reading view-state values in the hidden view-state form field.
- Select appropriate session-state provider for your application.
- Asp.Net provides various ways to store data in a session.Based on the requirement and conditions of the application select appropriate session storage. Example:in-process session state, out-of-process session and creating custom session also possible.
- Disable session state when you are not using it.
- To disable session state for a page, set the EnableSessionState attribute in the @ Page directive to false, as in the following example:
<%@ Page EnableSessionState="false" %>
To disable it at application level,Use this property in web.config.
<sessionState mode="Off" />
- To disable session state for a page, set the EnableSessionState attribute in the @ Page directive to false, as in the following example:
- Use View state of control when it is required.
- Data Access Level:
- Use SQL Server and stored procedures for data access:
- SQL Server is the recommended choice for data storage to create high-performance, scalable Web applications.
- Use the SqlDataReader class for a fast forward-only data cursor:
- The SqlDataReader class creates a forward-only, read-only data stream that is retrieved from a SQL Server database.
- Cache data and page output whenever possible:
- use caching if there is no dynamic content request for every page request.
- Use SQL cache dependency appropriately.
- Use Table-based polling feature provided by SQL Server. In table-based polling, if any data in a table changes, all cache items that are dependent on the table are invalidated
- Use data source paging and sorting instead of UI:
- Don`t pull all the data from the database. use paging concepts and retrieve the number of records that are necessary to display.
- Balance the security benefit of event validation with its performance cost.
- Use SqlDataSource control caching, sorting, and filtering .
- Use SQL Server and stored procedures for data access:
-
- Set the number of threads per worker process.
- Recycle processes periodically.
- Preload the application.
- initial start up response time can be improved by preloading.
- Precompile Web site projects.
- Initially project is batch compiled upon first request and this batch compilation compiles all pages in a directory to improve memory and disk usage.So Precompile the whole project before deploying it into the server.
- Disable debug mode.
- Disable debug mode before you deploy a production application.
- Tune the configuration files for the Web server computer and for specific applications. Web Application Level:
- Preload the application.
- Recycle processes periodically.
- For applications that rely extensively on external resources, enable Web gardening on multiprocessor computers.
- Set the number of threads per worker process.
Happy programming, share if you find usefull.
Asp.Net Subdomains Single sign on
Single sign-on (SSO) is a property of access control of multiple related, but independent software systems. With this property a user logs in once and gains access to all systems without being prompted to log in again at each of them. Continue reading “Asp.Net Subdomains Single sign on”
CSS Positioning: A Comprehensive Look
If you’ve come to grips with CSS-based layouts, then it’s likely that you’re using floats as the primary means to layout your pages. Maybe you’ve even started to experiment with some of CSS’s far-future layout techniques, in hopes that browser support for them improves.
One aspect of CSS layouts that will likely be around for some time yet is CSS positioning. That is, using CSS’s position
property. In this post, I’ll cover CSS positioning in detail and I hope you’ll come away from this with some more options in your CSS layouts. Continue reading “CSS Positioning: A Comprehensive Look”
JSON Tutorial,definition, history, usage and Comparison
Introduction to JSON
This page introduces you to JSON – JavaScript Object Notation. We have discussed definition, history, usage and Comparison with XML of JSON in this page. Continue reading “JSON Tutorial,definition, history, usage and Comparison”