Friday, October 31, 2008

Debugging without break the code.


In a earlier project that i had worked, i used remote debugging, that work just fine, until the network policies were changes, and then it was extremely painful to make some kind of debugging, and i then i make use of the old fashion debug of using Response.Writeln(value to debug) or Debug.WriteLine(value to debug).

Today i found a hidden feature of the VS debugger, call "When Hit...". That feature gives the possibility to use breakpoints has run time markers to extract values.

After you select the breakpoint with right mouse click, a window appears so you can configure the behaviour of your breakpoint.


In the textbox Print a message we write the syntax of what we want the debugger to tell us, when he passes on that breakpoint. As an example on the output window will appear this messages if we configure the breakpoint as the window above.
Function: Some_Event(object, System.EventArgs), Timestamp: "18:15:54"
Function: Some_Event(object, System.EventArgs), Timestamp: "18:15:54"
(...)

This feature also allows the execution of a macro, witch provides other process to be trigged by our breakpoint.

Tuesday, October 28, 2008

Handling a Timeout on a Async Request.







Today i got a chalange to break trought, that was handling a Timeout on a Async Request, and i find out that the solution was in adding to the HTML source a Page Request Manager that validates if the request fall into a Timeout. Sys.WebForms.PageRequestManager.getInstance().add_endRequest(function (sender, args) {

if (args.get_error() && args.get_response().get_timedOut()) {

// Tratar o timeout

// colocar o errorHandled = true para evitar receber a popup gerada pela biblioteca de AJAX.

args.set_errorHandled(true);

}

});



And belive me, it works ...

Monday, October 6, 2008

Books, Books and more Books


Here are some links to free Technical Books

Freecomputerbooks.com
Freetechbooks.com
Onlinecomputerbooks.com

Sunday, October 5, 2008

How was Microsoft Dreamway

In friday the Dreamway event occur in the Centro Cultural de Belém (CCB). Another event to review old friends, colleagues and to know more about the new Microsoft Technologies.

After checking in, i assist the Pedro Rosa and Nuno Costa session, that talk about the new tendencies in development, and they explain the Software as a Service concept and show some demos, where we can saw what Microsoft technologies were able to do, such as Silverlight in rich presentations and User Interfaces, such Virtual Earth in maps, or the Live services

Next, i had a coffee break and then i went to a session that talk about the vantages of using the Visual Studio Team System, and in witch way that unit test could be created in this Integrated Development Environment (IDE).

In the next session, presented by Ivo Ramos, i was able to see how easy is to developers and database administrators (DBAs) can work together, and how Visual Studio Team System 2008 Database Edition can help with that task.
Using and database project, developers can work and save the database schema into source control, and also stored procedures, tables etc.

After lunch, Miguel Caldas presented whit is peculiar style, the main features of the new IE8, where one of the most important is the backward compatibility with previous browsers, by telling to IE8 to assume the behavior of IE7, IE6 or even IE5.

In the middle of the Miguel Caldas presentation, at the sound of loud rock music and wrestling star style, Microsoft CEO Steve Ballmer showed at the event, and in front of a majority audience of developers he said that the biggest strength to mobilize an economy was "Developers, Developers, Developers", and Microsoft mission was to guarantee the conditions and tools that developers can do their job.

After the Steve Ballmer session i went to assist an session about ADO.NET Data Services and Microsoft Entity Framework, brilliant presented by Nuno Silva.
Nuno Silva presented the way how does the MS Entity Framework work, he show that the MS Entity Framework is an abstraction of the data model witch the developers only needs to know the entity that he wants the data from. Instead of making a selection with ten inner joins to get an entity, with MS Entity Framework he can create those entities. Another aspect of the MS Entity Framework is that you can create an entity that inherits from another entity.
The ADO.NET Data Services also know as Astoria, is the getting the data access layer (DAL) in a Representational State Transfer (REST ) way, by an URL like an SOAP web service.

Friday, September 12, 2008

Sharepoint Development Bible

Microsoft Office Sharepoint has became the most selled Content Management System (CMS) on the market, but the developement of applications on this CMS is done with lack of knowledge giving little use of the product qualities.

Microsoft Technet releases a group of documents and resources that are usefull for best practices in Sharepoint development.

This bible for Sharepoint development can be found in here

Thursday, September 11, 2008

10 Reasons to use Google Chrome

10. Dynamic Search Engines

- Google Chrome allows to add several search engines on the main page, to do that you must:


Go to a search engine. Ex: www.yahoo.com


At the right side will appear an option to press the TAB key to search on the following selected search engine.

After a search, the selected search engine will appear in your main window.





9. Dictionary

Google Chrome has its own dictionary with a lot of languages available.




8. Multilingual

Google Chrome is truly multilingual, with a single selection of a language we change all Chromes culture.

7. Separated Browsing Data Cleaning

In other browser the cleaning of the browsed data its made to all browsed data files, Chrome allows you to choose between a day and a month to clean your Internet files.



6. Thumbnails of most visited websites.

Main page of Chrome shows the most visited websites in Thumbnails


5. Browse without a trace

This feature allows you to navigate without leaving an History, Cookies or any other record of the web sites you been surfing on.


4. JavaScript Console

The JavaScript Console allows to check and test javascript snippets on the fly.

3. JavaScript Debug

On Selecting this option an window will open and attach the process that handles the debug caller window, for debug.


2. Task Manager

Chrome handles windows and tabs as a sub-process of the browser, and we can kill those processes without shutting down the browser.




1. Dynamic Search


By typing any word on the address bar Google Chrome will search for that you type, give suggestions and it search also in GMail if you are logged in.