Author Topic: About Easy Code functionality  (Read 8094 times)

Daniel

  • Regular Member
  • *
  • Posts: 1
About Easy Code functionality
« on: February 12, 2016, 05:31:53 PM »
Hi All,
I have just a general question. I am a vb6 programmer and I would like to know if Easy Code does allow me to work with other libraries in a COM standard. For example, is it possible to open an excel file, to modify some rows and save it ? Also, it would be useful to me to find out which are the similarities and differences between vb classic and this interesting language developed by Ramon Sala. Thank you in advance.


rsala

  • Moderator
  • Member
  • *****
  • Posts: 357
    • Easy Code
Re: About Easy Code functionality
« Reply #1 on: February 13, 2016, 07:55:49 AM »
Hi Daniel,

Thanks for your kind words about the IDE.

Easy Code was based on VB to make assembly programming easier. The very main difference is that Easy Code works only with assembly programming (supporting various assemblers), so you have to know the assembler language in depth.

Regards,

Ramon

BTW: Easy Code CANNOT open an excel file.
EC coder

HSE

  • Member
  • *****
  • Posts: 2491
  • AMD 7-32 / i3 10-64
Re: About Easy Code functionality
« Reply #2 on: February 13, 2016, 11:12:58 AM »
Ramon:
   Believe or not, it's posible and apparently not very dificult (using the work of Biterider, of course).

Daniel:
   You need ObjAsm32 macro system      http://masm32.com/board/index.php?board=43.0
   I don't know how easy is for a Asm beginner.


Regards. HSE
 
Equations in Assembly: SmplMath

jj2007

  • Member
  • *****
  • Posts: 13932
  • Assembly is fun ;-)
    • MasmBasic
Re: About Easy Code functionality
« Reply #3 on: February 13, 2016, 12:24:09 PM »
xlsConnect is another option; see \masm32\MasmBasic\Res\Masm2Excel.asc for a full example (needs MasmBasic).

@HSE: Can you post a small example? Here is one using xlsConnect:

include \masm32\MasmBasic\MasmBasic.inc      ; download
  Init
  xlsConnect                  ; no args=Excel, System
  .if !Zero?                  ; non-zero means success
      FileWrite "tmp.xls", "Just a test"      ; create a spreadsheet
      xlsCommand "[app.activate()]"           ; optional: activate Excel
      xlsOpen Cat$(CurDir$()+"tmp.xls")
      xlsConnect "tmp"
      .if !Zero?
            xlsWrite "R2C1", Cat$("This sheet was modified on "+Date$+", "+Time$)
      .endif
  .endif
  xlsDisconnect      ; say bye to Excel
EndOfCode

HSE

  • Member
  • *****
  • Posts: 2491
  • AMD 7-32 / i3 10-64
Re: About Easy Code functionality
« Reply #4 on: February 13, 2016, 12:50:00 PM »
Hi JJ!

The example is ObjAsm32\Projects\Office\ExcelHost
Equations in Assembly: SmplMath

mabdelouahab

  • Member
  • ****
  • Posts: 536
Re: About Easy Code functionality
« Reply #5 on: February 13, 2016, 08:02:13 PM »
Guys...
The man says "I am a vb6 programmer ... ", This means that it needs to MASM32REF  :biggrin:

jj2007

  • Member
  • *****
  • Posts: 13932
  • Assembly is fun ;-)
    • MasmBasic
Re: About Easy Code functionality
« Reply #6 on: February 13, 2016, 09:05:15 PM »
The example is ObjAsm32\Projects\Office\ExcelHost

Thanks. It works if you manually copy \Masm32\ObjAsm32\Code\ObjMem32\ObjMem32.lib to \Masm32\lib\ObjMem32.lib

A bit more complicated than my example, though: 240 lines of source code, plus 1.4 MB of specific include files...

Biterider

  • Member
  • *****
  • Posts: 1082
  • ObjAsm Developer
    • ObjAsm
Re: About Easy Code functionality
« Reply #7 on: February 13, 2016, 10:07:33 PM »
Hi jj
ObjMem32.lib and .inc should be copied on corresponding MASM directories on installation of OA32. Did you experience any problems with that?
In the ObjMem32 directory is a .bat file I use to copy/update those files when I changed something in the library.

I count 60 lines including comments and empty lines on the word super simple demo application...
In my opinion, it is more a matter of taste which approach you choose to deal with COM & .NET.

Regards, Biterider


jj2007

  • Member
  • *****
  • Posts: 13932
  • Assembly is fun ;-)
    • MasmBasic
Re: About Easy Code functionality
« Reply #8 on: February 14, 2016, 03:33:46 AM »
Hi Biterider,

The installation of the .lib was not automatic this time, and the make.bat just shouted "error" without explaining the cause. But opening \Masm32\ObjAsm32\Projects\Office\ExcelHost\ExcelHost.asm in RichMasm and hitting F6 gave me sufficient info to understand that I had to copy the lib to its Masm32 folder.

The Excelhost example itself is impressing, compliments :t

For my needs, DDE is enough, though ;-)

Jochen

Biterider

  • Member
  • *****
  • Posts: 1082
  • ObjAsm Developer
    • ObjAsm
Re: About Easy Code functionality
« Reply #9 on: February 14, 2016, 04:16:08 AM »
Hi Jochen
If you use the provided make.bat files, if an error happened, look for a file named make.txt. All messages (stdout) are echoed into this file, so you can follow most of the times where the problem lies.
I'll check the installation routine again to find where something could go wrong.
Thanks.  ;)

Biterider

rsala

  • Moderator
  • Member
  • *****
  • Posts: 357
    • Easy Code
Re: About Easy Code functionality
« Reply #10 on: February 18, 2016, 07:27:56 AM »
Quote
Believe or not, it's posible and apparently not very dificult (using the work of Biterider, of course).
Quote
xlsConnect is another option; see \masm32\MasmBasic\Res\Masm2Excel.asc for a full example (needs MasmBasic).

Thanks, I did not know that.
EC coder