<?xml version="1.0" encoding="utf-8"?><rss version="2.0"><channel><title>The Menace Blog</title><link>https://weblogs.asp.net:443/dennisthemenace/</link><description>Adventures in Web Development</description><item><title>Resolve a Javascript file inside a MasterPage</title><link>https://weblogs.asp.net:443/dennisthemenace/resolve-a-javascript-file-inside-a-masterpage</link><description>&lt;p&gt;&lt;b&gt;The issue:&lt;/b&gt;&lt;/p&gt;&lt;p&gt;There are times when you structure your website layout differently such as admin pages would be under /admin folder and so forth. Since MasterPage files doesn't resolve an incorrect path to a local Javascript folder and file, your scripts will not work. Oddly enough, the CSS file path location is resolved automatically and it determines the proper location of where the CSS file is regardless of the page location.&lt;/p&gt;&lt;p&gt;&lt;b&gt;The solution:&amp;nbsp;&lt;/b&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Host your Javascript source file else where in a remote location and provide the absolute URL to the script. A perfect example of this is having your jQuery hosted on a Google Cloud Network (CDN). &amp;lt;script src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js" type="text/javascript"&amp;gt;&amp;lt;/script&amp;gt;. While this works, it's not recommended for secured sites since you're requesting a file from an unsecured site.&lt;br&gt;&lt;/li&gt;&lt;li&gt;&amp;nbsp;Use ResolveClientUrl() method in your server-side code or declaratively such as &amp;lt;script src='&amp;lt;%= ResolveClientUrl("~/js/jsfile.js") %&amp;gt;' type="text/javascript"&amp;gt;&amp;lt;/script&amp;gt;.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;Hope this helps people who encounters this issue.&lt;/p&gt;&lt;p&gt;- Dennis&lt;br&gt;menacestudio.com / codeoverload.net&lt;br&gt;&lt;/p&gt;</description><pubDate>Mon, 19 Oct 2009 00:30:00 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/resolve-a-javascript-file-inside-a-masterpage</guid></item><item><title>Access Modifiers</title><link>https://weblogs.asp.net:443/dennisthemenace/access-modifiers</link><description>&lt;p&gt;There are still a lot of confusion between access modifiers especially some keywords such as friend, protected, and protected friend. This post is meant to clear things up and distinguish the keywords from each other. Take note that C# keywords are in lower-case (Pascal notation is used below to simply things). In a lot of cases, Private and Public will suffice but there will be instances where you need to limit some exposure to certain types and members -- the logic behind encapsulation.&lt;br&gt;&lt;/p&gt;&lt;p&gt;&lt;b&gt;Public&lt;/b&gt;&lt;br&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Full accessibility which includes accessibility between different assemblies.&lt;/li&gt;&lt;li&gt;Default for enums and interfaces.&lt;br&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;b&gt;Private&lt;/b&gt;&lt;br&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Accessible only within the containing type.&lt;/li&gt;&lt;li&gt;Default for members of classes and structs.&lt;br&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;b&gt;Protected&lt;/b&gt;&lt;br&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Accessible within the containing type.&lt;/li&gt;&lt;li&gt;Accessible by an inheriting type (subclass); but not visible through the base class.&lt;/li&gt;&lt;li&gt;Similar to Private in nature but is accessible when the type is inherited.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;&lt;b&gt;Friend&lt;/b&gt;&lt;b&gt; (VB) / Internal (C#)&lt;/b&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;Accessible anywhere strictly within the same assembly.&lt;/li&gt;&lt;li&gt;Default for non-nested types.&lt;/li&gt;&lt;/ul&gt;&lt;b&gt;Protected Friend (VB) / Protected Internal (C#)&lt;/b&gt;&lt;br&gt;&lt;ul&gt;&lt;li&gt;Includes both the capabilities of Protected and Friend/Internal.&lt;/li&gt;&lt;li&gt;Since Protected and Friend have differentiating restrictions, the two combined opens up doors in terms of accessibility rather than to merge or restrict.&lt;/li&gt;&lt;ul&gt;&lt;li&gt;For instance: a method is now accessible within the same assembly, and at the same time accessible outside as long as the said type member is inherited.&lt;br&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/ul&gt;</description><pubDate>Wed, 16 Sep 2009 17:33:00 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/access-modifiers</guid><category>c#</category><category>Visual Basic</category></item><item><title>Using jQuery to select/deselect Gridview checkboxes</title><link>https://weblogs.asp.net:443/dennisthemenace/using-jquery-to-select-deselect-gridview-checkboxes</link><description>&lt;p&gt;I’ve been using jQuery more and more lately. I’ve been studying it closely now specially how to work with its API and has been well surprised at the cool things that it can do. After several hours (more like days and days) of examining its capabilities, I was able to put together a project with several pages of demos that highlights some of its functions, events, DOM manipulation, etc. Learning how cool it can accomplish things, I’d though of what practical applications can I use it for in the real world. None of this will matter if I can’t apply it anywhere else besides building fancy highlighting of text, etc.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;jQuery in real world application:&lt;/strong&gt;

  &lt;br&gt;So why not start somewhere such as a Gridview? One common application of Javascript that’s common in tabular type control such as the Gridview is the ability to select/deselect several checkboxes at the time. I’ve seen codes after codes of this implementation but line composes of many lines and none seems to be simple and straight-forward. Since jQuery extends Javascript, the challenge here is to iterate through the input checkboxes by means of minimal or somehow smaller lines of codes.&lt;/p&gt;

