Friday, 15 April 2011

windows - Variable not declared error in a Maze Game -



windows - Variable not declared error in a Maze Game -

the maze game have developed via tutorial found research doing well. step step have been debugging application windows using vb in visual studio 2012. told tutorial utilize next code:

private sub movetostart() startsoundplayer.play() dim startingpoint = panel1.location startingpoint.offset(10, 10) cursor.position = pointtoscreen(startingpoint) end sub

on line startsound.play() visual basic gives me error message saying: error correction options. click on , tells me:

'startsoundplayer' not declared. may inaccessible due security level.

what do prepare this?

declare:

private startsoundplayer = new system.media.soundplayer("c:\windows\media\chord.wav")

as tutorial says. in same class movetostart method. if still fails, declare startsoundplayer public instead of private.

windows vb.net soundplayer

No comments:

Post a Comment