Posts tagged LiveCode

LiveCode is a modern day HyperCard

This post is a reply to Why HyperCard had to Die — by Stanislav. I’m not saying the post is wrong, I am just presenting an alternative that is alive and working well. LiveCode is a modern day HyperCard and everyone who used HyperCard will feel at home at it.

LiveCode runs on macOS, Windows and Linux and can generate standalone binaries for all those platforms plus Android and iOS. You can get it from https://www.livecode.com or you can get a GPL version of it from https://www.livecode.org.

In this post, I will recreate the demo that Stanislav created on their post which was a simple four operation calculator. I hope readers will notice how familiar the environment is and yet how modern it became.

Disclaimer: I work for LiveCode.

Created a Leanpub helper Desktop App

I’ve been having a lot of fun with my new book LiveCode Advanced Application Architecture (available on this site and on Leanpub). To make my life easier, I set aside some hours today to create a little desktop helper application for Leanpub. I wanted an app that could show me some quick information about my sales, allow me to generate new previews and publish new versions of the books.

Leanpub Quickboard running on Windows 10

Leanpub Quickboard running on Windows 10

I’ve written a new book about LiveCode

I’ve just written a new LiveCode book. It explores the best practices used by seasoned LiveCode developers from around the world and also how to apply insights from the MVC pattern into that platform. Along the book you work through a simple address book application while learning all the tips and tricks from our community.

LiveCode Advanced Application Architecture

LiveCode Advanced Application Architecture

The book is available for GBP 15 and can be purchased with the button below, or you can read more and learn about the unique bundle I am offering.

Read more for learning about the bundle and also about the experience of writing another book.

DB Lib Goes Open Source with GPL

DB Lib is a minimalistic database library for LiveCode that works on Desktop and Mobile and allows you to build database-savvy apps without writing SQL directly. For example consider the following code:

dbWhere "country", "Brazil" put dbGet("contacts") into tDataA set the dgdata of control "contacts" to tDataA

It picks all records from the contacts table that have the country field equals to Brazil and set a datagrid to it. It’s very easy to use. A more involved example:

on mouseUp -- assemble array put dbCardToArray("contacts") into tDataA -- check if we're adding a new record -- or updating an existing one. -- -- this check depends on the record id being present. if field "id" is empty then get dbInsert("contacts", tDataA) if it is not a number then answer error it else answer "New Record Saved" end if go card "contact list" else dbWhere "id", field "id" get dbUpdate("contacts", tDataA) if it is not a number then answer error it else answer "Record Updated" end if go card "contact list" end if end mouseUp

In this code first we pick the data from a card using dbCardToArray(), a function that magically picks data from fields, buttons and other controls, and assemble an array that is used to insert or update a given record depending on the presence of an id field.

This is just a quick glimpse of what you can do with DB Lib. It is basically a ORM for LiveCode.

Mentions