Search Results for procedure

 

Style Guide, Procedures and Code Documentation

In order for source code to be more readily readable across teams, it is recommended that your source code always be styled according to this style guide.

 

 

Table Action

Table Actions are presented to the users of the Default Admin interface and are also intended to be made available in a dynamic way to users of a customized front end. As an Action, the Procedure is expected to perform some sort of task, such as an automated set of updates to the Database Table.

 

Include

An Include Procedure cannot be executed directly, the contents of its source code can only be Included into other Procedures using the Include command.

 

 

 

 

 

Public Method

A Public Method may be called from any other Procedure, by the Default plug-in, or a Custom COM DLL. Each Public Method may either use specific Input Parameters, or it may accept an Input Query.

 

Record Action

Record Actions are presented to the users of the Default Admin interface and are also intended to be made available in a dynamic way to users of a customized front end. As an Action, the Procedure is expected to perform some sort of task, such as an automated set of updates to the Database Record.

 

Record Report

Record Reports are presented to the users of the Default Admin interface and are also intended to be made available in a dynamic way to users of a customized front end. As a Report, the Procedure is expected to produce output to be displayed to the user.

 

Table Report

Table Reports are presented to the users of the Default Admin interface and are also intended to be made available in a dynamic way to users of a customized front end. As a Report, the Procedure is expected to produce output to be displayed to the user.

 

MOX Coding and Programing Language Syntax Documentation

The MOX coding and programming language pays heritage to BASIC, but has been crafted for the specific type of work and environment that is demanded of Moxie.Build.

 

Message Handler

A Message Handler is only ever called by the Database on a Database Event. These Event Messages allow a Developer to intercept operations taking place on a per-record level and implement Event based business logic.

 

PaaS Method

A PaaS Method may be called by any other Moxie system. In order to call a PaaS Method from MOX, the PaaS statement is used.

 

Remote Method

A Remote Method may be called by any other Moxie system. It can be used to divide up a large system among a number of backend servers, or as a public API for 3rd parties. In order to call a Remote Method from MOX, the Remote statement is used.

 

Method

Private Method contained within a given procedure.

 

Include

Takes one parameter, ProcedureName

 

Export and Import of Database Schema

ExportSchema and ImportSchema are BuiltIn procedures that are available for use with source control systems.

 

Get Started with Setting up the Development Environment

Developing in Moxie.Build on localhost give you the advantage of working with the template files natively. When working on procedures (MOX code) you need to access that through the Procedures page in the Admin area of a Moxie.Build system, if running the server on localhost or on a remote server. When running on a remote server, you can edit the template files via the Files page in the Admin area.

 

Query Based Routing Example

For small and simple procedures that are not expected to grow in complexity over time, simple routing based on URL parameter values from a [Pull] directly from the Request query is sufficient and requires less code. For complex procedures that are expected to grow and evolve over time, a larger more robust foundation for the routing should be used.

 

Learn More about Frontend Development

Prerequisites: This tutorial assumes that you have already set up a Category and Procedure if necessary. This page covers some of the basics that are involved in Front End development using the MOX language.

 

Moxie.cfg Config

The Moxie.cfg file is read on server start and controls aspects that cannot be changed while the server is running.

 

Command Line with .mox file

A .mox file, with MOX code in it, can be run from the command line while a Moxie.Build system is not otherwise already running.

 

Thread

Takes a variable number of parameters

 

TRON

Takes one parameter, FilePath

 

Moxie.http Headers

The optional Moxie.http file is read on server start and controls the default HTTP headers set for all requests.

 

UpdateTableProc

Takes ten parameters, TableName, OldProcName, NewProcName, Type, Params, GroupTypes, Label, Note, DevNote, Source

 

SkipCalls

Takes no parameters

 

Nightly Management Utility

This utility program manages a server install with one or many Moxie.Build services running by taking care of nightly tasks via a scheduled task.

 

LoadNulFile

Takes two parameters, FileName, bHasHeader

 

OnError (Continue)

Used as a scoping keyword, similar to WorkWith/End WorkWith .

 

PaaS

Takes three parameters, Url, SaaSTenant, InputQuery, OutputQuery

 

Lang

Takes four parameters, FieldBase, Destination, Source, IfLenFld

 

MsgBox

Takes two parameters, Text, Title

 

HtmlBlocks / End HtmlBlocks

Takes two parameters, Location, Mode

 

SetKillCount

Takes one parameter, Value

 

Sleep

Takes one parameter.

 

Remote

Takes three parameters, Url, InputQuery, OutputQuery

 

Select / Case / End Select

Takes a variable number of conditional statements to compare against a single source

 

HtmlHistory

Takes two parameters, Title, Path

 

HtmlBlock / End HtmlBlock

Takes two parameters, Location, Mode

 

InStr%

Takes two parameters, Source, Match

 

InStr$

Takes two parameters, Source, Match

 

Html

Takes 3 parameters, Location, Mode, Text

 

Lang$

Takes one parameter, Source

 

InStrAny$

Takes two parameters, Source, Match

 

InStrAny%

Takes two parameters, Source, Match

 

RecoverMOX$

Takes one parameter, HtmlEscapedString, and returns the Unescaped Version of this string

 

FlushAll

Has no parameters

 

Flush

Takes one parameter, TableName

 

NewTableProc

Takes nine parameters, TableName, ProcName, Type, Params, GroupTypes, Label, Note, DevNote, Source

 

ListProcs

Takes one parameter, TableName

 

DeleteTableProc

Takes two parameters, a TableName and ProcName

 

HttpNoCache

Has no parameters.

 

[If] Assignment (Top Query)

Parameter is divided into two parts, the Test and the Result if True. The test comes prior to the keyword of Then and the Result if True comes after.

 

HttpsEnsure

Takes no parameters.

 

[CountIf]

Takes one parameter, TestCondition

 

Folder and File Structure

Brief overview on the file structure and contents under Moxie. The files and folders discussed in this post are those that are essential when upgrading to the most recent version of Moxie.Build , or when troubleshooting server errors.

 

[Sort] (DB Relationship Attribute)

Accepts a space separated list of field names.

 

Public Method WorkQuery Example

In this example, you will see how to use a public method that works on or with the current WorkQuery that you pass into the method.

 

Call

Takes a variable number of parameters

 

AjaxReply

Has no parameters

 

[If] Assignment (DB Field Attribute)

Parameter is divided into two parts, the Test and the Result if True. The test comes prior to the keyword of Then and the Result if True comes after.

 

 

 

Learn More About the Content Management System

Prerequisites: This page assumes that you have already set up your Moxie.Build server and logged in as an admin user. This page covers some of the basics that are involved in using the Content Management aspects of the Moxie.Build system.

 

Templates Documentation

Prerequisites: This tutorial assumes that you have already learned about Managing Files .

 

 

IncrKillCount

Has one parameter.

 

If (Not) / And / Or / ElseIf / End If

Takes a variable number of conditional statements

 

JsonReply

Has no parameters

 

Meta

Takes any unspecified data, intended for use by external systems

 

LangWith

Has one parameter, a Content.Lang prefix

 

GoTo

Takes one parameter, a Label

 

Exception

Takes one parameter, the text of the exception to throw.

 

Error

Takes one parameter, the text of the error to throw.

 

Critical

Takes one parameter, the Name of the critical section

 

Function

A special type of Private Method, called a Private Function, that is intended to return a single value or multiple values simultaneously.

 

Exit (Proc)

Takes no parameters