Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

Learning Visual Basic Problem

  • 30-01-2007 01:48AM
    #1
    Registered Users, Registered Users 2 Posts: 1,559 ✭✭✭


    Im trying to teach myself visual basic via online tutorials.
    I downloaded visual basic 2005 express edition.
    Ive only started the tutorial and Im already having problems.
    The tutorial is aimed at visual basic 6 and I thought it would be the same.

    I tried this code

    Public Class Form1

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
    Form1.Show()
    Print("Welcome to the Visual Basic Tutorial")
    End Sub
    End Class


    It comes up with this error

    'WindowsApplication2.Form1' cannot refer to itself through its default instance; use 'Me' instead.

    Form1.Show() is the problem apparently its use has been changed.
    Anyone now how you use Show() in the new visual C++ edition?


Comments

  • Closed Accounts Posts: 17,208 ✭✭✭✭aidan_walsh


    Visual Basic 6 is not the same thing as Visual Basic.NET. VB.NET is a pretty radical departure from VB of old in many ways.

    Try some proper .NET-based tutorials, like these


  • Registered Users, Registered Users 2 Posts: 1,559 ✭✭✭quinnd6


    Cool thanks


Advertisement