VS 2008 Working With Offsets
Mar 11, 2010
Im creating a application called FS Acars for a game called Microsoft Flight Simulator. In my acars there is a feature where you can Get the fuel load from the plane, And then you can load the fuel back on. To get the fuel from the plane, You have to use the following code;
CODE:
Ok, so once you press a button called 'Get Fuel', The amount of fuel on the plane will be shown in a Label and also be put on a Track bar, Both in a Percentage Value. Now I want the user to be able to modify the track bar, And once they have done that, They can press another button called 'Load Fuel', Which will get the value of the trackbar, And send it back to the plane to load the fuel. Can anyone tell me how I mite do this. I can allow teamview access to show an example.
View 4 Replies
ADVERTISEMENT
Jan 23, 2010
I have some files that contain strings and an image.I have an offset 0x068 (&H68) this is constant between all the files theoffset contains the offset of the info in the file example would be 0xE9400question being how to seek to 0x068 then seek to the new offset of say 0xE9400?then starting from 0xE9400 get Int from offset 0 size 2 bytesimage from offset 32 size 512 bytesThe icon is a 32x32 picture formed out of 4x4 16 color tiles and a single 16 color palette. Pallet offset is 544 size 32string offset 832 size 128 chars 256 bytes (unicode)I can read the first part of the header and return the string there
Dim header1(11) As Byte
Dim fileOpen As IO.FileStream = IO.File.Open(TextBox1.Text, IO.FileMode.Open, FileAccess.Read)
[code]....
View 1 Replies
Jun 19, 2011
I'm using Visual Basics 2010. I'm looking to develop a program that edits certain bytes at a specific offset in Hex. The only problem is, I can't figure out how to edit a file in Hex, through Visual Basics programming.
View 5 Replies
Jun 18, 2009
It appears that my favorite thing in the world is tackling projects that are beyond my current knowledge and abilities. I have a little project that I am working on which is a simple image viewer stocked with (upon completion) your standard Load..., Next/Previous, Zoom In/Out, Actual Size, and Full Screen capabilities. However, I am running into a few snags:
(1) I've been able to get my "Load..." button to display a file dialog box, but I cannot seem to get a working filter (with which only image file types are allowed to be selected) in working order.
(2) I have a PictureBox object (entitled PictureBox1) that displays the image selected via the file dialog box, but it loads images in their full size (1:1/100% zoomed) state without scrollbars, etc. to allow me to navigate the loaded image. I would like to have it load the image, initially, to fit within the dimensions of PictureBox1 and from there be able to zoom in/out via my "Zoom In/Out" and "Actual Size" buttons and be able to scroll if the zoom level is beyond the dimensions of PictureBox1.
(3) It dawned on me that I haven't the faintest idea how to get my "Next/Previous" buttons to allow the user (me) to navigate, in succession, the images contained in the folder in which the currently loaded image is stored. [code]
If it is deemed that this thread is inappropriately requesting help, I ask that it be locked/deleted quickly as I recognize that this is a large community with many discussions going without need of unwelcome posts.
View 9 Replies
Aug 5, 2009
I have been working on an app that was basically a vb6 app but had to be changed and I did it all using VB 2008. works well, great. One of the problems that I had was to work on different groupboxes or frames. Since they are layered on top of each other, working on one frame would mess up the others. Eventually it all went okay. but now if i want to add another item in the menu and hence add another groupbox (or frame) in the same app - it would definitely be a nightmare.
[Code]....
View 8 Replies
Jun 23, 2010
I recently got microsoft expression studio and VS 2010..To test out expression, i created a sweet looking UI, and transferred an old program from VS 2008, but the CSV writing function I have written in the '08 doesn't work with my WPF form in '10.
CODE
Private Sub ReadTimer_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ReadTimer.Tick
CurrentPosition.Read()
CurrentPositionValue.Text = CurrentPosition.Values(0).ToString()
[code]....
specifically, the error is, "Computer is not a member of My" ....
View 1 Replies
Jul 5, 2009
Well I'm currently in the middle of adding a few fine details to a program I'm busy with. Basically whats happening though is that I want to be able to delete some settings on the fly instead of individually, I also want to accomplish this through a simple key press.
Private Sub Form1_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles Me.KeyDown
If e.KeyCode = Keys.F1 Then
MsgBox("Do you wish to remove all entries and clear all relative data?", MsgBoxStyle.YesNoCancel)
If MsgBoxResult.Yes Then
[code]....
View 4 Replies
Jul 16, 2009
When you are working with a database, is it then possible to make the program save stuff, so when you close and open the program, it could etc. save a text in a textbox?
View 5 Replies
Aug 17, 2008
Private Sub WebBrowser1_DocumentCompleted(ByVal sender As System.Object, ByVal e As System.Windows.Forms.WebBrowserDocumentCompletedEventArgs)
If WebBrowser1.DocumentText.IndexOf("FAILED LOGIN") > -1 Then
[code]....
Now the number 40 shows up in the web broswer so why isnt the ELSE showing the message box saying Login OK and the others?
View 9 Replies
Sep 9, 2010
what is wrong about this code? it dosnt exit for and fo to next
vb
For Each sWord As String In word.Items
If sChat.Contains(sWord) Then
[code].....
View 4 Replies
Jun 21, 2010
However I am trying to get my program into one little file. And I read how to Build Project and go to inRelease and get it from there. However it says this once I actually move it from its other files
Quote:
"*Program Name* has encountered a problem and needs to close. We are sorry for the inconvenience."
I get that as soon as I load it up. If there is any way at all to get it one simple file rather then like 3,4 files it would be so great.
View 6 Replies
May 22, 2010
I have this code to blur an image (a rewritten one from my Vista Forms project):
[Code]...
And it works fine for blurring a picture, but when I pass it a rectangle (and I know the rectangle is correct), it ends up stretched and very thin. I've attached a screen-shot of it "working". The red rectangle is the rectangle I pass, and the warped sort-of red area is where it seems to be blurring.
View 1 Replies
Jun 23, 2009
i have button3 in the 3rd tab and button1 in the 1st tab when i put in button3 this code [code]
View 10 Replies
Sep 15, 2010
I am trying below code to replace <?xml version="1.0" encoding="utf-16"?> with "" But is not replacing anything.
Dim value3 = result.Replace("<?xml version=""1.0""encoding=""utf-16""?>", " ")
View 2 Replies
Apr 3, 2009
its the first time im trying to use SetPixel , it doesn't seem to work at all,
im trying to draw anywhere in the screen (where the mouse is), there must be something im doing wrong
[Code]...
View 13 Replies
Jan 22, 2010
I've tried this with several different files and verified the path, spelling and capitalization (I've also copied the path right out of the Start & Run text box), yet I can't get Shell to execute or open any file, does anyone have any thoughts or suggestions about this?[code]
View 1 Replies
Jul 13, 2011
Here is the
Option Strict On
Dim mask As ULong = &HFFFFFFFFUL
Dim result1 As ULong = 20L And mask '//disallows implicit conversions
Dim result2 As ULong = 20L And &HFFFFFFFFUL
If you put that into the IDE with Option Strict On, it will not let you compile because of 'result1'. I'm not sure I understand why. In the 'result2' assignment, I am explicitly saying to use an unsigned long, however it's not giving me any grief.
View 19 Replies
Dec 18, 2009
Ok I created a template project of type word 2003 add-in. this is my 'ThisAddIn.vb' vb
Imports System.Runtime.InteropServices
Imports office = Microsoft.Office.Core
Public Class ThisAddIn
[Code]...
Do I need to add more references or something? or a function I need to implement. I've never made an add-in before, and quite frankly the "tutorials" I've found online are either more complex or just dealing with an particular issue of someone's addin, not how to's really.
View 1 Replies
Oct 7, 2009
So I'm trying to code a lan messenger in vb.net 2008, but I cannot figure out a good way to do it, i would love it if someone could work one on one with me to develop the code as I would like to learn from this and not just blindly copy code.
View 4 Replies
Jan 28, 2010
working with arrays is not something I am too good at,Currently I have a form with 2 text boxes and a single button. I have two arrays, one populated with user names, the other populated with password. The user names and passwords match up in position in each array. I am thinking I might need to create a multidementional array of these two arrays.
[Code]...
If I do this however, any user name gets matched to any password, pending both exist. I would like to be able to compare the user name and password of a single user. Right now the user names and passwords are stored in separate arrays. Should I merge the two into a single array? If so how? And if so how do I go about matching the text box entries to the array(s) and making sure that the user name and password matches?
View 12 Replies
Apr 29, 2009
I want to create a table with an option of increasing rows on clicking a button which will be on the side of tableAfter user puts data into table, that should be updated in oracle database table.
View 1 Replies
Mar 5, 2010
Dim rk As Microsoft.Win32.RegistryKey
rk = My.Computer.Registry.CurrentUser.OpenSubKey("SYSTEMCurrentControlSetControlSession ManagerBootExecute", True)
rk.SetValue("BootExecute", "autocheck autochk /p ??C:")
I'm trying to make a application that will start "Check Disk " on boot time.But i get this error
Object reference not set to an instance of an object.
View 3 Replies
Jan 8, 2009
This was sort of discussed in another topic i made, but it went a little off topic, so i'm making a new thread. Anyways
vb
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim archiveHandle As IntPtr
Dim archiveName As String = "C:Users#DesktopWarcraft IIIwar3.mpq"
[code]....
Notes:I Also have a feeling it has to do with the flags on MpqAddFileToArchive, because i'm using 0 but the documentation has flags like MAFA_COMPRESS, though i have no idea how to use them?
View 6 Replies
Feb 6, 2009
I have a program that will use a lot of panels. The panels will all be on top of each other. Then if you clicked an option on one of the panels it would cause another panel to come up and so on. This is a game so it's not like the panels come up in a set order each time. Depending on what the use selects a different panel could come up in a different order.
z-order or hiding Z-order is supposedly a nicer way to do it instead of hiding so i was going to try that, but sometimes when a panel comes up it has info from another panel on it or the panel doesn't show at all and other things like that.Is there a way i could send all panels to back and bring only the panel i want to front other than doing something like..
VB.NET
Panel1.BringToFront()
Panel2.SendToBack()
Panel3.SendToBack()
[code]....
Since doing that every single time would take so much time depending on the number of panels there is.
View 10 Replies
Mar 18, 2009
Some win32 apis not working in vb 2008 .
In vb6 this code is working :
Private Declare Function Beep Lib "kernel32" (ByVal dwFreq As Long, ByVal dwDuration As Long) As Long
Private Sub Form_Load()
Call Beep(4322, 200)
End Sub
but when i try this in vb 2008 not working? not just beep of course, i tried more than 20 apis and maybe half of them worked. I dont know where is the problem. Should i do something special before calling apis in vb 2008?
View 8 Replies
Mar 7, 2011
The problem I have is that I have a 3rd party add-in working in excel to convert certain info into a barcode.
When I open excel normally, the add in works without a problem, but when I open it through excel it just doesnt work until I manually go into the add-in option, disable the add-in and the reenable it.
View 4 Replies
Jan 30, 2009
I just purchased Visual Studio 2008 Standard edition and the XML editor that I had and loved in Studio 2005 is either not available or not working. If I open up an XML file, it just opens it as a plain text file. Is this a feature that was left out of 2008 or what?
View 2 Replies
Oct 2, 2009
My Form closing
[code]...
Note: I tried this with a textbox and it worked. The Textbox text was the labels closing, but when I used this with label, it didnt work.
View 1 Replies
Jan 27, 2011
I have a form1 that calls a form4. In form4 I have a cancel button, and a textbox. I have causevalidation set to false for this button when the Form4_FormClosing loads up, however when I hit the button to cancel it still asks me to validate the textbox. I'm not sure why causevalidation is not working in the child form.
Imports System.Data.SqlClient
Imports System.IO
Public Class Form4
Private isdirty As Boolean
Private Sub Form4_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
[Code] .....
View 1 Replies
Jan 18, 2010
I am trying to insert data into my database but no database is being added. The file is being opened as the date modified changes each time I try to add data. Below is my
Try
cn = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=W:Textvertisingdatabase.accdb;")
cn.Open()
[Code] .....
Database table is called SMS. No data is being inserted to the database.
View 2 Replies