If you have ever tried working with a TreeView within an UpdatePanel, you would notice that it takes forever to render and on postback the whole application seems to be very sluggish.
The reason this occurs is because the javascript that is emitted by the TreeView does not play well with the Update Panel. This is a known issue, but for some reason is not getting a fix.
One way around this is to disable the scripts emitted by the TreeView control and let the UpdatePanel take care of not causing postbacks via the partial page rendering mechanism. This can be done by setting ‘EnableClientScripts=”false”‘ on the TreeView.
Debut is more than a web cam video capture utility. It is a software that allows you to capture video from most any source. For my purpose however, I needed to find a good, free software that would allow me to capture videos via my web cam.
Other features include encoding into various formats (.avi, .wmv, .asf .mpg and more), capture from external devices and the screen, and quite a few other nifty features.
For a more detailed description check out the website of Debut, including for the download.
I’ve been looking around for a small application that would sit in my taskbar and update me whenever new mail comes in. I don’t know how I missed it, but Google themselves have a tiny application (which seems like a portion out of gtalk) called Gmail Notifier. Small useful application.
Gmail Notifier: Download
If you have ever tried to perform an action within an iFrame when a window is resized then you would notice that using the “onresize” event of the body element within the iFrame is useless. For some reason, the “onresize” event of the page within the iFrame does not fire when the window itself is resized, so attaching a “onresize” event to the body tag of the page doesn’t work.
So basically this is the structure of your page:
<html>
<head></head>
<body>
<iframe id="myIframe" src="iframepage.html"></iframe>
</body>
</html>
Now you want to capture the “onresize” event of the window in your iframe so you can manipulate your interface or do something when it occurs. On a regular page (which has no iframes), placing this in your ‘body’ tag would help.
However, in your iFrame page, using the following will allow you to capture the ‘onresize’ event.
<script>
self.parent.window.attachEvent("onresize", myFunction);
</script>
Place the script tag on your page and it will attach the function to the event.
Most problems with regards to the modalpopupextender not displaying at the center of your page when co-ordinates are not specified arise due to an incorrect DOCTYPE. Usually changing this DOCTYPE will help (as I have pointed out in a previous post of mine). However sometimes it is not possible to change the DOCTYPE as it affects other portions of your page.
In order to fix that you may have to perform a custom build of the AjaxControlToolkit by modifying some of the source.
I’ve tested this out with version 1.0.10920.0 of the AjaxControlToolkit, however I’m sure it works with later versions.
Download the source of the toolkit from codeplex and open the solution using Visual Studio.
The first file you will have to modify is the ‘Common.js’ which is located in ‘AjaxControlToolkit\Common\Common.js’ .
Within this search for the function ‘getClientBounds’. Replace the switch statement with the following one:
switch(Sys.Browser.agent) {
case Sys.Browser.InternetExplorer:
if (document.documentElement && document.documentElement.clientWidth)
clientWidth = document.documentElement.clientWidth;
else if (document.body)
clientWidth = document.body.clientWidth;
//clientWidth = document.documentElement.clientWidth;
if (document.documentElement && document.documentElement.clientHeight)
clientHeight = document.documentElement.clientHeight;
else if (document.body)
clientHeight = document.body.clientHeight;
//clientHeight = document.documentElement.clientHeight;
break;
case Sys.Browser.Safari:
clientWidth = window.innerWidth;
clientHeight = window.innerHeight;
break;
case Sys.Browser.Opera:
clientWidth = Math.min(window.innerWidth, document.body.clientWidth);
clientHeight = Math.min(window.innerHeight, document.body.clientHeight);
break;
default: // Sys.Browser.Firefox, etc.
clientWidth = Math.min(window.innerWidth, document.documentElement.clientWidth);
clientHeight = Math.min(window.innerHeight, document.documentElement.clientHeight);
break;
}
The next set of changes to be made are to the ‘initialize’ function of the ModalPopupExtender which is located in the ‘AjaxControlToolkit\ModalPopupExtender\ModalPopupBehavior.js’ file.
Within the ‘initialize’ function search for
this._backgroundElement.style.position = 'fixed';
and change it to this
this._backgroundElement.style.position = 'absolute';//'fixed';
A few lines below that is another change that has to be made from:
this._foregroundElement.style.position = 'fixed';
to:
this._foregroundElement.style.position = 'absolute';//'fixed';
Once you have made the changes compile the source and you should be able to use your new AjaxControlToolkit.dll in order to resolve most of the centering issues known to occur with the ModalPopupExtender.
Make sure to backup your original files before you attempt this.
Locating a good mechanic for your car is a big hassle. One would hope that the big name shops like ‘Pep Boys’ would live up to their names in customer service. This is however a review of my experience with ‘Pep Boys’ located on the feeder of US-59 in Houston. I know that stores like ‘Pep Boys’ are franchised and hence service from one store to another varies. Which is why I’m being specific to this location when I write my review.
What: Automobile Repair
Who: Pep Boys
Address: 7525 Southwest Fwy, Houston, TX - (713) 779-8600
Ever since coming to Houston and I have been going to Pep Boys for all my automotive repairs. Needless to say I’m not a “happy” customer when I come out, but they manage to do a fair job, or so I thought, up until now.
I own a 1999 Pontiac Grand Am and recently my battery lights came on on the dashboard. Being the kinds who doesn’t like things not in working order, I immediately made my way to a nearby Autozone to get it checked out. After a few minutes of checking the battery, the guy at Autozone told me that my battery was fine, but my alternator was close to failing. It wasn’t pushing out the required volts needed in order to charge the battery. Autozone has friendly customer service.
So Pep Boys being my usual auto repair shop, I called them and asked them if they could fix up the alternator if I had bought it elsewhere. They said they would, but only if I’d gotten it from O’Reilly’s or a couple of other places (but NOT from Autozone). Luckily I hadn’t purchased on yet and I did get one from O’Reilly’s. I’m not sure why people do not like Autozone for parts (I’ve heard its because they are no up to the mark in terms of quality, but I have not validated that yet).
Either ways, dropped off my car and the alternator at Pep Boys, after they told me it would cost me $130 for labor alone ($230 if I’d purchased the alternator from them. I picked up the alternator from O’Reilly’s for much cheaper and the whole thing came to $170). I didn’t shop around for prices, and no one else was willing to fit an alternator that was purchased from outside, so I decided to go with it (like I had another choice).
The next day they called me to tell me that there was some ‘pig tail’ like contraption that was broken and they needed to replace it. They also told me that it cost $40 (so there goes all the savings I thought I was making). Having no other choice, I told them to go ahead anyways.
That afternoon while picking up the car, I asked them if I had warranty on everything and they said the parts warranty would be from whom I bought the alternator (O’Reilly), but because I never bought the parts from them they could not give me a warranty on the labor.
Paid up, walked out, drove my car and then about 10 miles out a whole lot of lights came on. The airbag light was the first to come up. I never knew why, but I decided to check that out later. In the evening on the way home, I started the car and shifted it into gear it jerked like crazy. It was almost as though the whole engine shifted. This jerking effect would kick in everytime the automatic gears would shift up.
Besides the airbag lights and the jerking, the next things that gave problem were that the traction control and abs lights switched on. It was as though the car was having a total breakdown and I wasn’t sure why because all I had replaced was the alternator which I figured was relatively easy to replace.
A day or two later I took it back to PepBoys to ask them why thinks were working that way and they told me that it might be a problem with the engine and they would have to take a look, but taking a look would cost $$$’s.
Having screwed up the first time I did NOT want to leave it with them. Who knows what they might do or charge me for next.
So I spent the next week attempting to find a good mechanic. Got info about one through my friend and showed it to him. The moment he looked at it he told me I was ripped off and that was the worst alternator job he’d seen. He couldn’t believe it when I told him ‘Pep Boys’ did this job. He was like “Pep Boys did this!!?!?!”.
According to him, what they charged me $130 bucks to do, should have actually cost me $40. And he didn’t know about no pig tailed crap. By the time the check engine light had come on, so I decided to give it in for an engine tune up as well.
Another $239 bucks later and a fixed alternator job and engine tune up and my car is running like spiffy new :). I asked the mechanic what had happened and apparently the “pig tailed” thing they were refering to was the wires connecting to the alternator (a set of 4 wires). They spliced it up and tried to fix it back together and got all the connections mixed up.
So the reason for all the lights going on and the engine jerks and everything that was happening was because they screwed up fixing in the alternator.
This is not the first time something like this has happened. Previously someone I know had their car fixed up there and everytime it would come back with a new problem until it just totalled almost.
In my opinion, these guys really don’t know what they are doing half the time or get in-experienced staff to work on things and mess them up.
Conclusion: The staff at PepBoys are fairly irresponsible, do not perform a check once they fix things up, probably don’t even fix things up right, overcharge for their services and just make life miserable for the customer. This has been a harrowing experience and has lasted more than a week. I would NOT go back to this Pep Boys store and would NOT recommend that anyone goes there.
February 29th, 2008 in
Reviews | tags:
Houston,
pep boys,
Review |
13 Comments
The IE Developer Toolbar is similar to Firebug for Firefox. It provides you with a set of tools for troubleshooting pages efficiently (helps a whole lot with those positioning/css issues).
Downloading and installing the toolbar is straightforward and works without a hitch. However, when I tried to use it, It would never work. I tried installing/uninstalling a couple of times with no luck. Clicking on the IE Developer toolbar icon does nothing and if you reach it via the menu Tools-Toolbars-Explorer Bar->IE Developer toolbar, it brings up the toolbar which does not help you in any manner.

