Visual Studio Expand and Collapse issue on Ashx Generic Handler

Hi, when working in Ashx.. By “Default” you are unable to collapse & Expand your code. It will make you have to see a long-long-long code (sometime_ :P). Here is the trick:

1. Go to  Tools >> Options >> Text Editor >> File Extension. (In your visual studio yaa).

2. Add Extension = ashx. And map the extensionless file to the editor type you want.. For me the code i use on ashx is Visual basic. When you done, just click Ok, and re-open your ashx file.

3. Now you see the Collaps & Expand already available, but you may face the issue like the image below. Character bla bla bla.. Don’t worry, your code still work. To make your heart calm and not see the error, just put /// before <%WebHandler Language=”VB”……

4. Tadaaa… Its done.. now go back to work..

Kongsikan Artikel Ini

Author Description

Seorang pengaturcara perisian komputer. Peminat buku-buku bacaan alternatif dan puisi. Mempunyai minat yang mendalam dalam dunia pelaburan saham. Membangunkan blog khas untuk Rekod Kajian Saham yang telah dilakukan secara peribadi iaitu - www.pergh.biz -

Comments are closed.