Right, I have a problem.
I am currently trying to develop a flight tracking system in visual basic express for my virtual airline (jetengland.com).
I have run into a problem which has stopped development.
Is there a vbexpress package for the FSUIPC module?
I have tried converting the VB6 package into visual basic express code (using vbe built in tools) but to no avail.
What I'm basically trying to do is get the longitude and latitude, altitude, groundspeed, airspeed & remaining NM from FSUIPC (if they are all possible).
Here is what i have so far:
Form1.vbs:
Public Class jet_england_main_form
Private Sub CloseToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CloseToolStripMenuItem.Click
Close()
End Sub
Dim hdg As Offset(Of UInteger) = New FSUIPC.Offset(Of UInteger)(&H580)
Dim magvar As Offset(Of Short) = New FSUIPC.Offset(Of Short)(&H2A0)
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
FSUIPCConnection.Process()
Dim hdgTrue As Double = hdg.Value * 360.0 / (65536.0 * 65536.0)
Dim hdgMag As Double = hdgTrue - (magvar.Value * 360.0 / 65536.0)
If hdgMag < 0 Then
hdgMag += 360
ElseIf hdgMag > 360 Then
hdgMag -= 360
End If
Dim SendLongLat As New System.Net.WebClient
Dim SendLongLatR As New System.IO.StreamReader( _
SendLongLat.OpenRead("http://www.application.jetengland.com/send_update.php?longitude="))
Dim Contents As String = SendLongLatR.ReadToEnd()
End Sub
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
OpenFSUIPC()
FSUIPCConnection.Process()
Me.txtHeadingAtStartup.Text = compass.Value.ToString("F2")
ToolStripStatusLabel1.Text = "Error connecting to the application server!"
Dim ToolStatusStripLabelInfo As New System.Net.WebClient
Dim file As New System.IO.StreamReader( _
ToolStatusStripLabelInfo.OpenRead("http://www.application.jetengland.com/get_status.php"))
Dim Contents As String = file.ReadToEnd()
file.Close()
ToolStripStatusLabel1.Text = Contents
End Sub
Private Sub MToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MToolStripMenuItem.Click
MsgBox("An error occured: jEE001XXC", MsgBoxStyle.Critical, "Error!")
End Sub
Private Sub FileAFlightPirepToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles FileAFlightPirepToolStripMenuItem.Click
MsgBox("Why would you want to do this if the program logs everything for you! Don't worry, we get all your stalls aswell, leave it all to us :]", MsgBoxStyle.Information, "Sorry!")
End Sub
Private Sub LoginToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles LoginToolStripMenuItem.Click
Login_Box.Show()
End Sub
Private Sub ForgotPasswordToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ForgotPasswordToolStripMenuItem.Click
ForgotPassword.show()
End Sub
Private Sub ServerStatusToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ServerStatusToolStripMenuItem.Click
ServerStatus.Show()
End Sub
Private Sub AboutToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles AboutToolStripMenuItem.Click
AbowtBoksWon.Show()
End Sub
Private Sub ToolStripStatusLabel1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ToolStripStatusLabel1.Click
End Sub
Private Sub FileAFlightPlanToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles FileAFlightPlanToolStripMenuItem.Click
End Sub
End Class
The errors that I am getting are:
Thanks in advance,
Dominic Lipscombe.