After a little hunting around I found that the reason it does not work is because 3rd party extensions are not enabled.
This can be enabled via ‘Tools->Internet Options->Advanced->Browsing->Enable third-party browser extensions’. Check that, apply your changes and restart IE. The toolbar should now show up with the DOM elements and their corresponding styles and attributes.
Its a good tool to have at your disposal.
Link to download: Microsoft IE Developer Toolbar
After recently purchasing a laptop, I mistakingly removed the webcam software that came with it. After hunting for a software that would help me capture pictures, I came across Yawcam. It is a simple software that lets you capture pictures to a file, stream it, motion detection etc.
Its a nice replacement for the stock software that comes with your computer (might not have all the same functionality).
You can reach the Yawcam website via this link: Yawcam
February 13th, 2008 in
Software | tags:
Software,
Webcam |
No Comments
If you are attempting to convert your existing Asp.net web application to an AJAX Enabled Asp.net web application, you most probably followed down the path of merging your existing web.config with one that is provided by a new Asp.net AJAX Enabled web application’s web.config.
This worked fine for me until I tried adding a AutoCompleteExtender and needed to declare a method in code behind with the attributes
[System.Web.Services.WebMethodAttribute(), System.Web.Script.Services.ScriptMethodAttribute()]
That’s when I came across the following error:
The type or namespace name ‘ScriptManager’ does not exist in the namespace ‘System.Web.UI’ (are you missing an assembly reference?)
Having merged the web.config files I assumed I should not be getting the error. However, what I had failed to do was merge the .csproj files. Apparently some references are in the .csproj file. Mainly, the reference to the System.Web.Extensions.
Adding a reference to the System.Web.Extensions should fix the problem.
Recently I had to work with the ModalPopupExtender that comes with the AjaxControlToolkit. I’ve worked with it before, but this time it posed a couple of problems (that were caused not because of the toolkit, but rather other things).
Without specifying the “X” and “Y” attributes of the ModalPopUpExtender(MPE) it is supposed to, by default, render at the center of the screen. Sometimes this doesn’t happen. The solution to getting it to render at the center of the screen is adding the following doctype to your page:
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd”>
Even then, my page didn’t seem to display the popup right. Its only later that I discovered that I was using Response.flush on the page to display a “Loading…” screen. This causes the html used for the “Loading…” screen to be the first thing on the page.
Since the DOCTYPE is now forced down the page, the rest of the page does not render as per the specified DOCTYPE. This causes the MDE to render at some other position on the screen (other than the center).
To fix this, Response.Write and Flush your DOCTYPE tag first, so it becomes the first line on the page.