Wednesday 2 April 2008

Yuma

I've been playing with Yuma and it's great fun.

I've got a lot of learning to do but I thought I'd mention one or two bits I've found useful.

I have an include file called myGlobals.yuma which includes methods



Sub MsgBox(s As String)
Function MsgBox(s As String, buttons as Integer) As Integer
Function MsgBox(s As String, buttons as Integer, Title As String) As Integer
Sub printLine(s As String)
Sub printParagraph(s As String)
Function lineBreak() As String
Const TargetYuma = True
The msgBoxes are just to stop test code falling over when I compile for RB and Yuma.

The other methods are for simpler formatting within Yuma and try to make the source a bit more readable when adding breaks or paragraphs to the output.

TargetYuma helps with conditional compilation.

In my RB code, I use a similar module which stops the RB code from falling over by having methods
Sub print
Sub PrintLine(s As String)
Sub printParagraph(s As String)
Function lineBreak() As String
Const TargetYuma = False
I save the project in VCF format, so picking classes and modules and converting them to Yuma then becomes a breeze.

Some of the very simple stuff I've tried so far is available for download from my website but please be aware that site is not running Yuma. The .yuma files need to be downloaded and tested on your own yuma development server.

2 comments:

Anonymous said...

That's a good idea, Steve. I especially like the TargetYuma constant. Hmm... maybe we should build that in, although since RB doesn't have it, you'd still need to define it (as False) somewhere in your RB projects. I'm not sure what we can do about that.

Steve Garman said...

There'll probably be more than TargetYuma before you've finished.

My guess is you'll want to offer some sort of module as an rbo file for RB users, even if you decide to keep quiet about Yuma's RB roots when dealing with web developers.