Visual Studio
Welcome to the Visual Studio UserVoice site. Let us know what you would like to see in future versions of the Visual Studio suite of products. This site is for suggestions and ideas. If you need to file a bug, visit the Visual Studio Connect site: http://connect.microsoft.com/visualstudio.
ASP.NET Runtime/Web Tooling suggestions have moved! All your ideas, including your votes, have been transferred and are searchable in the ASP.Net Uservoice forum. Please submit any new ASP.NET Runtime/Web Tooling suggestions, or vote on existing suggestions by going to http://aspnet.uservoice.com.
We look forward to hearing from you!
Thanks – Deon Herbert
Visual Studio Team
-
Add new initialization way of memvars
Add new initialization way of memvars:
x,y = 0
x,y,z = 1,2,3
a,b,c = MyFunction()Function MyFunction() as byte, byte, int
return 1,2,36 votes -
Duck typing of interfaces
One of the features that was dropped from VB9 was dynamic interfaces:
http://download.microsoft.com/download/5/8/4/5841bc1a-e864-4423-bb75-d4f3c18c0af5/visual%20basic%209.0%20overview.docAny chance of bringing this back? I know it can be done at runtime:
http://www.codeproject.com/Articles/16074/DuckTyping-Runtime-Dynamic-Interface-ImplementatioBut that looses the compile time type checking, which is the great advantage of dynamic interfaces -- it gives you the best of both worlds, you can define a set of behavior for an existing class without having to have control over that class, based upon it's public interface, with no chance of it failing because of a missing property or method (if the class doesn't meet the requirements for the interface,…
6 votes -
Using object comparing in the Select Case statement
Select Object myobj
....Case obj1, obj2, obj3, obj4....Case frm1
End Select
6 votes -
Add to Visual Basic the ability to declare a new strong type in terms of another type
Many other languages have 'strong' typing. Java, C#, and VB have strong typing regarding classes, but not for the primitive numeric types. It can be a great aid to making large-scale industrial and commercial software. For example, if one could declare two different types Apples and Oranges:
Type Apples Is New Integer
Type Oranges Is New Integer
...
Dim A As Apples = 3
Dim B As Oranges = 4then accidentally mixing arithmetic or assignment between these types would be prevented by the compiler, e.g. the assignment:
A = B
would be rejected by the compiler (and Intellisense) as…
6 votes -
Allow the subject of a With block to be referenced in the block using a new keyword WithRef
Primarily, this is a convenience mechanism to avoid having to declare a variable in certain cases.
Proposed:
Function ReturnNewCheese(cheeseType as CheeseEnum) as Cheese
With New Cheese
.CheeseType = cheeseType 'property
.Curdle 'method
Helpers.DoSomethingWithCheese(WithRef)
Return WithRef
End With
Exit FunctionNow:
Function ReturnNewCheese(cheeseType as CheeseEnum) as Cheese
Dim x as New Cheese
With x
.CheeseType = cheeseType
.Curdle
Helpers.DoSomethingWithCheese(x) 'requires explicit variable declaration
End With
Return x 'requires explicit variable declaration
Exit Function6 votes -
Implement support for binary, octal and hex literals
I know VB supports hex literals but these need to be improved so instead of using the &h prefix, you could use a suffix:
Dim hexValue = 1F7hThe same way you could then implement both binary and octal literals:
Dim binValue = 01100011b
Dim octValue = 722o5 votesHey Xavier,
Good suggestion. As you mentioned VB already has hexadecimal and octal literals but no binary literals. It’s certainly a small feature we’re considering for a future release.
As I see it, VB is a language which strives to be both powerful for advanced developers while also approachable and learnable by new programmers. One of the early concepts we need to learn as new programmers is how binary numbers work and it’s unfortunate that the language today forces you to visualize that and do the translation in your head mentally. I’d certainly like to make that first-class (after all, who uses Octal anymore?).
Regarding the proposed syntax change the benefit seems minimal going from &HFF to FFH so we’re unlikely to make that change but it is worth considering relaxing the IDE’s pretty-lister forcing you to use upper-case, at least then you could type &hFF01 and &b10011101. I…
-
Make references visible in VB projects in Solution Explorer (like C#)
In C#, references are visible in Solution Explorer/Navigator. In VB you have to hide invisibles to achieve this.
5 votes -
Add some Tutorial Projects
Add some tutorial projects for those poeple who are new to vb.net/2011 get to know what it is and how it works n stuff encouraging them to get into programming and explore new ideas also making the process user friendly. The easiest way to do this by using sample projects like "HelloWorld" and implementing into vb as a tutorial project with basic fucktion like If Fucntions , Select Case and loop functions etc... basically Add more of some practical related tutorials :)
5 votes -
4 votes
-
enable line comments in VB after the line continuation char (_)
Just a very simple thing:
I had an attribute and a field written on two lines like this:
<DebuggerBrowsable(DebuggerBrowsableState.Never)> _
Private _SomeField As Stringand wanted to add a line comment after the '_':
...State.Never)> _ 'My reason why
I now get the following error: "Line continuation character '_' must be preceded by at least one white space and must be the last character on the line."
My request now is to change the rule "...must be the last character on the line" to "...must be the last non-white-space character on that part of the line that does not belong…
4 votesHey Chris,
Excellent suggestion! When we introduced implicit line-continuation in VB2010 it was a very painful restriction that we had to leave in due to technical and schedule constrains that comments weren’t allowed after them. Happily, thanks to the improved parser architecture we use in Roslyn (a future version of VB/C#) we will be able to support it one day. In fact, in the Roslyn compilers comments are already supported after implicit line-continuation so I can write this:
’ Comment herePrivate _SomeField As String
After we got that working it seemed reasonable to lift the restriction on normal, explicit line-continuation as well though we haven’t yet done so.
While we do not currently have plans to address this issue in the next release of Visual Studio, we are reviewing suggestions now for future versions of VB in and beyond the Roslyn time-frame. We have not determined when that will…
-
the most wanted feature in basic.net now (and still) is *comments within multiline statements*
I have to repeat the begging for comments within multiline statements in visual basic... yes, I know you refused to do that for me and numerous others over the last 6-7 years stating that it is "by design"... so what? our continuous and numerous complaints just show that this request has its roots, so do not make excuses of design... *change that design detail* and everything will be ok... mr. hejlsberg on /BUILD/ conference talks about 'paste as c#' and 'paste as vb.net' and you are not able to convince yourself of the need to change that tiny design glitch...…
4 votesHey gjuro,
We’ve considered inline/multiline comments in VB several times. In the past it’s been a very expensive thing to implement because of the way the language parser was designed and the way the IDE integrates with it. The VB and C# code bases are, for historical reasons, very different. Anyway, in Roslyn such a thing isn’t as difficult anymore but we still question the value. In fact “is it worth it” is the real obstacle at this point.
We don’t actually see much use of inline/multiline comments even in C# which makes us even more hesitant to add them to VB.
Now, what we have been able to make work in Roslyn is this:
Dim q = From x In y ’ This is a from clause
Where x < z ’ And this is the where
Select x ’ This select is redundantThat is, comments after implicit…
-
add // for a comment and eat up semicolon at the end of the line
while pasting to VB.NET a sample I managed to develop in C# I understood that most of reediting needed consisted of changing // into ' for starting comments and deleting terminating semicolons
by chaning this two tiny details you would greatly help porting C# to VB.NET code
4 votes -
Bring the "Enable Single Instance Application" for VB.Net (WPF) on Framework 4.0
Add the option of single instance application (program.. IDK) in VB.Net with WCF and .Net 4.0.
We need to make single instance applications while using VB.net, too, not just VB!
Example of program which needs it:C4D-Alpha: A launcher program which enables and launches some features on a specific program (external).
C4D-Alpha saves the settings for next launch on every change.
C4D-Alpha's best use is assigning it to a keyboard shortcut (ie. CTRL ALT SHIFT C) and then when its up (after a quarter of a second) press the corresponding key for the feature you want to launch.Link: http://www.mediafire.com/download.php?lz58m1zqaiidnfy
…
4 votes -
The "Is" keyword let be a real reference in the Select block.
Select Case i
Case 1, 5, 10 To 20
FuncSpec()
Case IIf(Is Mod 2 = 0, Is, Nothing) ' the "Is" keyword is a read-only reference of the "i" variable
FuncEven()
Case IIf(IsPrime(Is), Is, Nothing) ' the "Is" keyword is a read-only reference of the "i" variable
FuncPrime()
Case Else
FuncOther()
End Select'Advantages:
' - branching by any kind of case (not only by equality or range or comparison operator)
' - no need to convert to If block (what is redundant and less readable)4 votes -
Collection initializers for read-only collection properties in VB.NET
I'm very happy that Microsoft is committed to VB.NET have the same features as C#.
One feature I use extensivle in C# is collection initializers. I've just noticed that VB.NET supports these but not for read-only class properties.
I found at http://msdn.microsoft.com/en-us/library/dd293617.aspx that if a collection has a an Add method, it is used to initialize the variable. This should also apply to read-only collection properties.Here is compilable C# code showing the feature working:
using System;
using System.Collections.Generic;namespace ConsoleApplication3
{
class Class1
{
private readonly List<Int32> list = new List<Int32>();public List<Int32> ListProp
{
get
{
return this.list; …4 votes -
Implement a Strictly .net mode for VB.net.
implement a compiler switch that when turned on. vb.net is no longer backwards compatible with vb6.
Option DotNetOnly On
So now you'll get compiler errors if you use any on the vb6 keywords and legacy functions.
A c# like approach to shared methods, only accessible via the class, not an instance.4 votesHey Adam,
Thanks for the suggestion. Could you be more specific on what specific things you’d want disallowed and very specifically why they “don’t make the cut”. I ask because as written this suggestion could mean different things to different people; “VB6 keywords” “VB6 compatibility” isn’t very meaningful objectively. For instance AddressOf, Alias, And, As, Boolean, ByRef, Byte, ByVal, Call, Case, Date, Declare, Dim, Do, Double, Each, Else, ElseIf, End , Exit, False, For,Function, Get, GoTo, If, In, Integer, Is, Let, Lib, Like, Long, Loop, Me, Mod, New,Next, Not, Nothing, Object, On, Option, Optional, Or, Private, Property, Public, ReDim, REM, Resume, Return, Select, Set, Single, Static, Step, Stop, String, Sub, Then, To, True, While, With, and Xor all are just some of the keywords which were in VB6 – I don’t imagine you’re suggesting disallowing all of them. Also it’s not very clear how you delineate what is .…
-
VB-Intellisense should suggest undefined variables from current context after writing "Dim..."
Often, if i write a line of code, i start to write something and think this would be better split in more lines and use a new variable
Basic example:
result = (a + b) * c
while writing the line, i think (a+b) is rather complex in one line, so just use a new temporary variable. But first I complete this line, if I already had defined this variable and write the "Dim" and the assignment afterwards.
so, i write:
result = x * c
and afterwards i go some lines up and start to write
dim x as...
…
3 votes -
control + First Letter short cut Key for Properties (was available in vb6)
Can we have short cut keys for the Properties of an Object, It was even available in VB6, Since from 2003 missing this functionality a lot.
Would be great if we can have this functionality asap
3 votes -
Self-Extending Integration
Hi,
I am a good programmer of VB.Net I found it Very Easy to use. But the thing i want is that programmer should be able to extend language by building new keywords. As In some class If we use IDisposable Then we can use Using statement for that class. So I want that user make new classes and make new keywords for them. Although It is easy to say this but i think its programming will be so hard but VB.Net will be language extending itself. There should be a class for implement or inheriting Keyword and build rules…3 votes -
Make the declaring matching operators (such as =/<>) optional
When defining an operator such as:
Public Shared Operator =(value1 As Binary, value2 As Integer)
Return value1.ToInt32() = value2
End OperatorThe compiler should automatically default the matching "<>" to "Not =" thus avoiding the now mandatory declaration:
Public Shared Operator <>(value1 As Binary, value2 As Integer)
Return Not value1 = value2
End Operator3 votes
- Don't see your idea?