0

In vb we put comments in codes using single quote in front of comment without close it at the end of comments. Ex : 'This Will be a comments
But something wrong if i don't close it with single quote too. All codes after comments will become like comments until i close it with single quote.

This is a try :

'This is a comments
Dim i as Integer ' declare i as integer type
Dim j as String

For i = 0 to 5 ' This comments too
   Msgbox i 
Next i

It makes me must to close my comments with single quote if i want to post the codes in VB section.

'This is a comments'
Dim i as Integer ' declare i as integer type'
Dim j as String

For i = 0 to 5 ' This comments too'
   Msgbox i 
Next i

Thank You.

3
Contributors
6
Replies
10
Views
5 Years
Discussion Span
Last Post by Dani
0

Testing ...

'This is a comments
Dim i as Integer ' declare i as integer type
Dim j as String

For i = 0 to 5 ' This comments too
   Msgbox i 
Next i

Edited by Dani: Testing something :)

0

Ok ... my apologies.

There is another way of doing code tags without indenting. Code blocks start and end with three tildes in a row, and allow you to force a specific language to be used. Therefore, you can do:

~~~ vb
Here is VB code that I am forcing to be syntax highlighted with VB syntax
~~~~

And that should work.

0

And that should be the action of the Code button, right? Like before code tags and cursor between for pasting, now in line between tildelines:

This will be empty line with cursor

There will be ready new lines ie tags are '\n~~~\n'. I think it would be good change, if somebody want to tabulate let's paint and push tab (even you would be afraid that the tab replace the text from Word experience, not indent like programmers editor)

0

Consider to do soon this change of Code button update as posting in Python forum is a mess with code tags. (you could add forum default syntax after first tildes to get vb syntax in vb forum)

0

Consider to do soon this change of Code button update as posting in Python forum is a mess with code tags.

I'm confused. What's wrong with the Python forum?

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.