Reputation: 148534
I'm dealing with an ASPX file
I want to comment a css line. ( ctrl k c)
however it doesn't work in CSS. only on html
How can I fix that ?
Upvotes: 2
Views: 90
Reputation: 7349
There is no default method for commenting css lines in aspx page. So it just add the asp comments in lines.
But you can record your own macro to perform the action. Refer to this link :
Upvotes: 1
Reputation: 5998
I think Visual Studio only looks at the file extension, not the specific context. Since this is inline styles in a ASPX document, it will simply do HTML (or the ASPX equivalent) comments. It would probably also fail if you used inline Javascript.
If you use a stylesheet with the correct .css extension, it should work as expected and do either single line comments (// ...
) or block comments (/* ... */
). I believe VS do the latter, but it's been a while since I used it.
(PS: Bonus points for creating an animated gif illustrating the problem).
Upvotes: 1