Jump to content


Check out our Community Blogs

Register and join over 40,000 other developers!


Recent Status Updates

View All Updates

Photo
- - - - -

Suggestion


This topic has been archived. This means that you cannot reply to this topic.
8 replies to this topic

#1 Tonchi

Tonchi

    Helping the world with programming

  • Expert Member
  • PipPipPipPipPipPipPip
  • 1249 posts

Posted 13 December 2012 - 05:42 AM

Is it possible for someone who is authorized here to implement Format Document from Visual Studio here when you are typing a code, so we are not obligated to do that by ourself? It would be a great implementation.

Microsoft Student Partner, Microsoft Certified Professional


#2 Roger

Roger

    Skadoosh!

  • Administrator
  • 1222 posts

Posted 13 December 2012 - 10:31 AM

Do you mean to format as you're typing? Or formatting pasted code?

New around here? Click here to register and start participating in under a minute?

Or do a quick search and you may find the answer you're looking for.


#3 Tonchi

Tonchi

    Helping the world with programming

  • Expert Member
  • PipPipPipPipPipPipPip
  • 1249 posts

Posted 13 December 2012 - 11:25 AM

I mean pasted code. Because if you are typing when you are on Codecall you can automatically format yourself, but when you are pasting your code on Codecall you loose your nerves (at least me) when you must format that by yourself. Imagine that you have to format some code with 300 lines of code by yourself. If you know what I mean :)

Microsoft Student Partner, Microsoft Certified Professional


#4 Roger

Roger

    Skadoosh!

  • Administrator
  • 1222 posts

Posted 13 December 2012 - 01:26 PM

Can you show me an example? I thought code tags format code already for you.

And you should normally not post 300 lines of code. :)

New around here? Click here to register and start participating in under a minute?

Or do a quick search and you may find the answer you're looking for.


#5 Tonchi

Tonchi

    Helping the world with programming

  • Expert Member
  • PipPipPipPipPipPipPip
  • 1249 posts

Posted 13 December 2012 - 03:12 PM

300 lines of code is just an example :)
I have experienced few times that my code is in mess when I was posting a question with a code.

Microsoft Student Partner, Microsoft Certified Professional


#6 Roger

Roger

    Skadoosh!

  • Administrator
  • 1222 posts

Posted 13 December 2012 - 03:45 PM

Were you pasting formatted code? I've heard that it gets messed up sometimes. Best way is to use the Paste as Plain Text button (the middle clipboard in the editor). Can you give that a try?

New around here? Click here to register and start participating in under a minute?

Or do a quick search and you may find the answer you're looking for.


#7 Tonchi

Tonchi

    Helping the world with programming

  • Expert Member
  • PipPipPipPipPipPipPip
  • 1249 posts

Posted 16 December 2012 - 09:43 AM

See here http://forum.codecal...er/#entry647598 at post #9. I have pasted that code as a Plain Text but it's still the same and ugly code.

Microsoft Student Partner, Microsoft Certified Professional


#8 neil

neil

    CC Addict

  • Senior Member
  • PipPipPipPipPip
  • 373 posts

Posted 16 December 2012 - 10:00 AM

See here http://forum.codecal...er/#entry647598 at post #9. I have pasted that code as a Plain Text but it's still the same and ugly code.

Isn't that an indent problem ?
EDIT:
there are some IDEs which handle indents differently and mess up the code tags formatting.
I get around this by copying the script/code from a text editor. (Not that i ever use IDEs anymore.)
EDIT:
if you're going to share a lot of lines, might as well attach the code instead of pasting it in.

Edited by neil, 16 December 2012 - 10:04 AM.


#9 Roger

Roger

    Skadoosh!

  • Administrator
  • 1222 posts

Posted 16 December 2012 - 08:12 PM

I think neil is right and this is editor dependent. Have you tried the same code using another editor? I've see both good formatting and bad ones. Not sure what's causing the difference.

New around here? Click here to register and start participating in under a minute?

Or do a quick search and you may find the answer you're looking for.





Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download