Table of Contents
Valentina Studio Examples : JS Scripts
In this Valentina Project (updated 2017-05-10 for v7.1) you can find few JS scripts that generate some code for a DB or Table you choose in the Schema Editor.
- Open this project in Valentina Studio 7.1 or newer.
- In the folder gen_code choose a folder with language for which you want to generate. For example, 'for xojo'
- Open script you want to run, click RUN button. Some scripts may want a current Database/Table to be selected in the Schema Editor.
FUNCTION Cmd with Binding
Generate FUNCTION with SQL Insert/Update/Delete with Binding. This example also demonstrates how easy you can create own dialog using JS.
PROJECT with CreateSchema
Generate PROJECT with MODULE which has many functions CreateTable_TN(), CreateView_VN, CreateTrigger_TN(), … CreateSchema. Script write correct Connect() Disconnect() methods for local SQLite or remote mySQL dbs. Project is workable.
Project VDB ClassWay
Generate PROJECT with MODULE, which contains the set of classes to implement Class-way style of Valentina DB.