EC goAsm 'Hello World' errors, & EC/Help

Started by vmars316, June 16, 2011, 09:11:37 PM

Previous topic - Next topic

vmars316

Ugh, three errors:
============== helloWorld - Debug ==============

Compiling resources...
Assembling: winMain

1)
Warning .......................
Line 16 of assembler source file (winMain):-
Could not open file:-
#include "windows.inc"

But Tools/settings/compile/link says "C:\EasyCode.Go\GoASM\Include\"
and "windows.inc" is in both  C:\EasyCode.Go\GoAsm\Include  and 
also in  C:\EasyCode.Go\Include

2)
Error!
Line 62 of assembler source file (winMain):-
Unexpected material:-
<0,0>

But there are only 45 lines of code.

OBJ file not made
Errors ocurred.
=================================
3)
In EC/help
all the help files work fine.
Except, 'win32 help':
what it gives me instead is
an html listing of directory: C:\EasyCode.Go\GoASM\Help\
I have both win32.HLP and win32.GID in there.

Thanks...vmars316
.
All things in moderation, except for love and forgiveness...vmars316
.
www.QuickerThanASpark.com

vmars316

Oh, I forgot to mention
that if i just dblClick on win32.hlp
all is well.
But clicking on the ec/help/win32
no work'em good.
Thanks...vmars
.
All things in moderation, except for love and forgiveness...vmars316
.
www.QuickerThanASpark.com

vmars316

Quote from: vmars316 on June 16, 2011, 09:49:55 PM
But clicking on the ec/help/win32
no work'em good.
I downloaded a diff version of "win32api.zip"
and installed it.
Work'em good.
It has quite a few more files.

But still  1)  and  2)  above are still a prob.

Thanks...vmars
.
All things in moderation, except for love and forgiveness...vmars316
.
www.QuickerThanASpark.com

vmars316

Hmm...
The windows.inc i have installed is 2k.
The WINDOWS.INC i just downloaded is 1,113kb .
Pls, which one should i be using for EC/GoAsm ?
Thanks...vmars
.
All things in moderation, except for love and forgiveness...vmars316
.
www.QuickerThanASpark.com

TmX

I think it's best to use Donkey's Headers
EC supports it: Tools -> Settings -> General -> Use the GoAsm headers

vmars316

Thanks Tmx.
I downloaded Donkeys zip
and installed in c:\GoAsm\Include
Should i also take files out of Folders?

Pls, i need answer for question  2)  above:

>Error!
>Line 62 of assembler source file (winMain):-
>Unexpected material:-
><0,0>

when i compile 'hello window' program (see below)
.Const

.Data

WINMAIN_MESSAGES   DD WM_CREATE, OnwinMainCreate
               DD WM_CLOSE, OnwinMainClose

.Code

winMainProcedure Frame hWnd, uMsg, wParam, lParam
   Mov Eax, [uMsg]
   Mov Ecx, SizeOf WINMAIN_MESSAGES / 8
   Mov Edx, Addr WINMAIN_MESSAGES
:   Dec Ecx
   Js > L2
   Cmp [Edx + Ecx * 8], Eax
   Jne <
   Call [Edx + Ecx * 8 + 4]
   Ret
L2:   Xor Eax, Eax   ;Return (FALSE)
   Ret
EndF

OnwinMainCreate:
   UseData winMainProcedure
   ;==================================
   ;Write the initialization code here
   ;==================================
   Xor Eax, Eax   ;Return (FALSE)
   Ret
EndU

OnwinMainClose:
   UseData winMainProcedure
   ;=========================
   ;Write the final code here
   ;=========================
   Invoke IsModal, [hWnd]
   Or Eax, Eax      ;Cmp Eax, FALSE
   Jz >
   Invoke EndModal, [hWnd], IDCANCEL
   Mov Eax, TRUE   ;Return (TRUE)
:   Ret
EndU

Thanks...vmars



.
All things in moderation, except for love and forgiveness...vmars316
.
www.QuickerThanASpark.com

Ramon Sala

Hi vmars,

No, you should not take files out of Folders in GoAsm headers.

About the error, may a see the declaration having that "<0,0>"?

Ramon
Greetings from Catalonia

vmars316

Quote from: Ramon Sala on June 17, 2011, 10:07:01 PM
Hi vmars,

No, you should not take files out of Folders in GoAsm headers.

About the error, may a see the declaration having that "<0,0>"?

Ramon


Hi Ramon,
That's the prob,
there is no "<0,0>",
see the code above.
That's the exact code.

When i open c:\GoAsm\debug\
which contains
winMain.asm , winMain.File ,
winMain.File does contain <0,0>
As a matter of fact line 62 looks like this:
icc   INITCOMMONCONTROLSEX   <0,0>

The whole of 'winMain.File' is attached.

Thanks...vmars
.
All things in moderation, except for love and forgiveness...vmars316
.
www.QuickerThanASpark.com

Ramon Sala

Hi vmars,

I just created a visual project (Project1) with a window named winMain. Then I copied and pasted the code above and it compiled and linked without any error (I attach the project I'm referring to), so I don't know what is hapenning in your computer.

Also, I attach an image of my "Compile / Link" tab for you to see (I have the GoAsm folder in drive G:).

I hope that can help you,

Ramon
Greetings from Catalonia

vmars316

Hi Ramon,
I made the changes to compile/link
When I run your winMain, it runs fine.
But it does give 1 Warning:

Warning .......................
Line 785 of the include file commctrl.h:-
Could not evaluate expression in conditional directive (rest of file skipped):-
NTDDI_WINCE
Linking...

But when I copy your code
into my helloWorld - winMain (Window)

I get the same error:
Error!
Line 62 of assembler source file (winMain):-
Unexpected material:-
<0,0>
OBJ file not made

Strange huh!

When I compared your Project1.ecp
to my helloWorld.ecp

Your Project1.ecp has the following:  Include=commctrl.h
Where as helloWorld.ecp has no such line.
When I add  Include=commctrl.h  to  helloWorld.ecp 
helloWorld.ecp code runs fine, and shows the same warning as yours does.

I may have initially had probs with  finding  commctrl.h  in my project. 
I'll keep an eye on it. If it happens again, I'll Post it.

Thanks...vmars
.
All things in moderation, except for love and forgiveness...vmars316
.
www.QuickerThanASpark.com

Ramon Sala

Hi Vmars,

I think I know what happened.

You probably created the "Hello' project before having the GoAsm headers (or without having the 'Use the GoAsm headers' option selected). If so, Easy Code automatically includes the 'Windows.inc' file (and maybe other 'inc' files). When projects are created with the 'Use the GoAsm headers' option selected then EC automatically includes the 'windows.h' files (and maybe other '.h' files).

If you like, and just for testing, create a new 'Hello' project with the 'Use the GoAsm headers' option selected and then paste the code in the main window.

Regards,

Ramon
Greetings from Catalonia

vmars316

Hi Ramon,
Yes, That sounds right.
@ next project i'll know for sure.
Thanks...vmars
.
All things in moderation, except for love and forgiveness...vmars316
.
www.QuickerThanASpark.com