|
-
Sep 16th, 2004, 11:00 PM
#1
Thread Starter
New Member
problem using binary data with a stream
I have a database of my MP4 music files, and I'm trying to use VBA to modify the Header info.
I can load the file into a stream, modify the part of the header that I want to, but I can't write back to the stream.
I believe it has something to do with converting to Unicode and back.
If I don't convert to unicode and back, I can write, but as soon as I conver, I can't write. It says "Arguments are of the wrong type, are out of acceptable range, or are in conflict with oneanother.
Here's the code:
Dim st As Stream
Set MyStream = New Stream
MyStream.Open
MyStream.Type = adTypeBinary
MyStream.LoadFromFile "c:\audia.m4a"
Dim stri As Variant, aoeu as String
stri = MySteram.Read()
aoeu = StrConv(stri, vbUnicode)
' Replace the text in the header that I want, etc...
stri = strconv(aoeu, vbFromUnicode)
MyStream.write (stri)
MyStream.Close
--------------
I don't really know much about unicode, so hopefully it's something simple.
Thanks for any help!
Last edited by Evan Scamman; Oct 30th, 2004 at 11:42 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|