Getting Started

To get started we recommend to have a look at our demo app, there is source code provided with each example so you can get an idea of how the awesome library work, you can also download its source code. You can also watch our main video tutorial and build a new app yourself while watching the video. When creating a new solution using the awesome library make sure to have a look at the installation page

General features

The awesome controls have some common functionality/features, you can see this functionality explained below.

Getting data

You can get the data via ajax by specifying the the
. If nothing is specified the control will look for a controller with the same name as it + its type, example:
@Html.Awe().AjaxRadioList("Country1").Url(Url.Action("GetCountries", "Data")) // gets data from Data/GetCountries; url specified by .Url extension
@Html.Awe().AjaxDropdown("Meal") // gets data from MealAjaxDropdown/GetItems by convention
@Html.Awe().AjaxCheckboxList(o => o.Meals1).Controller("BestMealAjaxDropdown") // gets data from BestMealAjaxDropdown/GetItems
The url will get the current value of the control in the
parameter, so we can define it if it's needed:
public ActionResult GetCountries(int? v) // v has the current value
you might not need it for the AjaxDropdown and similar controls, but you will need it for the Lookups

Binding to Parents

Some components can be bound to parents, this way when they request data, the values of the parents are also sent to the server, and for some controls (like AjaxDropdown, Grid, etc.), changing the value of a parent will trigger the child to reload, so you get a cascading effect. This is done using the
.Parent(name, alias = "parent", loadOnChange = true)
extension. By default the value of the parent will be sent using the
name of the parameter, but different names can be specified using the alias, example:
@Html.TextBoxFor(o => o.Name)
<input type="text" value="hi" id='foo1' />
@Html.Awe().AjaxCheckboxListFor(o => o.Categories)

@(Html.Awe().AjaxDropdownFor(o => o.Meal)
       .parent("foo1", "foo")
       .Parent(o => o.Categories, "cats")    // parent Categories with alias "cats"
       .Parent(o => o.Name)) // parent Name with default alias "parent"
And now in
action we're getting the values of the parent controls using the specified parameter names (alias).
public ActionResult GetMyMeals(string foo, int[] cats, string parent) 

Predefined parameters

Additonal parameters with predefined values can be sent to the server using
.Parameter(name, value)
       .Parameter("category", 3)
       .Parameter("chefid",  7)
    function getData(){
        return {x: 100, y: 230 };
And the
action could look like this:
public ActionResult GetMeals(int category, int chefid, int x, int y){

Changing default settings

You can change the default values for the controls by calling something like this:
Settings.Lookup.HighlightChange = true;
Settings.Lookup.Title = "please select";
Settings.MultiLookup.Fullscreen = true;
Usually you would call this when the application starts (
Global.asax Application_Start

Localising default texts

See our localisation page. Use web debugging tools: We highly recommend to use web debugging tools in your development, most modern browsers have them by default and you can activate it by hitting F12 or Ctrl+Shift+I , this way when a javascript error will happen you'll see it in your web debugger's console, you'll also be able to see all the ajax requests and results, if they were successful, data that was received etc.