Skip to main content

Posts

Console.Log : Say Goodbye to JavaScript Alerts for Debugging!

Admit it, you’ve done it. You have a bug somewhere in your web page and you add an alert to popup a useful message like “I am in the if statement” or “varName=Bob” to help you figure out what is wrong with your code.  In IE9 we have an alternative: the Console object . ASP.NET programmers who work in Visual Studio may already be familiar with the  debug  object. You call methods of the debug class in your .NET code to display messages in the Output window to help you debug your code in Visual Studio. The Console object is the IE9 equivalent. Hopefully you have already discovered the Developer tools in IE8 and IE9. If not, just open your browser and go to a website, any website will do. Now hit F12. This will bring up the developer tool window. Now go to the Console tab. Now try typing  console.log(“Hello world”)  in the console command line at the bottom of the window. Your output should look something like this. console.log  will display the pa...

How to handle console.log programmatic in global scope

Methods Since  console  isn’t yet formally covered by a specification, implementations vary. In Node it’s closely tied to standard input output, referred to as “stdio” by the documentation. This gives rise to  error  and  log  methods that will be printed to the appropriate output stream. Most implementations give us convenient ways of separating output for debugging messages, errors, and warnings: console . log ( 'This is merely an informational debug message' ); console . warn ( 'This is a warning' ); console . error ( 'This is an error' ); Inspection and Concatenation In most browsers and Node, objects will be automatically printed in a readable format when using  console.log . That means printing variables is possible without any extra effort: console . log ({ alex : "some dude" }); How to handle Console.log Programmatic globally? // Declare flag values used as parameters to Fixconsole() method. var ALERT_ON = false;...

ExtJS - Grid panel features

What can we do with ExtJS GridPanel? I have to develop a lot of applications in my web app and I see that grid component of ExtJS may fit in. However, I am not aware of what all things I can do with the - off the shelf available framework pieces - available plug-ins in the marketplace and - custom development through my own developers This is a typical question that we hear from the business users who wants to design an application by keeping the framework’s capability in perspective. In this article I have tried to put the list of stuff you can do with grid and hopefully that shall enable you to take advantage of the beauty of ExtJS. Pre-requisites This article assumes that you are familiar with basics of ExtJS What are the available options? In this section I will be taking you through some of the commonly seen usage of ExtJS grid panel. While covering all the capabilities of grid may not be possible, I am sure it will be helpful for the business users who want to...