Register | Login | |||||
Main
| Memberlist
| Active users
| ACS
| Commons
| Calendar
| Online users Ranks | FAQ | Color Chart | Photo album | IRC Chat |
| |
0 user currently in Programming. | 3 guests |
Acmlm's Board - I2 Archive - Programming - Help with VB | | | |
Add to favorites | "RSS" Feed | Next newer thread | Next older thread |
User | Post | ||
windwaker Ball and Chain Trooper WHY ALL THE MAYONNAISE HATE Level: 61 Posts: 6/1797 EXP: 1860597 For next: 15999 Since: 03-15-04 Since last post: 4 days Last activity: 6 days |
| ||
I am really new to VB and I am really learning to edit bytes right now. Plus I have a question: how do I edit, or say add 1 to each byte in a range or the entire file? | |||
HyperLamer <||bass> and this was the soloution i thought of that was guarinteed to piss off the greatest amount of people Sesshomaru Tamaranian Level: 118 Posts: 39/8210 EXP: 18171887 For next: 211027 Since: 03-15-04 From: Canada, w00t! LOL FAD Since last post: 2 hours Last activity: 2 hours |
| ||
Well it kinda depends. Do you copy the entire file to memory first, or just edit it directly? I assume you're editing the file directly, so you'd do something like this...
That'll add one to bytes 5 through 10 in the file. (Keep in mind that in VB addresses start at 1 instead of 0 like in most other things, so you'll have to add 1 to any addresses you want.) |
|||
windwaker Ball and Chain Trooper WHY ALL THE MAYONNAISE HATE Level: 61 Posts: 7/1797 EXP: 1860597 For next: 15999 Since: 03-15-04 Since last post: 4 days Last activity: 6 days |
| ||
Thanks a bunch! I am trying to make an encryption program and this will help a lot! Let's say I open a 10 byte file and say to edit bytes 1 through 15. Would this work? | |||
Mega-Dog Level: 20 Posts: 25/139 EXP: 40051 For next: 2388 Since: 03-15-04 From: Minnesota Since last post: 8 days Last activity: 4 days |
| ||
my way would be Option Explicit DIM fCont() as Byte open " redim fCont(lof(1)) get #1,,fCont close #1 this will load allt he bytes up in a array called fCont(). |
|||
FrenziedPanda89 Micro-Goomba Level: 8 Posts: 4/19 EXP: 2022 For next: 165 Since: 03-16-04 From: Canada Since last post: 553 days Last activity: 339 days |
| ||
I like this site. Enjoy http://www.garybeene.com/vb/tut-lang.htm |
Add to favorites | "RSS" Feed | Next newer thread | Next older thread |
Acmlm's Board - I2 Archive - Programming - Help with VB | | | |