Home

Red squigglies in VB code

I put together a simple vb program to test a function for an SSRS project. I get red squigglies (syntax errors?) even though it compiles and executes fine. Squigglies appear in the Dim pageNames statement.

Sub Main Header1("Point Liability").Dump() End Sub ' Define other methods and classes here Function Header1(pageName as String) as Boolean Dim pageNames as String() = { "Points Liability", "Merch In", "Variable Costs", "Customer Service Fees" } For Each name as String in pageNames If name = pageName then Return True Next Return False End Function

Comments

  • edited May 2014
    Solved it. Although the recent vb compilers (since Visual Studio 2010 I believe) do not require line continuations in cases like this, LINQPad doesn't know that (though I suppose it could find out which VB compiler version is running). If I add the line continuations, the squiggles go away.
Sign In or Register to comment.