&lt;p&gt;I’m pretty sure there’s a handful ways of accomplishing this task and one might argue about the usage of&lt;em&gt;&lt;strong&gt;&amp;nbsp;&lt;/strong&gt;$().each()&lt;/em&gt; which is a function that iterates through the context of all matched element(s). As far as I know, there’s two easy ways to accomplish the task without using an iteration. One is to refer the input name/id of the checkbox, assuming that you have an id for the input (which would be exactly the same for each row).&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Markup of the Gridview:&lt;/strong&gt;&lt;/p&gt;

&lt;div style="border: 1px solid gray; margin: 20px 0px 10px; padding: 4px; overflow: auto; line-height: 12pt; background-color: rgb(244, 244, 244); width: 97.5%; font-family: consolas,'Courier New',courier,monospace; max-height: 200px; font-size: 8pt; cursor: text;"&gt;
  &lt;div style="border-style: none; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;
    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: white; width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   1:&lt;/span&gt; &lt;span style="color: rgb(0, 0, 255);"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(128, 0, 0);"&gt;asp:TemplateField&lt;/span&gt;&lt;span style="color: rgb(0, 0, 255);"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   2:&lt;/span&gt;     &lt;span style="color: rgb(0, 0, 255);"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(128, 0, 0);"&gt;HeaderTemplate&lt;/span&gt;&lt;span style="color: rgb(0, 0, 255);"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: white; width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   3:&lt;/span&gt;         &lt;span style="color: rgb(0, 0, 255);"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(128, 0, 0);"&gt;input&lt;/span&gt; &lt;span style="color: rgb(255, 0, 0);"&gt;id&lt;/span&gt;&lt;span style="color: rgb(0, 0, 255);"&gt;="headercheck"&lt;/span&gt; &lt;span style="color: rgb(255, 0, 0);"&gt;type&lt;/span&gt;&lt;span style="color: rgb(0, 0, 255);"&gt;="checkbox"&lt;/span&gt; &lt;span style="color: rgb(0, 0, 255);"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   4:&lt;/span&gt;     &lt;span style="color: rgb(0, 0, 255);"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(128, 0, 0);"&gt;HeaderTemplate&lt;/span&gt;&lt;span style="color: rgb(0, 0, 255);"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: white; width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   5:&lt;/span&gt;     &lt;span style="color: rgb(0, 0, 255);"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(128, 0, 0);"&gt;ItemTemplate&lt;/span&gt;&lt;span style="color: rgb(0, 0, 255);"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   6:&lt;/span&gt;         &lt;span style="color: rgb(0, 0, 255);"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(128, 0, 0);"&gt;input&lt;/span&gt; &lt;span style="color: rgb(255, 0, 0);"&gt;id&lt;/span&gt;&lt;span style="color: rgb(0, 0, 255);"&gt;="rowcheck"&lt;/span&gt; &lt;span style="color: rgb(255, 0, 0);"&gt;type&lt;/span&gt;&lt;span style="color: rgb(0, 0, 255);"&gt;="checkbox"&lt;/span&gt; &lt;span style="color: rgb(0, 0, 255);"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: white; width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   7:&lt;/span&gt;     &lt;span style="color: rgb(0, 0, 255);"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(128, 0, 0);"&gt;ItemTemplate&lt;/span&gt;&lt;span style="color: rgb(0, 0, 255);"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   8:&lt;/span&gt; &lt;span style="color: rgb(0, 0, 255);"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(128, 0, 0);"&gt;asp:TemplateField&lt;/span&gt;&lt;span style="color: rgb(0, 0, 255);"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;In your script, you can easily refer to each instances of the rowcheck by doing this, then perform a function accordingly (see code below). This is probably a safer approach since you’re pointing to a specific id. This is perfect if you have another column that also uses a checkbox control.&lt;/p&gt;

&lt;div style="border: 1px solid gray; margin: 20px 0px 10px; padding: 4px; overflow: auto; line-height: 12pt; background-color: rgb(244, 244, 244); width: 97.5%; font-family: consolas,'Courier New',courier,monospace; max-height: 200px; font-size: 8pt; cursor: text;"&gt;
  &lt;div style="border-style: none; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;
    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: white; width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   1:&lt;/span&gt; $(&lt;span style="color: rgb(0, 96, 128);"&gt;"#rowcheck"&lt;/span&gt;).attr(&lt;span style="color: rgb(0, 96, 128);"&gt;"checked"&lt;/span&gt;, &lt;span style="color: rgb(0, 0, 255);"&gt;function&lt;/span&gt;(){});&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;A more generic approach would be as follows (see code below). The grdWhatever refers to the id of the Gridview. Something like the code below would work only if only 1 column uses a checkbox since this approach would get every single checkboxes within that specific id of the Gridview that has an input type of checkbox. In most cases, checkboxes are rarely used no more than in a single column.&lt;/p&gt;

