The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: Henut on April 02, 2012, 01:55:54 PM

Title: I am a new in masm32,I need some help
Post by: Henut on April 02, 2012, 01:55:54 PM
I am glad you come here
I  write code as icz's example in RadASM
when I builde it     
There are a lot of mistakes
just as:
\masm32\lib\user32.lib(31) : error A2044: invalid character in file
\masm32\lib\user32.lib(32) : error A2044: invalid character in file
\masm32\lib\user32.lib(33) : error A2044: invalid character in file
\masm32\lib\user32.lib(34) : error A2044: invalid character in file

I want to know how to point out where the mistake it is,just as when bulid in VC it can point out which  codes has mistake.

Excuse me,I am not good at english
Title: Re: I am a new in masm32,I need some help
Post by: MichaelW on April 02, 2012, 02:10:59 PM
Hello Henut, welcome to the forum.

It looks like you are trying to include user32.lib with:

include \masm32\lib\user32.lib

When libraries must be included with includelib:

includelib \masm32\lib\user32.lib

You can avoid these problems by replacing all of this:

      .486                      ; create 32 bit code
      .model flat, stdcall      ; 32 bit memory model
      option casemap :none      ; case sensitive

;     include files
;     ~~~~~~~~~~~~~
      include \masm32\include\windows.inc
      include \masm32\include\masm32.inc
      include \masm32\include\gdi32.inc
      include \masm32\include\user32.inc
      include \masm32\include\kernel32.inc
      include \masm32\include\Comctl32.inc
      include \masm32\include\comdlg32.inc
      include \masm32\include\shell32.inc
      include \masm32\include\oleaut32.inc

;     libraries
;     ~~~~~~~~~
      includelib \masm32\lib\masm32.lib

      includelib \masm32\lib\gdi32.lib
      includelib \masm32\lib\user32.lib
      includelib \masm32\lib\kernel32.lib
      includelib \masm32\lib\Comctl32.lib
      includelib \masm32\lib\comdlg32.lib
      includelib \masm32\lib\shell32.lib
      includelib \masm32\lib\oleaut32.lib
. . .


With:

include \masm32\include\masm32rt.inc
Title: Re: I am a new in masm32,I need some help
Post by: Henut on April 02, 2012, 02:33:36 PM
thanks for your advice
in the code I write:

include \masm32\include\windows.inc
include \masm32\include\user32.inc
include \masm32\include\kernel32.inc
include \masm32\lib\user32.lib
include \masm32\lib\kernel32.lib

but it can't work well
the mistake still exist

if i copy icz's codes to paste,it will run normal.
but wen I type in by meself,there wiil be many mistakes
Title: Re: I am a new in masm32,I need some help
Post by: Henut on April 02, 2012, 02:38:05 PM
Oh my god
yes just as you say,I miss "lib"
thank you
Title: Re: I am a new in masm32,I need some help
Post by: vanjast on April 02, 2012, 04:42:40 PM
Welcome to the world of...... strange people !! :U
Title: Re: I am a new in masm32,I need some help
Post by: dedndave on April 02, 2012, 05:49:01 PM
welcome to the forum   :U

yah - Iczelion's tutorials could use a little update   :P
if you get a "symbol redefinition" error,
it may be that the example program defines something that more recent versions of the masm32 package take care of for you
Title: Re: I am a new in masm32,I need some help
Post by: Henut on April 04, 2012, 08:29:51 PM
 :wink
many thanks your remind
I very like here,so many good natured man
Title: Re: I am a new in masm32,I need some help
Post by: vanjast on April 04, 2012, 09:42:37 PM
Me- The Cooley guy, from darkest africa - I mean really dark  :green2
Hutch - Cantankerous old aussie 'GIT'
Dendave - Cool when Z is not looking over his shoulder  :wink
Bill Cravener - Next to Dendave
Donkey - Now he's cool, actually frozen solid in Canada
baltoro - He's unstable on the San Andreas fault line
BogdanOntanu - Now this guy needs a haircut, and a cleanup!
carlos - He comes from MEXICO.. why, I have no idea?
sinsi - He's a bearded male aussie dog from Adelaide... a really southern type  :bg

..and a whole lot more mudder fookers welcome you too  :U

Title: Re: I am a new in masm32,I need some help
Post by: dedndave on April 05, 2012, 06:28:56 AM
about Sinsi's location...
i have a ham radio buddy down there in Moana Beach - pretty close to Sinsi
Peter - VK5ZPS
not too far from the antarctic circle - brrrrrr
Title: Re: I am a new in masm32,I need some help
Post by: hutch-- on April 05, 2012, 01:47:50 PM
You would change your mind in the summer, I have been in Adelaide when it topped 120 degrees in the old scale.
Title: Re: I am a new in masm32,I need some help
Post by: dedndave on April 05, 2012, 08:43:17 PM
well - it's not that close to the circle, i guess   :P

wow - 35 deg S - that's not near as far south as i was thinking
that's not much different than the N lat of Phoenix