Advanced JavaScript Library
8.1 Hello World
Home > Documentation > 8.0 Tutorials > 8.1 Hello World


The following simple example serves as a quick check to test if your HTML page is correctly setup with Cheiron Library support. This example will display a message box with the "Hello World" text to the user. You can run the example online by clicking the "Show Me" button at the end of this page. You can also try any of the examples directly via the in browser Development Studio.


Step One: Create Your Html File

The easiest way to create your fist Cheiron Library compatible Html file is to download one of the pacakges from the downloads section of this website and find the "Template.html" file. Copy and rename this file to provide a canvas for your first Cheiron tutorial. For reference a simplified version of the contained Html is provided below. You may need to adjust the path of the script and theme files depending on how you have installed the libraries.

<link href="Themes/CheironBlue/CheironBlue.css" type="text/css" rel="stylesheet" />
        <script src="Scripts/System.js" type="text/javascript"></script>
        <script src="Scripts/System.Imports.js" type="text/javascript"></script>

Step Two: Add Your Main Function

Inside the "head" section of your Html page add a new script block using the standard tags as below. Insert an empty Main function inside the script block as below. The Cheiron Libraries will detect any Main function at page load and automatically run any code contained within it.

<script type="text/javascript">

    function Main()

Step Three: Add Your Main Function

Finally you need to add the actual Cheiron code to your sample page. Inside the main function add the following simple single line of Cheiron JavaScript code. This calls the System object's MessageBox function which acts as a helper to display a message window to the user. 

System.MessageBox("My First Cheiron Message", "Hello World!");


Next Tutorial: 8.2 Creating Controls

Shopping Basket
Your shopping basket is currently empty.
RSS Feed   Powered By Commerce Cloud
This site is powered by the Commerce Cloud Engine. Copyright (c) 2009 Exbos Limited. All Rights Reserved. SiteMap   Cookie Policy
Web site design and layout by Exbos Ltd. Copyright (c) 2010 Exbos Ltd. All Rights Reserved.
Commerce Cloud - the professional solution providing Enterprise Level Multiple Store Fronts all managed from a single sign on