&lt;div style="border: 1px solid gray; margin: 20px 0px 10px; padding: 4px; overflow: auto; line-height: 12pt; background-color: rgb(244, 244, 244); width: 97.5%; font-family: consolas,'Courier New',courier,monospace; max-height: 200px; font-size: 8pt; cursor: text;"&gt;
  &lt;div style="border-style: none; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;
    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: white; width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   1:&lt;/span&gt; $(&lt;span style="color: rgb(0, 96, 128);"&gt;"#grdWhatever input:checkbox"&lt;/span&gt;).attr(&lt;span style="color: rgb(0, 96, 128);"&gt;"checked"&lt;/span&gt;, &lt;span style="color: rgb(0, 0, 255);"&gt;function&lt;/span&gt;() { });&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Putting it all together:&lt;/strong&gt;&lt;/p&gt;

&lt;div style="border: 1px solid gray; margin: 20px 0px 10px; padding: 4px; overflow: auto; line-height: 12pt; background-color: rgb(244, 244, 244); width: 97.5%; font-family: consolas,'Courier New',courier,monospace; max-height: 200px; font-size: 8pt; cursor: text;"&gt;
  &lt;div style="border-style: none; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;
    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: white; width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   1:&lt;/span&gt; $(document).ready(&lt;span style="color: rgb(0, 0, 255);"&gt;function&lt;/span&gt;() {&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   2:&lt;/span&gt;     $(&lt;span style="color: rgb(0, 96, 128);"&gt;"#headercheck"&lt;/span&gt;).click(&lt;span style="color: rgb(0, 0, 255);"&gt;function&lt;/span&gt;() {&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: white; width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   3:&lt;/span&gt;         &lt;span style="color: rgb(0, 0, 255);"&gt;this&lt;/span&gt;.&lt;span style="color: rgb(0, 0, 255);"&gt;checked&lt;/span&gt; = !(&lt;span style="color: rgb(0, 0, 255);"&gt;this&lt;/span&gt;.&lt;span style="color: rgb(0, 0, 255);"&gt;checked&lt;/span&gt; == &lt;span style="color: rgb(0, 0, 255);"&gt;true&lt;/span&gt;);&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   4:&lt;/span&gt;         &lt;span style="color: rgb(0, 0, 255);"&gt;var&lt;/span&gt; ischecked = !(&lt;span style="color: rgb(0, 0, 255);"&gt;this&lt;/span&gt;.&lt;span style="color: rgb(0, 0, 255);"&gt;checked&lt;/span&gt; == &lt;span style="color: rgb(0, 0, 255);"&gt;true&lt;/span&gt;);&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: white; width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   5:&lt;/span&gt;         $(&lt;span style="color: rgb(0, 96, 128);"&gt;"#grdWhatever input:checkbox"&lt;/span&gt;).attr(&lt;span style="color: rgb(0, 96, 128);"&gt;"checked"&lt;/span&gt;, &lt;span style="color: rgb(0, 0, 255);"&gt;function&lt;/span&gt;() {&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   6:&lt;/span&gt;             &lt;span style="color: rgb(0, 0, 255);"&gt;this&lt;/span&gt;.&lt;span style="color: rgb(0, 0, 255);"&gt;checked&lt;/span&gt; = ischecked;&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: white; width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   7:&lt;/span&gt;         });&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: rgb(244, 244, 244); width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   8:&lt;/span&gt;     });&lt;/pre&gt;

    &lt;pre style="border-style: none; margin: 0em; padding: 0px; overflow: visible; line-height: 12pt; background-color: white; width: 100%; font-family: consolas,'Courier New',courier,monospace; color: black; font-size: 8pt;"&gt;&lt;span style="color: rgb(96, 96, 96);"&gt;   9:&lt;/span&gt; });&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;The headercheck refers to the header input checkbox that triggers the event&amp;nbsp; to select/deselect the underlying checkboxes. Line 3 reverses the current selection then a variable was introduced to hold whatever the selection was. It then proceeds the iteration of all checkboxes within grdWhatever and apply the same selection to them.With only 7 lines of codes (less the document.ready function), you can't go wrong with this type of implementation. It's readable and very simple to implement.&lt;br&gt;&lt;/p&gt;

&lt;p&gt;On my next post, I’ll probably be posting more jQuery applications to solve common issues and/or build upon old Javascript codes and somehow compress them.&lt;/p&gt;

&lt;p&gt;- Dennis
  &lt;br&gt;&lt;a href="http://www.menacestudio.com" target="_blank" mce_href="http://www.menacestudio.com"&gt;menacestudio.com&lt;/a&gt;&lt;/p&gt;
