Pete Dowson Posted March 12, 2012 Report Posted March 12, 2012 How we know what is the code to catch te funcion i mean if i want the Heading off the aircraft what will be the code? for the Altitude is DimGndAltAsInteger and for the heading? i mean there is any list whith all the aircraft funcions codes? Sorry, I'm rather confused by your terms. By "code" what do you mean? Is it a list of FS variables and the FSUIPC offsets you need? If so, the complete lists are provided in documents included in the FSUIPC SDK. Regards Pete
Joaogl Posted April 4, 2012 Report Posted April 4, 2012 Hello, When i add the FSUIPC4.DLL to the References it give an error. "A reference to 'C:\Program Files (x86)\Microsoft Games\Microsoft Filght Simulator X\Modules\FSUIPC4.DLL' could not be added. Please make sure that the file is accessible, and that is a valid assembly or COM component" How can i resolve this problem?
Pete Dowson Posted April 4, 2012 Report Posted April 4, 2012 When i add the FSUIPC4.DLL to the References it give an error. To what "references"? FSUIPC4.DLL is an FS module. It can't be run separately or attached to by other programs other than by the defined IPC ("inter-process-comunications") interface. Please see the FSUIPC SDK. "A reference to 'C:\Program Files (x86)\Microsoft Games\Microsoft Filght Simulator X\Modules\FSUIPC4.DLL' could not be added. Please make sure that the file is accessible, and that is a valid assembly or COM component" It is not an "assembly" or "COM compoanent" and you cannot link to it directly. Please refer to the SDK. You seem to be severely misunderstanding something. Pete
Pete Dowson Posted April 4, 2012 Report Posted April 4, 2012 haaaa, ok, so where can i find that sdk? Same place as you find FSUIPC and all my other programs. either on the Schiratti site, or in the Download Links subforum here. How did you find this forum? Regards Pete
Joaogl Posted April 4, 2012 Report Posted April 4, 2012 on the google searching for how connect fsuipc to vb program.
Joaogl Posted April 4, 2012 Report Posted April 4, 2012 ok ive already found it so now i just need to execute the FSInterrogate2std correct?
Joaogl Posted April 4, 2012 Report Posted April 4, 2012 ok im reading the FSI2 Manual, FSUIPC for Programmers and FSUIPC4 Offsets status... Just a question how can i add this on the Visual Basic 2010?
Pete Dowson Posted April 4, 2012 Report Posted April 4, 2012 on the google searching for how connect fsuipc to vb program. Why not check the SDK first? There are examples. The Downloads of this forum are empty... What are you on about? The Download Links subforum, which is where I pointed you to,, has several threads full of non-empty download links! Please do read what is written! there is no sdk for fsx? Why should there be a separate SDK for FSX? FSUIPC has been going since FS95, with compatibility all the way through. Why would I produce identical SDKs for each version of FS? It wouldn't make any sense! ok ive already found it so now i just need to execute the FSInterrogate2std correct? Why? That's just a utility program provided by Pelle Liljendal to assist you in understanding how FSUIPC offsets behave. It is written in Delphi and is an example of an FSUIPC-interfacing application. ok im reading the FSI2 Manual, FSUIPC for Programmers and FSUIPC4 Offsets status...Just a question how can i add this on the Visual Basic 2010? Sorry, you seem to be going off half-cocked in all directions. Sit down, review all the files, read them all, look at the VB example. Start again tomorrow. Pete
Paul Henty Posted April 4, 2012 Report Posted April 4, 2012 Joaogl, If you're using VB2010 I recommend you use my FSUIPCClient.DLL for .NET languages. See the thread called "FSUIPC Client DLL for .NET" in the downloads sub-forum. Download the ZIP and have a look at the example app written in VB.NET. Please also refer to the UserGuide. Paul
Joaogl Posted April 5, 2012 Report Posted April 5, 2012 Hi guys, Just a question, im new here as u can see soo were can i find that downloads sub-forum. Why not check the SDK first? There are examples. only now i know that there is an SDK for FSUIPC so..... Why should there be a separate SDK for FSX? FSUIPC has been going since FS95, with compatibility all the way through. Why would I produce identical SDKs for each version of FS? It wouldn't make any sense! I just asked becouse i thought it only work on FS2004 so.... now i know it works in all versions. Why? That's just a utility program provided by Pelle Liljendal to assist you in understanding how FSUIPC offsets behave. It is written in Delphi and is an example of an FSUIPC-interfacing application. ok i thought i had to go there to extract some files to the VB so... ok thanks Sorry, you seem to be going off half-cocked in all directions. Sit down, review all the files, read them all, look at the VB example. Start again tomorrow. Ok its a new day im working again :D Im not new in the VB and im a WebDesigner, i im trying to make and ACARS but firts i need do know how to work with FSUIPC SDK after that i need to send all the information to the website and after all that i will do the other things like style and etc. so im trying to do a new thing so.... Thanks for all
Pete Dowson Posted April 5, 2012 Report Posted April 5, 2012 Just a question, im new here as u can see soo were can i find that downloads sub-forum. I don't understand how you can miss the SubForums? They are the first thing you see when you come to the forum, right at the top! There are subforums called Announcements, FAQ, Download Links and User Contributions. Being new here I would have thought they were the very first things you saw -- how do you not see them? They are there explicitly to attract the attention of new visitors so they can look for solutions to their problems before adding new messages to the Support Forum. itself! Regards Pete
Joaogl Posted April 5, 2012 Report Posted April 5, 2012 Ive done the Download of the FSUIPCDotNetClient2.0.zip open the VB Exemple add the reference but it give me 2 warnings.... Warning 1 Could not find type 'FSUIPCClientExample_VB.DoubleBufferPanel'. Please make sure that the assembly that contains this type is referenced. If this type is a part of your development project, make sure that the project has been successfully built using settings for your current platform or Any CPU. 0 0 Warning 2 The variable 'pnlAIRadar' is either undeclared or was never assigned. C:\Users\Joao Lourenco\Desktop\uuu\FSUIPCClientExample_VB\Form1.Designer.vb 520 0 why this hapen?
Paul Henty Posted April 5, 2012 Report Posted April 5, 2012 Ive done the Download of the FSUIPCDotNetClient2.0.zip open the VB Exemple add the reference but it give me 2 warnings.... Warning 1 Could not find type 'FSUIPCClientExample_VB.DoubleBufferPanel'. Please make sure that the assembly that contains this type is referenced. If this type is a part of your development project, make sure that the project has been successfully built using settings for your current platform or Any CPU. 0 0 Warning 2 The variable 'pnlAIRadar' is either undeclared or was never assigned. C:\Users\Joao Lourenco\Desktop\uuu\FSUIPCClientExample_VB\Form1.Designer.vb 520 0 why this hapen? Hi, Have you tried to build the project or have you just gone into the form designer. Building it first might help. If it won't build, let me know if you can see the DoubleBufferPanel class. If should be at the bottom of the Form1.vb code file. It looks like this: Public Class DoubleBufferPanel Inherits Panel Public Sub New() ' Set the value of the double-buffering style bits to true. Me.SetStyle(ControlStyles.DoubleBuffer Or ControlStyles.UserPaint Or ControlStyles.AllPaintingInWmPaint, True) Me.UpdateStyles() End SubEnd Class[/CODE]Paul
Joaogl Posted April 5, 2012 Report Posted April 5, 2012 First no i cant find it. Second, i was reading the codes and the files and im trying im test program. For now im just creating a lot of funcions just to try and to understand... For now i have a button to connect other to disconnect and works. I create a Label to say my Speed but it says like 50.5 how can i remove that .5 ? i just want the 50...
Paul Henty Posted April 5, 2012 Report Posted April 5, 2012 HI Joaogl, I've reproduced the error you are getting on the form designer. You can fix it by building or running the project, then close the form designer and reopen it. I create a Label to say my Speed but it says like 50.5 how can i remove that .5 ? i just want the 50... This isn't really to do with FSUIPC or my DLL. It's just VB / .NET programming. It's not really possible to give VB lessons in this forum. You can find this kind of thing elsewhere on the internet or in books. But to answer your question just convert to a string using a fixed point format with 0 decimal places: Dim mySpeed as Double = 50.5myLabel.Text = mySpeed.ToString("F0")[/CODE]This will probably round the number for you. If you don't want rounding then use the Floor function.[CODE]Dim mySpeed as Double = 50.5myLabel.Text = Math.Floor(mySpeed).ToString()[/CODE]Paul
Joaogl Posted April 5, 2012 Report Posted April 5, 2012 In this code: Dim airSpeed As Offset(Of Integer) = New FSUIPC.Offset(Of Integer)(&H2BC)On Timer: Dim airpeedKnots As Double = (airSpeed.Value / 128D) Me.Label3.Text = airpeedKnots.ToString("f1")[/CODE]The number &H2BC on the Dim is what we want to know correct?if is &H2BC is speed if is &H3118 is com frequency 2...Correct?If its true there is any list with all that codes and funcions?if its not true what tells to the FSUIPC what we want to know?
Paul Henty Posted April 5, 2012 Report Posted April 5, 2012 The number &H2BC on the Dim is what we want to know correct? if is &H2BC is speed if is &H3118 is com frequency 2... Correct? If its true there is any list with all that codes and funcions? Yes, that's all correct. A list of all the offsets (code numbers) can be found in the FSUIPC SDK. For FSUIPC4 the document is called 'FSUIPC4 Offsets Status.pdf'. This document tells you three main things about each offset: 1. The offset code (address) e.g. 02BC 2. The Size of the offfset in bytes and the type of data stored in the offset - This tells you what data type to Dim your offset as. Example: 4 byte integer = (As Integer), 2 Byte = (As Short). 3. How the value is stored so you can convert it to real-world values. Example: (Indicated Air Speed, as knots * 128). This means to get back to knots you need to divide by 128. - (airSpeed.Value / 128D) There is a useful table on page 7 of my UserGuide.pdf (see the Docs folder in the Zip) which tells you what .NET types to use for each size/type of FSUIPC offset. Paul
Joaogl Posted April 5, 2012 Report Posted April 5, 2012 yes im reading a lot of files i really need to create my acars but know i think my bigggg problem is connect to my WebSite DataBase so... i will continue treining this but more the DataBase...
Joaogl Posted April 5, 2012 Report Posted April 5, 2012 I think i will create a new database add all this offsets with a search.. becouse by the other way i will take hours searching for some code...
Joaogl Posted April 5, 2012 Report Posted April 5, 2012 Please what is rong here to a Login Imports MySql.Data.MySqlClientPublic Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim conn As MySqlConnection conn = New MySqlConnection conn.ConnectionString = "Server=sql9.000webhost.com;User Id=a4060939_teste;Password=jafo2te;Database=a4060939_teste" Try conn.Open() Catch ex As Exception MsgBox(ex.Message) End Try Dim myadapter As New MySqlDataAdapter Dim sqlquery = "SELECT * FROM account WHERE fname='" & TextBox1.Text & "' AND lname='" & TextBox2.Text & "'" Dim mycommand As New MySqlCommand mycommand.Connection = conn mycommand.CommandText = sqlquery myadapter.SelectCommand = mycommand Dim mydata As MySqlDataReader mydata = mycommand.ExecuteReader If mydata.HasRows = 0 Then MsgBox("Bad") Else MsgBox("Good") Me.Hide() End If End SubEnd Class[/CODE]
Paul Henty Posted April 6, 2012 Report Posted April 6, 2012 Joaogl, I can't help with this, sorry; it has nothing to do with my DLL or FSUIPC. You'll need to find a more suitable forum to ask for support with VB.NET or MySQL database use. Paul
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now