Saturday, July 28, 2007
Thursday, July 26, 2007
Diffrence Between Parse vs. TryParse vs. ConvertTo
The first of these functions, Parse, is one that should be familiar to any .Net developer. This function will take a string and attempt to extract an integer out of it and then return the integer. If it runs into something that it can’t parse then it throws a FormatException or if the number is too large an OverflowException. Also, it can throw an ArgumentException if you pass it a null value.
TryParse is a new addition to the new .Net 2.0 framework that addresses some issues with the original Parse function. The main difference is that exception handling is very slow, so if TryParse is unable to parse the string it does not throw an exception like Parse does. Instead, it returns a Boolean indicating if it was able to successfully parse a number. So you have to pass into TryParse both the string to be parsed and an Int32 out parameter to fill in. We will use the profiler to examine the speed difference between TryParse and Parse in both cases where the string can be correctly parsed and in cases where the string cannot be correctly parsed.
The Convert class contains a series of functions to convert one base class into another. I believe that Convert.ToInt32(string) just checks for a null string (if the string is null it returns zero unlike the Parse) then just calls Int32.Parse(string). I’ll use the profiler to confirm this and to see if using Convert as opposed to Parse has any real effect on performance.
Via
Wednesday, July 25, 2007
Want To Create ur Own opinion Poll?