</description><pubDate>Sun, 22 Feb 2009 02:34:00 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/using-jquery-to-select-deselect-gridview-checkboxes</guid><category>jquery asp.net gridview javascript</category></item><item><title>Using jQuery in VS 2008</title><link>https://weblogs.asp.net:443/dennisthemenace/using-jquery-in-vs-2008</link><description>&lt;p&gt;I’ve been reading a lot about jQuery lately (actually since last month) but more so lately because I’d like to know what the buzz is all about. When I first heard about it last year, I simply just ignored it because I know that jQuery is only one of many UI libraries out there. When Microsoft announced that Visual Studio 2008 officially supported the framework via its intellisense, I started paying attention. Now jQuery is becoming more and more popular these days and I’ve noticed that a lot of web sites tends to learn more towards web 2.0 interface now. The UI side of things has finally come back and emerge back in the scene in terms of web development.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;What is jQuery?      &lt;br /&gt;&lt;/strong&gt;Now what exactly is jQuery? In simple terms, it’s basically a Javascript library or framework that enables developers to interact with the DOM (document object model) with less effort and/or less code. The small framework performs majority of the interaction in the back-end. For more information and to learn about it, visit the official &lt;a href="http://jquery.com/" target="_blank"&gt;website&lt;/a&gt;. The documentation provides you with the tutorials and functions that you can call to start working with it immediately. Aside from functions, there are also hundreds of available plug-ins that available to be used&amp;#160; right away. They can be considered as a set of libraries that can be called within your code. These plug-ins (or separate js files) are designed to interact with your existing jQuery library, and therefore in most cases can be initialized with a very simple call or statement. The greatest thing that I’ve learned about jQuery is its cross-browser compatability which is a significant advantage. If you’ve been developing web applications for years, it’s frustrating having to deal with making codes work consistently with different browsers.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;jQuery in Visual Studio 2008&lt;/strong&gt;     &lt;br /&gt;Since most of my development efforts are done using VS 2008 (VW Express 2008 @ home), I’ll share some of the things that can make life easier when getting started with jQuery. Most of the things that I have learned is through &lt;a href="http://weblogs.asp.net/scottgu/archive/2008/11/21/jquery-intellisense-in-vs-2008.aspx" target="_blank"&gt;this post&lt;/a&gt; by Scott Guthrie, which pretty much highlights what is required for jQuery to work with Visual Studio 2008.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Steps to make intellisense work:&lt;/strong&gt;     &lt;br /&gt;1. Install the &lt;a href="http://weblogs.asp.net/scottgu/archive/2008/11/21/jquery-intellisense-in-vs-2008.aspx" target="_blank"&gt;Visual Studio 2008 Service Pack 1&lt;/a&gt;.     &lt;br /&gt;2. Install the &lt;a href="http://code.msdn.microsoft.com/KB958502/Release/ProjectReleases.aspx?ReleaseId=1736" target="_blank"&gt;hotfix or patch&lt;/a&gt; for –vsdoc.js to enable JScript editor support.     &lt;br /&gt;3. Download &lt;a href="http://docs.jquery.com/Downloading_jQuery#Download_jQuery" target="_blank"&gt;jQuery&lt;/a&gt; and &lt;a href="http://code.google.com/p/jqueryjs/downloads/detail?name=jquery-1.3.1-vsdoc.js" target="_blank"&gt;Visual Studio documention&lt;/a&gt; into your project. As of current post, the version is 1.3.1. You will need to download both files as both are required (the actual library and the VS-doc for intellisense support).&lt;/p&gt;  &lt;p&gt;The main thing to keep in mind is to make sure that the naming of the files are identical (less the ‘-vsdoc’) since this is how the file is recognized in the VS environment.    &lt;br /&gt;&amp;#160;&lt;a href="https://aspblogs.blob.core.windows.net/media/dennisthemenace/Media/script1_5FF8338B.jpg"&gt;&lt;img title="script1" style="border-top-width: 0px; display: inline; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="57" alt="script1" src="https://aspblogs.blob.core.windows.net/media/dennisthemenace/Media/script1_thumb_245824CB.jpg" width="186" border="0" /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;Since I will be using the jQuery library quite often, the best approach that I’ve found is to include it within your Masterpage file to simplify your development efforts. That’s why we’re using jQuery to begin with –to keep things programmatically simple. &lt;/p&gt;  &lt;p&gt;Within your &lt;strong&gt;Masterpage file’s&lt;/strong&gt; &amp;lt;header&amp;gt; attribute, you can add a reference by writing the code as such and include a &amp;lt;asp:ContentPlaceHolder&amp;gt; for individual pages scripts: &lt;/p&gt;  &lt;div class="csharpcode"&gt;   &lt;div class="csharpcode"&gt;     &lt;pre class="alt"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;head&lt;/span&gt; &lt;span class="attr"&gt;runat&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;server&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;script&lt;/span&gt; &lt;span class="attr"&gt;src&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;scripts/jquery-1.3.1.js&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;type&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;text/javascript&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;script&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre class="alt"&gt;&amp;#160;&lt;/pre&gt;

    &lt;pre&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;asp:ContentPlaceHolder&lt;/span&gt; &lt;span class="attr"&gt;ID&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;contentHeader&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;runat&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;server&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre class="alt"&gt;    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;asp:ContentPlaceHolder&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

    &lt;pre&gt;&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;head&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
  &lt;/div&gt;
  &lt;style type="text/css"&gt;
.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }&lt;/style&gt;&lt;/div&gt;
&lt;style type="text/css"&gt;

.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }&lt;/style&gt;

&lt;p&gt;In your &lt;strong&gt;.aspx file&lt;/strong&gt; that uses the Masterpage file, you can use the &amp;lt;asp:ContentPlaceHolder&amp;gt; within the &amp;lt;head&amp;gt; attribute to interact with the embedded Javascript library.&lt;/p&gt;

