I have some code that I wrote for a simple Crypter in VB.ET 2010 Express Edition. I tried to build it, and I get two Errors that I don’t know how to fix.
Here is the Code
Public Class MainWindow 'Class Name
Dim infectedfile, stub As String
Private Property Cryptfile As String
Private Sub MainWindow_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
End Sub
The Error I get is “Event ‘Load’ cannot be found”
And here is the second line of code:
Dim btSalt() As Byte = New Byte() (1, 2, 3, 4, 5, 6, 7, 8)
The Error I get is “Bounds can be specified only for the Top-Level array when initializing an array of arrays.”
All help is appreciated! 🙂
To solve your 2nd error, you should declare your array like this:
As for the first error, we’ll need more context.
Cheers
EDIT:
Here’s how to override the OnLoad method, which is prefered over subscribing to own event, ie form events: