Common ASP.NET Problems (together in one post)
February 12, 2008
1. You have IIS and ASP.NET 1.1 running OK. Now you want to run ASP.NET 2.0 for one webfolder with 1.1 running remaining site. You started getting “Failed to access IIS metabase”.
Solution : Run aspnet_regiis in asp.net 2.0 folder
C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727> aspnet_regiis -ga ASPNET
Then reset IIS
(more to be added soon….)
ASP.NET MVC Framework CTP Released!
December 11, 2007
Community Technology Preview Release of MVC Framework is released. Go get it from http://asp.net/downloads/3.5-extensions/
Some documentation is available at http://quickstarts.asp.net/3-5-extensions/mvc/default.aspx
For Help or See what others thinking see forums at http://forums.asp.net/1146.aspx
I am thinking of posting a tutorial pretty soon …..comparsing side by side of Rails and ASP.NET MVC….. stay tuned.
Updated to IE7 and the Problems….
November 27, 2007
I been still surviving on IE6 until recently (as I use most of the time Opera or Firefox, I never bother to upgrade IE). But as I was playing with Silverlight, I need another browser to test my silverlight applications other than Firefox2. Upgrade is painless (you need to restart though at the end).
After that, any links from my Yahoo messenger were not working… same the case with Visual Studio 2005/2008…. I guess infact any attempt to launch a webpage from outside the browser was unsuccessful…..
How to fix it….. my first guess was may be IE7 deleted or moved IE6 executable (Not replaced….as it wont be problem)…… and all these applications keep trying to lookup IE6 ………..
Well…. I was wrong…… what happend was … IE6 was set as default browser at the time IE7 was installed and IE7 is not set automatically as default browser…….may be it asked me….I dont remember….. so all these applications are trying to launch default browser app…….without much success………..
So to Fix, simply launch IE7…. go to Tools –> Internet Options —> Programs and Make IE7 as default browser……. that should fix all these broken links…………
Trying out Popfly beta
November 19, 2007
I haved tried Yahoo Pipes sometime back when it was beta. Popfly is Microsoft’s stab at creating mashups. Mashups allows you to connect multiple data sources to display units visually without any coding.
Popfly requires Microsoft SilverLight runtime ( Microsoft version of Adobe brought Macromedia’s Flash Player) to be installed to create mashup and also to view it. You also need windows live account.
My first test using IE 6 was not pleasant with blurry ghosty images whenever you move over any of the controls. Also I didnt see any output when clicked on Preview. You could see a popup warning saying “you are not using IE7 or Firefox 2.0. ..your expereince may vary”. My second attempt with Firefox 2 is lot better. It worked smoothly (though I had trouble installing silverlight on Firefox. It ended up the problem is not with silverlight but NoScript addon… NoScript has a setting to forbid Silverlight for untrusted sites and some reason popfly is considered as untrusted site).
Also note that Opera wont work as silverlight is not supported on Opera browser. I use opera for most of the dialy browsing so it would be nice if silverlight support comes for opera in future.
Overall experience with Popfly is good and is bit faster than Yahoo Pipes (atleast when Pipes was beta). Popfly also makes creating template based webpage easier and quick and add as many as mashups embedded in that page.
Look at a simple mashup and webpage I did at http://www.popfly.ms/users/siri/myhomepage
Visual Studio 2008 & .NET 3.5 released Today
November 19, 2007
Some of the new features in VS 2008 that makes you happy are
(List taken from wonderful Blogs of ScottGu and Brad Adams)
- Support for .NET 2.0, 3.0 and 3.5 runtimes
- JavaScript intellisense
- Much richer JavaScript debugging
- Nested ASP.NET master page support at design-time
- Rich CSS editing and layout support within the WYSIWYG designer
- Split-view designer support for having both source and design views open on a page at the same time
- A much faster ASP.NET page designer - with dramatic perf improvements in view-switches between source/design mode
- Automated .SQL script generation and hosting deployment support for databases on remote servers
- LINQ support
Rails like MVC Framework From Microsoft
November 13, 2007
Recently there is some news about Microsoft building a MVC framework to go with ASP.NET and run on NET 3.5 framework. You could see the first detailed blog entry about it in ScottGu’s blog today. Looks promising with no postback & viewstate baggage. I will be updating my impression on this one soon.
Nested Classes in Ruby
October 10, 2007
You could create classes inside another classes in Ruby. In Ruby, classes defined are stored as constants with same name as class. And as you know Ruby class definitions are executable code and it execute in the context of that class as the current object. That means any classes (say B,C) defined inside another class (A) would act like constants of that outer class ( as A::B, A::C).
Lets look at some code
class Adef test_method
“I AM NOW IN CLASS A”
end
class B
def test_method
“I AM NOW IN CLASS B”
end
end
end p A.new.test_method –> “I AM NOW IN CLASS A”
p A::B.new.test_method –> “I AM NOW IN CLASS B”
See how we accessed Class B as A::B
PostgreSQL Log Analysis using Ruby’s PQA
September 25, 2007
Step1 : Install Ruby
Download Source ruby-1.8.5.tar.gz $ tar -xvfz ruby-1.8.5.tar.gz $ cd ruby-1.8.5 $ configure $ make $ make install
Step 2: Install Ruby gems
Download rubygems-0.9.4.tgz $ tar -xvfz rubygems-0.9.4.tgz $ cd rubygems-0.9.4 $ ruby setup.rb
Step 3: Install Practical Query Analysis
Download pga gem $ gem install pqa-1.6.gem
Step 4: Configure PostgreSQL
In postgresql.conf file, makesure these settings are on
log_statement true log_duration true log_pid trueRestart PostgreSQL to make these changes in effect.In my case postgresql is setup as a service to start at boot. so restarting is easy.
service postgresql restart
Step 5: Use PQA to anlayze log
pqa -file /path/to/your/logfile -normalize -top 5To generate a HTML Report
pqa -file /path/to/your/logfile -normalize -top 5 -format html > /tmp/myReport.html
Thats it!. You could find slowest queires, most run queries and other cool stuff from this great tool. you could out details and detailed documentation at http://pgfoundry.org/projects/pqa/
Rails IDEs - 3rdRails From CodeGear
September 23, 2007
I tried using Aptana and JEdit as IDEs for Rails development (to some success but not fully happy) before and recently tested CodeGear’s 3rdRail. I could see that 3rdRails is also designed based on Eclipse platform (same as case for Aptana Radrails). But what makes 3rdRail different from Aptana (other than $299 price tag) is couple of cool features like Logical representation of folders/files in project explorer. Controllers, Views are nicely tucked together. Models and Helpers are visible at top level makes it easy for you instead of grilling down the folders to get them.
Another neat feature is Console (they call it Project Commander), not only it shows output you could directly type and run all rails commands here (like rake tasks or installing plugins etc.)
Finally there is “Refactoring support”. For example, if you choose to rename an action, it will figure out all the files that action is referred and changes for you.
Go check it out at http://www.codegear.com/products/3rdrail. At least try for 3o days and see if you like it.
Performance Comparison For Rails and Merb
September 2, 2007
Merb is another MVC framework written in Ruby by Ezra Zygmuntowicz. Phil Misiowiec did some peformance comparsion for Rails and Merb when deploying with Mongrel, Swiftify and Nginx. You could look at full article at http://www.webficient.com/2007/08/testing-various-configurations-of-rails.html
For making it visually interesting, I created a simple Flex Chart based on those results. I kind of interpolated the same data in 2 different perspectives:
Chart 1 : Comparing Various Deployments for Rail & Merb
Chart 2 : Comparing Rails & Merb for Various Deployments
You could clearly see that Merb perfomed better than Rails but it is more evident when used with Evented Mongrel and less with simple Mongrel deployment. Also it showing storing sessions in MemCache is better than ActiveRecord store.
**** Note that I am not responsible for these results and full credit should go to Phil Misiowiec and I just try to represent the data visually here (while trying to play with Flex Charting) ******