&lt;div class="csharpcode"&gt;
  &lt;pre class="alt"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;asp:Content&lt;/span&gt; &lt;span class="attr"&gt;ContentPlaceHolderID&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;contentHeader&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;runat&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;server&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;&amp;#160;&lt;/pre&gt;

  &lt;pre class="alt"&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;script&lt;/span&gt; &lt;span class="attr"&gt;language&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;javascript&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;type&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;text/javascript&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="rem"&gt;// Check if document has been fully loaded&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;        $(document).ready(&lt;span class="kwrd"&gt;function&lt;/span&gt;() {&lt;/pre&gt;

  &lt;pre&gt;            &lt;span class="rem"&gt;// Your code here&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;            $(&lt;span class="str"&gt;&amp;quot;a&amp;quot;&lt;/span&gt;).click(&lt;span class="kwrd"&gt;function&lt;/span&gt;(&lt;span class="kwrd"&gt;event&lt;/span&gt;) {&lt;/pre&gt;

  &lt;pre&gt;                &lt;span class="kwrd"&gt;event&lt;/span&gt;.preventDefault();&lt;/pre&gt;

  &lt;pre class="alt"&gt;                $(&lt;span class="kwrd"&gt;this&lt;/span&gt;).hide(&lt;span class="str"&gt;&amp;quot;slow&amp;quot;&lt;/span&gt;);&lt;/pre&gt;

  &lt;pre&gt;            });&lt;/pre&gt;

  &lt;pre class="alt"&gt;        });&lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;script&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;&amp;#160;&lt;/pre&gt;

  &lt;pre&gt;&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;asp:Content&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;asp:Content&lt;/span&gt; &lt;span class="attr"&gt;ContentPlaceHolderID&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;contentBody&amp;quot;&lt;/span&gt; &lt;span class="attr"&gt;runat&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;server&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;a&lt;/span&gt; &lt;span class="attr"&gt;href&lt;/span&gt;&lt;span class="kwrd"&gt;=&amp;quot;#&amp;quot;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;Click here&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;a&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre class="alt"&gt;&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;asp:Content&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;style type="text/css"&gt;
.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }&lt;/style&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Outsourcing the jQuery library:&lt;/strong&gt;

  &lt;br /&gt;Since there are always new releases for the jQuery library, it can be difficult to keep up to date with every single new releases. Using a Masterpage instantly resolves that issue and having it in its separate /scripts folder helps keep things organized. With every new release comes a new file, which means that over the years that will come, your /scripts folder will build up with archives of releases. One option that I’ve learned is to instead use &lt;a href="http://code.google.com/apis/ajaxlibs/documentation/#jquery" target="_blank"&gt;Google’s API repository&lt;/a&gt; which is always up to date with each new releases. The documentation provides the direct link that can be referenced from your application instantly, but one pitfall that I’ve encountered when applying this approach is it can’t be used in secured websites (https). Internet Explorer will give you an alert that the page includes/contains an unsecured object (referring to the outsourced library). I don’t fully recommend this approach but it’s a logical alternative as to keeping your scripts minimal and the application scalable. In the end, what truly works for you is all that matters. There is also a great post by &lt;a href="http://blogs.msdn.com/webdevtools/archive/2008/10/28/rich-intellisense-for-jquery.aspx" target="_blank"&gt;Jeff King&lt;/a&gt; that also talks about the jQuery/Javascript intellisense feature in VS.&lt;/p&gt;

&lt;p&gt;I hope that this post provides some help and/or insights as to utilizing jQuery in your ASP.NET development.&lt;/p&gt;

&lt;p&gt;- Dennis
  &lt;br /&gt;&lt;a href="http://www.menacestudio.com"&gt;www.menacestudio.com&lt;/a&gt;&lt;/p&gt;</description><pubDate>Mon, 16 Feb 2009 11:24:42 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/using-jquery-in-vs-2008</guid></item><item><title>IIS Error Message: Snap-in failed to initialize</title><link>https://weblogs.asp.net:443/dennisthemenace/iis-error-message-snap-in-failed-to-initialize</link><description>&lt;p&gt;Oh I love errors! LOL…and I love posting about them because I learn something every time. With any issues comes solutions, always. You might not be able to find it the first time or the second time but over time, some way or another you’ll be lead to an actual solution. While working on an ASP.NET issue, I encountered an issue accessing an application. The error goes something like this:&lt;/p&gt;  &lt;p&gt;   &lt;div class="wlWriterEditableSmartContent" id="scid:57F11A72-B0E5-49c7-9094-E3A15BD5B5E7:76058230-f7e8-4248-b4b9-33b2b0c222fa" style="padding-right: 0px; display: inline; padding-left: 0px; float: none; padding-bottom: 0px; margin: 0px; padding-top: 0px"&gt;&lt;pre style="background-color:White;;overflow: auto;"&gt;&lt;div&gt;&lt;!--

Code highlighting produced by Actipro CodeHighlighter (freeware)
http://www.CodeHighlighter.com/

