| 1 |
lars |
1 |
<%@ Theme="Basic" %>
|
|
|
2 |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
|
3 |
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" >
|
|
|
4 |
<com:THead Title="Currency Converter" />
|
|
|
5 |
<body>
|
|
|
6 |
<com:TForm>
|
|
|
7 |
<fieldset>
|
|
|
8 |
<legend>Currency Converter</legend>
|
|
|
9 |
<div class="rate-field">
|
|
|
10 |
<com:TLabel ForControl="currencyRate" Text="Exchange Rate per $1:" />
|
|
|
11 |
<com:TTextBox ID="currencyRate" />
|
|
|
12 |
<com:TRequiredFieldValidator
|
|
|
13 |
ControlToValidate="currencyRate"
|
|
|
14 |
Display="Dynamic"
|
|
|
15 |
ErrorMessage="Please enter a currency rate." />
|
|
|
16 |
<com:TCompareValidator
|
|
|
17 |
ControlToValidate="currencyRate"
|
|
|
18 |
DataType="Float"
|
|
|
19 |
ValueToCompare="0"
|
|
|
20 |
Operator="GreaterThan"
|
|
|
21 |
Display="Dynamic"
|
|
|
22 |
ErrorMessage="Please enter a positive currency rate." />
|
|
|
23 |
</div>
|
|
|
24 |
<div class="dollar-field">
|
|
|
25 |
<com:TLabel ForControl="dollars" Text="Dollars to Convert:" />
|
|
|
26 |
<com:TTextBox ID="dollars" />
|
|
|
27 |
<com:TRequiredFieldValidator
|
|
|
28 |
ControlToValidate="dollars"
|
|
|
29 |
Display="Dynamic"
|
|
|
30 |
ErrorMessage="Please enter the amount you wish to calculate." />
|
|
|
31 |
<com:TDataTypeValidator
|
|
|
32 |
ControlToValidate="dollars"
|
|
|
33 |
DataType="Float"
|
|
|
34 |
Display="Dynamic"
|
|
|
35 |
ErrorMessage="Please enter a number." />
|
|
|
36 |
</div>
|
|
|
37 |
<div class="total-field">
|
|
|
38 |
<span class="total-label">Amount in Other Currency:</span>
|
|
|
39 |
<com:TActiveLabel ID="total" CssClass="result" />
|
|
|
40 |
</div>
|
|
|
41 |
<div class="convert-button">
|
|
|
42 |
<com:TActiveButton Text="Convert" OnClick="convert_clicked" >
|
|
|
43 |
<prop:ClientSide.OnLoading>
|
|
|
44 |
$('<%= $this->total->ClientID %>').innerHTML = "calculating..."
|
|
|
45 |
</prop:ClientSide.OnLoading>
|
|
|
46 |
</com:TActiveButton>
|
|
|
47 |
</div>
|
|
|
48 |
</fieldset>
|
|
|
49 |
</com:TForm>
|
|
|
50 |
</body>
|
|
|
51 |
</html>
|