Windows 10 - Display driver has stopped responding and has recovered.

by Duane Urban 15. July 2016 01:02
There are many reasons this happens but in my case it only happened when I was using Firefox.  I corrected the problem using the following steps: Navigate to Options>Advanced>General.  Under ‘Browsing’, uncheck the "Use hardware acceleration when available."  That should fix your problem.  As an added benefit Firefox seems to respond faster after the change.  

Tags:

ASP.Net Maintain Scroll Position

by Duane Urban 17. November 2015 08:41
It is easy to configure your site to maintain it's scrolling position.  Simply modify the <pages> directive in the web.config file to: <pages maintainScrollPositionOnPostBack="true"> That works even in an UpDatePanel.

Tags:

ASP.NET

The Empress Unbound (The Wayward Assassin: Book 2) Teaser

by Duane Urban 9. November 2014 16:41
Here is an excerpt from the first chapter of the second book in in the Wayward Assassin series - The Empress Unbound. Enjoy. [More]

Tags:

PHP Error - function.session-start: Cannot send session cache limiter - headers already sent

by Duane Urban 24. November 2013 01:06
If you have the session_start(); on the first line and the error message points to line 1 as where the error is, it means your PHP file is BOM encoded.  To repair your file use a program like Notepad++ then select > Encoding > Convert to UTF8 without BOM.  Then go back to Encoding and verify that Encode in UTF8 without BOM is selected.  If so, Save your file then upload it and view in your browser.  The error should be fixed.

Tags:

PHP | Error

Using Built-in HTML 5 Validation On An ASP:TextBox Control

by Duane Urban 10. October 2013 12:21
In HTML 5 validating an input is easy; all you have to do is add a "required" attribute to your text box.  ASP.NET has plenty of built in controls for validating which all add overhead to your page in the form of auto-generated JavaScript.  On the internet less is best however. Plus why write lots of code (sort of) when you don't have to? This is what you do in your CodeBehind:  VB.NET Me.txtPassword.Attributes.Add("required", Nothing) C# this.txtPassword.Attributes.Add("required"... [More]

Tags:

Programmatically data binding an AJAX Control Toolkit Accordion In CodeBehind

by Duane Urban 8. October 2013 17:27
Data binding an Accordion control is surprisingly simple and is no different than binding to DataView’s, ListView’s, etc. [More]

Tags:

Accordion | AJAX Control ToolKit | ASP.NET

Crop an article to a defined length using PHP

by Duane Urban 26. May 2013 13:11
If you need to crop an article to a defined length using PHP this function will do the trick. [More]

Tags:

PHP

Using jQuery to highlight a selected navigation link

by Duane Urban 26. May 2013 12:51
This is a simple way to highlight a navigation link for the active page using jQuery. [More]

Tags:

CSS | HTML | jQuery

Query XML With LINQ to Populate an asp:Repeater from Attribute Values

by Duane Urban 13. February 2013 06:10
Use LINQ to query an XML file and extract attribute values. [More]

Tags: , ,

ASP.NET | LINQ | XML

Modal Popups using JavaScript and CSS

by Duane Urban 3. August 2012 06:37
Displaying modal popups is easy with a little JavaScript and CSS. [More]

Tags:

JavaScript | CSS