--&gt;&lt;span style="color: #000000;"&gt;[HttpException (&lt;/span&gt;&lt;span style="color: #800080;"&gt;0x80004005&lt;/span&gt;&lt;span style="color: #000000;"&gt;): Server cannot access application directory &lt;/span&gt;&lt;/div&gt;&lt;/pre&gt;&lt;!-- Code inserted with Steve Dunn's Windows Live Writer Code Formatter Plugin.  http://dunnhq.com --&gt;&lt;/div&gt;
Instantly, the first thing that come to my mind is the server’s security access or something that deals with permissions. Looking in the IIS application pool, I encountered another error while opening up an application’s properties.&lt;/p&gt;

&lt;p&gt;
  &lt;div class="wlWriterEditableSmartContent" id="scid:57F11A72-B0E5-49c7-9094-E3A15BD5B5E7:ffdb19d9-311c-43b1-ad6a-96794887707d" style="padding-right: 0px; display: inline; padding-left: 0px; float: none; padding-bottom: 0px; margin: 0px; padding-top: 0px"&gt;&lt;pre style="background-color:White;;overflow: auto;"&gt;&lt;div&gt;&lt;!--

Code highlighting produced by Actipro CodeHighlighter (freeware)
http://www.CodeHighlighter.com/

--&gt;&lt;span style="color: #000000;"&gt;Snap&lt;/span&gt;&lt;span style="color: #000000;"&gt;-&lt;/span&gt;&lt;span style="color: #0000FF;"&gt;in&lt;/span&gt;&lt;span style="color: #000000;"&gt; failed to initialize.
Name:&lt;/span&gt;&lt;span style="color: #000000;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: #000000;"&gt;unknown&lt;/span&gt;&lt;span style="color: #000000;"&gt;&amp;gt;&lt;/span&gt;&lt;span style="color: #000000;"&gt;
CLSID:{A841B6C2&lt;/span&gt;&lt;span style="color: #000000;"&gt;-&lt;/span&gt;&lt;span style="color: #800080;"&gt;7577&lt;/span&gt;&lt;span style="color: #000000;"&gt;-&lt;/span&gt;&lt;span style="color: #000000;"&gt;11D0&lt;/span&gt;&lt;span style="color: #000000;"&gt;-&lt;/span&gt;&lt;span style="color: #000000;"&gt;BB1F&lt;/span&gt;&lt;span style="color: #000000;"&gt;-&lt;/span&gt;&lt;span style="color: #000000;"&gt;00A0C922E79C} &lt;/span&gt;&lt;/div&gt;&lt;/pre&gt;&lt;!-- Code inserted with Steve Dunn's Windows Live Writer Code Formatter Plugin.  http://dunnhq.com --&gt;&lt;/div&gt;

  &lt;br /&gt;These types of errors are out of norm and are exceptions that needs to be dealt with properly since they’re “unknown” and in the server side of things.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Solution:&lt;/strong&gt;

  &lt;br /&gt;1. Make sure that the project directory exists and has the proper permissions. In most cases, this is the issue. If this solution does not work, then proceed with step 2.&lt;/p&gt;

&lt;p&gt;2. &lt;a href="http://support.microsoft.com/kb/885655/" target="_blank"&gt;Microsoft did provide a solution&lt;/a&gt; via the command prompt on how to fix it but didn’t provide a “why” on the issue. This is a big deal because running a script does not guarantee a fix and second, running something without understanding the underlying process can cause more issues. This is like trying to learn Math and having the final solution without knowing the step by step process of achieving the final results. Same thing.&lt;/p&gt;

&lt;p&gt;According to Microsoft’s documentation, running the code below should fix error.&lt;/p&gt;

&lt;div class="wlWriterEditableSmartContent" id="scid:57F11A72-B0E5-49c7-9094-E3A15BD5B5E7:a836ed8d-e742-4ebe-a753-80bf56db1525" style="padding-right: 0px; display: inline; padding-left: 0px; float: none; padding-bottom: 0px; margin: 0px; padding-top: 0px"&gt;&lt;pre style="background-color:White;;overflow: auto;"&gt;&lt;div&gt;&lt;!--

Code highlighting produced by Actipro CodeHighlighter (freeware)
http://www.CodeHighlighter.com/

--&gt;&lt;span style="color: #000000;"&gt;regsvr32 C:\Windows\system32\inetsrv\inetmgr.dll &lt;/span&gt;&lt;/div&gt;&lt;/pre&gt;&lt;!-- Code inserted with Steve Dunn's Windows Live Writer Code Formatter Plugin.  http://dunnhq.com --&gt;&lt;/div&gt;

&lt;br /&gt;- Dennis

&lt;br /&gt;&lt;a href="http://www.menacestudio.com" target="_blank"&gt;Menace Studio&lt;/a&gt;</description><pubDate>Tue, 16 Dec 2008 18:22:53 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/iis-error-message-snap-in-failed-to-initialize</guid></item><item><title>No Visual Studio template found error</title><link>https://weblogs.asp.net:443/dennisthemenace/no-visual-studio-template-found-error</link><description>&lt;p&gt;The last few blogs that I posted about were about errors and there should be no surprise this time as I'm posting another error that I encountered today while firing up Visual Studio 2008 at home. The error that I received was, there was "no Visual Studio template found" and regardless of what framework I picked when creating a new website or project, no template was shown. Take note that I'm also using Microsoft Vista which also added to the issue (as I'll discuss in a few).&lt;/p&gt;&lt;p&gt;When I searched online, I found a dozen of posts from the different forums covering the error and to resolve this issue, I will need to bring up Visual Studio 2008 command prompt. This is pretty much the same as the regular command prompt but designed so that the listed directory is initiated in the installed Visual Studio 9.0 directory.&lt;/p&gt;&lt;p&gt;Users who are using the express edition will need to type: vcseexpress/installvstemplates (C#) while vbexpress.exe/installvstemplates for users that has VB installed. If you're using the pro edition, you will need to type in devenv.exe/installvstemplates to install the templates. While typing the command however, I was prompted by an error stating that the "requested operation requires elevation" which didn't make sense in the beginning. After a few minutes of digging in the web, I found the solution that I was looking for. You will need to bring up the Visual Studio 2008 command prompt alternatively by going to "All Programs&amp;gt;Microsoft Visual Studio 2008&amp;gt;Visual Studio tools and from there, you'll find the command prompt. Instead of clicking on it however, you will need to right-click it instead and run it as an administrator. This issue only occurs in Vista, so if you're using XP--you should be fine.&lt;/p&gt;&lt;p&gt;- Dennis&lt;br&gt;&lt;a href="http://www.menacestudio.com" target="_blank" mce_href="http://www.menacestudio.com"&gt;menacestudio.com&lt;/a&gt;&lt;br&gt;&lt;/p&gt;</description><pubDate>Fri, 11 Jul 2008 07:07:00 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/no-visual-studio-template-found-error</guid><category>Visual Studio</category></item><item><title>Server tag "asp:ScriptManager" is ambiguous</title><link>https://weblogs.asp.net:443/dennisthemenace/server-tag-quot-asp-scripmanager-quot-is-ambiguous</link><description>&lt;p&gt;I have encountered this error message in the past when I upgrade a few projects to 3.5 but it has been at least 3-4 months and found myself stuck with the same dilemma once again today. This error can be attributed to many things but mainly it comes down to web.config or ambigiouty in the references. Like my previous post, I would like to make another mental note as I know for sure that this won't be the last time that I will be seeing this error nor for anybody who upgrades to 3.5 that uses Ajax functionalities. After searching the web for answers, there was no definite response but after an hour of continuous searching, I was able to put all the information together which leads to the fix.&lt;/p&gt;&lt;p&gt;Here are the things that I tried and since that error message doesn't really dictate as to where the ambigiouty was found, I have to make a few guesses. The 4th bullet pretty much fixed my problem.&lt;br&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;I first removed references such as deleting them, then rebuild.&lt;/li&gt;&lt;li&gt;I have to download the latest version of Ajax Control toolkit 3.5 to match the site version (3.5)&lt;/li&gt;&lt;li&gt;One alternative that I have read is to rename the namespace into something different on controls that uses Ajax or AjaxControlToolkit but that would cumbersome if you have a lot of pages that uses Ajax. I found this method to be the least ideal.&lt;/li&gt;&lt;li&gt;In the &amp;lt;controls&amp;gt; section of the web.config, commenting out the &amp;lt;add
tagPrefix="asp" namespace="Microsoft.Web.UI"
assembly="Microsoft.Web.Extensions, Version=1.0.61025.0,
Culture=neutral, PublicKeyToken=31bf3856ad364e35"/&amp;gt; section should do the trick.&lt;/li&gt;&lt;/ul&gt;</description><pubDate>Tue, 27 May 2008 16:38:00 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/server-tag-quot-asp-scripmanager-quot-is-ambiguous</guid><category>ajax</category><category>ajax control toolkit</category><category>ASP.NET</category></item><item><title>No love for VB?</title><link>https://weblogs.asp.net:443/dennisthemenace/no-love-for-vb</link><description>&lt;p&gt;I'm looking around on books that evolves around ASP.NET and I'm starting to see a common pattern among a lot of the books. In most cases, they are predominantly written in C# leaving no alternate code in VB. I know that C# is being pushed by a lot of developers to be a better choice (this is debatable), but I just don't understand why there is a favor towards a single programming language (C# in this case). I'm a VB programmer myself and I know that C# is pretty similar and shouldn't be hard to learn, but the same concern goes the other way around. If most technical books are written in VB, then I'm pretty sure that the C# community will have the same concern as well.&lt;/p&gt;  &lt;p&gt;Believe it or not, there are still plenty of VB programmers out there, and it looks like the resources available (books, articles, etc.) are getting slimmer by the day. I recently purchased Professional ASP.NET 3.5 in C# and VB and found it a great book since it caters to both programming languages. The price/value of the book is respectable as the authors took the time to accommodate both languages. So why don't the other authors do the same thing? Is this too much to ask for?&lt;/p&gt;</description><pubDate>Mon, 17 Mar 2008 21:55:43 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/no-love-for-vb</guid><category>.NET</category><category>ASP.NET</category><category>Visual Basic</category></item><item><title>The type 'System.Web.UI.ScriptManager' is ambiguous</title><link>https://weblogs.asp.net:443/dennisthemenace/the-type-system-web-ui-scriptmanager-is-ambiguous</link><description>&lt;p&gt;Given the error above and more information below:&lt;/p&gt;  &lt;p&gt; The type 'System.Web.UI.ScriptManager' is ambiguous: it could come from assembly 'C:\WINDOWS\assembly\GAC_MSIL\System.Web.Extensions\1.0.61025.0__31bf3856ad364e35\System.Web.Extensions.dll' or from assembly 'C:\WINDOWS\assembly\GAC_MSIL\System.Web.Extensions\3.5.0.0__31bf3856ad364e35\System.Web.Extensions.dll'. Please specify the assembly explicitly in the type name.&lt;/p&gt;  &lt;p&gt;I have to deal with this issue a couple of times and each time, I have to make a mental note. I figured I'd rather make a post so it can help others and myself in the future to solve the issue when upgrading to 3.5&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Steps:&lt;/strong&gt;    &lt;br /&gt;1. Make a backup of your /bin directory and delete all files in it.    &lt;br /&gt;2. Re-build the project or website.    &lt;br /&gt;3. Add all the DLL's associated with the project.    &lt;br /&gt;4. The 4th step is odd but I have to go to Property pages&amp;gt;References and remove both the System.Web.Extensions (3.5) and the System.Web.Extensions.Design (3.5) to make it work. I hope this helps.&lt;/p&gt;  &lt;p&gt;- Dennis   &lt;br /&gt;menacestudio.com&lt;/p&gt;</description><pubDate>Wed, 27 Feb 2008 18:15:55 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/the-type-system-web-ui-scriptmanager-is-ambiguous</guid><category>.NET</category><category>ASP.NET</category></item><item><title>Script module error when upgrading to 3.5</title><link>https://weblogs.asp.net:443/dennisthemenace/script-module-error-when-upgrading-to-3-5</link><description>&lt;p&gt;When I converted a project from 2.0 to 3.5 today, I got an error that appears from the Web.config.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;font color="#ff0000"&gt;"The entry 'ScriptModule' has already been added"&lt;/font&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;It made me think that the cause of the error could be an incompatibility between the old project and the new framework. The problem however only occurs in the server while it compiles fine in my local machine. My initial guess was the server's installation of the framework was the culprit, but after doing some research, I was able to come up with a solution. &lt;/p&gt;  &lt;p&gt;For some odd reason, the upgrade wizard that converts to 3.5 adds an extra line of script module in the web.config which duplicates the entry. I was able to fix this by commenting out the line where the error was pointing.&lt;/p&gt;</description><pubDate>Thu, 14 Feb 2008 18:59:00 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/script-module-error-when-upgrading-to-3-5</guid><category>.NET</category><category>ASP.NET</category></item><item><title>Insertion of a page break in a repeater</title><link>https://weblogs.asp.net:443/dennisthemenace/insertion-of-a-page-break-in-a-repeater</link><description>&lt;p&gt;I was in a situation where I need to break up the data into a separate page after a certain amount of records (in my case 3). I chose to use repeater as I have a full control of the HTML layout and how I want my form to appear in a print format. I posted my question in ASP.NET forums and to my delight received a working code after a full day of torture and doing search in Google. I thought I would share here the snippet that can be useful when a specific scenario arise. It is not a lot of code but it saved me another day of frustration. Now it's time to put it on the side and move on with new projects.&lt;/p&gt;&lt;p&gt;The code below can be altered by changing the page size. Take note that the sub procedure below uses ItemDataBound event, which occurs after the binding of data and before it's displayed on the page (print in this case).&amp;nbsp;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Protected Sub Repeater1_ItemDataBound(ByVal sender As Object, ByVal e As RepeaterItemEventArgs) Handles Repeater1.ItemDataBound&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim pageSize As Integer = 3&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; If (e.Item.ItemType = ListItemType.Item OrElse e.Item.ItemType = ListItemType.AlternatingItem) AndAlso ((e.Item.ItemIndex + 1) Mod pageSize = 0) Then&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; e.Item.Controls.Add(New LiteralControl("&amp;lt;p style='PAGE-BREAK-AFTER: always'&amp;gt;&amp;amp;nbsp;&amp;lt;/p&amp;gt;"))&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; End If&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; End Sub &lt;/p&gt;</description><pubDate>Fri, 25 Jan 2008 18:49:00 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/insertion-of-a-page-break-in-a-repeater</guid><category>ASP.NET</category><category>Visual Basic</category></item><item><title>First post objective</title><link>https://weblogs.asp.net:443/dennisthemenace/first-post-objective</link><description>&lt;p&gt;I'm glad to be part of this great community and have the opportunity to blog with the best in the business. Since .NET has been introducing a lot of new features, it can be cumbersome to keep up with the latest changes. My goal herein my posts is about learning ASP.NET (cause I don't sincerely know it all) which includes topics relevant to problem solving, implementing features and/or give opinions about issues within the technology. I'll post as much as I can, and I hope to be an active participant in this community for years to come.&lt;/p&gt;&lt;p&gt;Lately I have been working with the new Visual Studio 2008 and although there were times when it was slow (mainly switching from code to design view), I'm happy with the upgrade for its improved functionality within coding. I'll be constantly working with the .NET 3.5 framework and hopefully get up to speed with the new things that are included in the package. I'm currently reading the Intelligent Investor by Benjamin Graham but once I'm done with it, a new .NET 3.5 development book is in line for sure.&lt;br&gt;&amp;nbsp;&lt;/p&gt;</description><pubDate>Fri, 25 Jan 2008 16:51:00 GMT</pubDate><guid isPermaLink="true">https://weblogs.asp.net:443/dennisthemenace/first-post-objective</guid><category>.NET</category><category>Visual Studio</category></item></channel></rss>