place them on your website, blog, MySpace, hi5, Friendster or Xanga
account or anywhere online that you can paste a bit of JavaScript or
Flash!
| ||||
| ||||
|
Tuesday, July 24, 2007
Jog Falls Tour
Jog Falls (Kannada ) is the highest untiered waterfalls in India, located in Shimoga District of Karnataka state. Created by Sharavathi River falling from a height of 253 meters (829 ft), Jog Falls is one of the major attractions in Karnataka tourism. It is also called by alternative names of Gerusoppe falls, Gersoppa Falls and Jogada Gundi
My photos.. http://flickr.com/photos/chin2prajapati
You can watch small clip of jog fall
Microsoft Silverlight "Light Up The Web"
- "WPF/E" is Codename of SilverLight.
- Silverlight is a part of .net Framework 3.0
like u can embed movie in silverlight easily & do animation , Effects.. etc.
For more discussion on Silverlight & Flash u can check this (http://geekglue.blogspot.com/2007/04/silverlight-vs-flash.html) blog.
Official Wesite for Silverlight is http://www.microsoft.com/silverlight
&
http://silverlight.net/
and For material visit http://www.microsoft.com/presspass/presskits/silverlight/materials.mspx
Demo of Silverlight applications.
Very good collection of silverlight examples for new commers click here
To See all Example First you have to install .net Framework 3.0
- Great Visual Studio QuickStarts for Silverlight 1.0/1.1 New!
- Silverlight Ink Experiments New!
- Convert Text to Path New!
- HTML DOM Interop with Silverlight New!
- Drag and Drop in Silverlight 1.0 New!
- Game of Life in Silverlight and F# New!
- Virtual Earth and Silverlight New!
- Smalltalk based on Silverlight/DLR New!
- Silverlight and Google Gears New!
- Creating A Data-driven Control New!
- 3D in Silverlight 1.1 Alpha
- RadControls for Silverlight by Telerik
- Silverlight 1.1 2D Physics with Source Code
- Lutz's Digger, Monotone and Inplay; see also .NET Reflector Plugin for Silverlight
- DLR Console
- Silverlight Chess (JavaScript vs. C#)
- SWF2XAML: A Slightly better Flash to XAML Conversion
- Scott Guthrie's blog posts tagged with Silverlight
- Silverlight Toolbar
- Use File Open Dialog with Silverlight
- Microsoft PopFly
- Microsoft Silverlight 1.1 Alpha Developer Reference Poster
- How-to videos
- Silverlight Surface Demo (with simple video support)
- Silverlight XPS Viewer
- Miguel de Icaza about Silverlight, DLR and OpenSource
- Eyeblaster Rich Media Silverlight AD
- SilverNibbles - Converting a Windows Forms Game to Silverlight
- Silverlight Controls and LINQ
- Silverlight Games 101 (Silverlight Rocks!)
- DLR & IconPython at Codeplex
- Silverlight Pad
- Video support with Silverlight Fox Example
- AOL Social Mail Gadget
- Silverlight Screencasts (more than 20 videos!!)
- Silverlight Disco Dance Floor
- Silverlights Out 2.0 and older version 1.1
- Silverlight GardientBrush Demo
- Silverlight and the Compact Framework (Mix 07 demo video)
- Dr. Popper Silverlight Edition
- Bryant's Silverlight Examples
- Asteroids Clone
- Binary Clock
- Silverlight Scribbler
- Silverlight and Security (.NET Security Blog)
- Keyboard Input
- Silverlight Glass Button (from WPF Glass demo)
- Silverlight 1.1 Layout System and Controls Framework
- Full Screen Mode with Silverlight
- Early version of Snoop for Silverlight
- New York Times Reader in Silverlight (video)
- The basics of a Silverlight Control
- Convert SWF to WPF and Silverlight
- Test with Silverlight/CoreCLR (TestDriven.NET)
- Fantasy Baseball
- Using Playlists in Silverlight
- Silverlight Pad to Test XAML Content
- Animation Using Keyframes and Splines
- Handling Runtime Error Messages in IE and Mozilla
- Downloading Fonts Using the Downloader Object
- Converting a WPF/E Application to a Silverlight Scripting Application
- VB on Silverlight
- Great Silverlight Introduction for JavaScript Developers
- Silverlight C# 3.0 Features
Tuesday, July 10, 2007
A new tool to check Redundancy in CSS called "css-redundancy-checker"
There comes a point in every developer’s life when your realise the problem isn’t your work, but the tools you’ve got to hand. Toolsmithery is an important part of the job, and so I spent a few hours yesterday crafting a tool useful to any front-end developer.
The result is the CSS Redundancy Checker.
When you’re writing HTML, over time, your CSS files begin to fill up
a lot. If you’re working on a large project, you might even end up with
several people contributing to the CSS file, not to mention refactoring
each other’s work. The result is a directory full of HTML files, and a
very large CSS file.
What tends to happen is that not ever selector in the CSS file
actually applies to your HTML; many are rendered redundant by
refactoring, or by changes in HTML. But when you’ve got a 70k+ CSS
file, it’s not easy to check precisely which selectors aren’t in use
any more.
Enter the CSS Redundancy Checker.
It’s a very simple tool, really. You pass in a single css file, and
either a directory of HTML files, or a .txt file listing URLs (one to a
line). It then proceeds to look at each file in turn, and at the end,
list all the selectors in your css file that aren’t used by any of the HTML files.
That’s it. I’m pretty sure it’s accurate, and it should work with
most CSS files. Most of the magic isn’t down to me, but down to _why the lucky stiff’s marvelous Hpricot
HTML parser. The script itself is about 50 lines of reasonably tidy
Ruby. You’ll need Ruby, and Hpricot, in order to run it. There’s more
full documentation over at the Google Code site where I’m hosting it. Please add any issues there, or get in touch if you want to contribute.
Things it doesn’t do: listing line numbers of where the selectors
are. I wrote that functionality on the train this morning, but I can’t
find a way to make it 100% accurate, so thought it best to leave it out
- inaccurate line numbers are of no use to anyone. If you can come up
with a way that works, let me know. Also, at some point I might turn it
into a Textmate command. All in good time, though.
The need for the tool came out of a large project we’re working on at NPG,
but I felt it would be useful to pretty much any HTML developer. So
I’ve released it to the world. Let me know what you think, and do
spread the word. You can get it via svn checkout, for now:
svn checkout http://css-redundancy-checker.googlecode.com/svn/trunk/ css-redundancy-checker
Thursday, July 5, 2007
How to use .Browser file in ASP.net
In ASP.NET version 1.1, the Machine.config file contained a section called <browserCaps>. This section contained a series of XML entries that defined the configurations for various browsers based on a regular expression. For ASP.NET version 2.0, a new .BROWSER file defines the parameters of a particular browser using XML entries. You add information on a new browser by adding a new .BROWSER file to the folder located at %SystemRoot%\Microsoft.NET\Framework\version\CONFIG\Browsers on your system.
Because an application is not reading a .config file every time it requires browser information, you can create a new .BROWSER file and run Aspnet_regbrowsers.exe to add the required changes to the assembly. This allows the server to access the new browser information immediately so you do not have to shut down any of your applications to pick up the information. An application can access browser capabilities through the Browser property of the current HttpRequest.
Syntax
aspnet_regbrowsers.exe <options>
Options
Option | Description |
|---|---|
| -? | Displays the Aspnet_regbbrowsers.exe Help text in the command window. |
| -i | Creates the runtime browser capabilities assembly and installs it in the global assembly cache. |
| -u | Uninstalls the runtime browser capabilities assembly from the global assembly cache. |
Remarks
Browser definition files can be either system-wide or application-specific, and each type is stored in a different location. System-wide browser definition files are stored in the %SystemRoot%\Microsoft.NET\Framework\version\CONFIG\Browsers directory. This directory contains predefined browser definition files that shipped with the corresponding version of the .NET Framework and any additional browser definition files copied there from software updates or service packs. Do not change the predefined browser definition files that come with ASP.NET, because service packs might update those files and overwrite your changes.
Application-specific browser definition files can be placed in the application's App_Browsers directory. In both locations, browser definition files must have a .BROWSER file name extension. Using the ASP.NET Browser Registration tool has no effect on application-specific browser definition files stored in an application's App_Browsers directory.
When browser definition files at the system level are modified, they do not automatically cause an update of browser capabilities for all applications. You must run the ASP.NET Browser Registration tool to update the browser capabilities assembly.
Note |
|---|
| The ASP.NET Browser Registration tool compiles browser definitions in the Browsers directory of the version of the .NET Framework that corresponds to the tool version. Each version of the .NET Framework has its own copy of the tool. |
The ASP.NET Browser Registration tool parses and compiles all system-wide browser definitions into an assembly and installs the assembly in the global assembly cache. If there are errors in the system-wide browser definitions, the tool reports those errors. The browser capabilities assembly is used by all Web applications on the system. Note that you can also programmatically recompile system-wide browser definition files by using the BrowserCapabilitiesCodeGenerator class.
Behavior
When the ASP.NET Browser Registration tool runs, a new assembly is created and the effect on all Web applications is the same as if the Machine.config file was changed: All running Web applications are recycled and Microsoft Internet Information Services (IIS) is restarted. The tool also generates a random private token file, and creates a key file to sign the assembly so the assembly can be installed in the global assembly cache. The key file is removed when the tool is finished, leaving only the public key.
At run time, browser definition file information is merged into a collection of known browsers in a BrowserCapabilitiesFactory object. When a request is made, ASP.NET identifies the requesting browser by the request header, and compiles an HttpBrowserCapabilities object that corresponds to the type of the requested browser.
Using the <browserCaps> element in the Web.config file to define browsers is deprecated in the .NET Framework version 2.0, but is still supported. The data in this element is merged with the information from the browser definition files.By contrast, browser definition files at the application level are automatically parsed and compiled on demand when the application is started. If any changes are made to the application's Browsers directory, the application is automatically recompiled. The ASP.NET Browser Registration tool has no effect on application-level browser information files.
Examples
To parse and compile all system-wide browser definitions into an assembly and install the assembly into the global assembly cache, run Aspnet_regbrowsers.exe. The following command creates and installs the assembly:
C:\WINDOWS\Microsoft.NET\Framework\<versionNumber>\aspnet_regsql.exe -i
You can also use the tool to remove the browser definition assembly from the global assembly cache. The following command removes the browser definitions assembly from the global assembly cache:
aspnet_regsql.exe -u
To get help on using the ASP.NET Browser Registration tool, use the following command:
aspnet_regsql.exe -?
Powered by ScribeFire.
Monday, July 2, 2007
Top 10 CSS image gallery
http://youneed2see.com/web/99/Top_10_CSS_image_gallery_tutorials
Powered by ScribeFire.





Note