Porting VB code

@Cho Sing Kum Understand completely Cho and appreciate your input. There’s a lot of silly coding in this VB6 code I have which makes absolutely no sense what-so-ever.
For example the coder is copying a byte array over and over and over again to prep it for encryption when it could have been done ‘prior’ to loading the text into the array. If you know you need the first 4 bytes why load the text get the Ubound, make another array 4 bytes bigger and copy the array to array(4) +, then stuff the first 4 bytes, then Redim the first array and copy the 2nd array back. To me you just add “0000” + text the first time. The coder has done things like this over and over again.
Occasionally I run across something I can’t deal with (hobby programmer with a lot more skill with databases), so I need to ask for help, I think in this case Michael is right, it’s just lazy programming or poorly ported from the original C. Always appreciate a 3rd or 4th opinion, I read and assess them all.