• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Read out/write .w3x Files with vb?

Status
Not open for further replies.
Level 8
Joined
Apr 24, 2007
Messages
47
Hi, i'm working on an tool but i have problems to read out or write some parameters in .w3x Files. I'm working with vb but i have think i have not enough skill to know how to read out this kind of file. I hope someone can help me. If it's with vb impossible, i can also need a information in c#...
 
Level 13
Joined
Aug 31, 2005
Messages
823
What version of vb are you using? 6.0?
If you want to load the .w3x file, I'd suggest something like this:
Code:
On Error Goto ErrorSho
Open "c:\My Documents\sample.w3x" For Output As #1
ErrorSho: 
MsgBox Error(Err)
That will open the file (if your interface supports it). Id suggest getting the file to open before moving too far into it.
 
Level 8
Joined
Apr 24, 2007
Messages
47
I just have VB2005 Express Edition......... -.-'
The only way i know to read out files with it is

Code:
MapText = My.Computer.FileSystem.ReadAllText("D:\Programme\Warcraft III\Maps\(2)BootyBay.w3m")

But the result is only the Textstring "HM3W" ...... Just a simple "open" i never found in this version -.-'
 
Status
Not open for further replies.
Top