<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.appstudio.dev/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Admin</id>
	<title>NSB App Studio - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.appstudio.dev/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Admin"/>
	<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/Special:Contributions/Admin"/>
	<updated>2026-07-16T16:55:04Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.46.0</generator>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Language_reference&amp;diff=7878</id>
		<title>Language reference</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Language_reference&amp;diff=7878"/>
		<updated>2015-11-21T21:32:02Z</updated>

		<summary type="html">&lt;p&gt;Admin: Reverted edits by Ftaalish (talk) to last revision by Ghenne&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
== Language Reference ==&lt;br /&gt;
&lt;br /&gt;
[[abs|Abs() Function]]&lt;br /&gt;
&lt;br /&gt;
[[ajax|Ajax() Function]]&lt;br /&gt;
&lt;br /&gt;
[[and|And Operator]]&lt;br /&gt;
&lt;br /&gt;
[[array|Array() Function]]&lt;br /&gt;
&lt;br /&gt;
[[asc|Asc() Function]]&lt;br /&gt;
&lt;br /&gt;
[[atn|Atn() Function]]&lt;br /&gt;
&lt;br /&gt;
[[call|Call() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[changeform|ChangeForm() Function]]&lt;br /&gt;
&lt;br /&gt;
[[chr|Chr() Function]]&lt;br /&gt;
&lt;br /&gt;
[[const|Const() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[conversions|Conversions Function]]&lt;br /&gt;
&lt;br /&gt;
[[cos|Cos() Function]]&lt;br /&gt;
&lt;br /&gt;
[[date|Date Function]]&lt;br /&gt;
&lt;br /&gt;
[[dateadd|DateAdd() Function]]&lt;br /&gt;
&lt;br /&gt;
[[datediff|DateDiff() Function]]&lt;br /&gt;
&lt;br /&gt;
[[datepart|DatePart() Function]]&lt;br /&gt;
&lt;br /&gt;
[[dateserial|DateSerial() Function]]&lt;br /&gt;
&lt;br /&gt;
[[datevalue|DateValue() Function]]&lt;br /&gt;
&lt;br /&gt;
[[day|Day() Function]]&lt;br /&gt;
&lt;br /&gt;
[[debugger|Debugger Statement]]&lt;br /&gt;
&lt;br /&gt;
[[dim|Dim() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[do...loop|Do...Loop Statement]]&lt;br /&gt;
&lt;br /&gt;
[[eqv| Eqv Operator]]&lt;br /&gt;
&lt;br /&gt;
[[erase|Erase() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[escape|Escape() / unEscape() Function]]&lt;br /&gt;
&lt;br /&gt;
[[eval|Eval() Function]]&lt;br /&gt;
&lt;br /&gt;
[[events|Events Control]]&lt;br /&gt;
&lt;br /&gt;
[[execute|Execute() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[exit|Exit Statement]]&lt;br /&gt;
&lt;br /&gt;
[[exp|Exp() Function]]&lt;br /&gt;
&lt;br /&gt;
[[filter|Filter() Function]]&lt;br /&gt;
&lt;br /&gt;
[[fix|Fix() Function]]&lt;br /&gt;
&lt;br /&gt;
[[for...next|For...Next Statement]]&lt;br /&gt;
&lt;br /&gt;
[[for each...next|For Each...Next Statement]]&lt;br /&gt;
&lt;br /&gt;
[[Form|Form Control]]&lt;br /&gt;
&lt;br /&gt;
[[format|Format() Functions]]&lt;br /&gt;
&lt;br /&gt;
[[function|Function() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[getlocale|GetLocale() Function]]&lt;br /&gt;
&lt;br /&gt;
[[getref|GetRef() Function]]&lt;br /&gt;
&lt;br /&gt;
[[geturlparameter|GetURLParameter() Function]]&lt;br /&gt;
&lt;br /&gt;
[[hex|Hex() Function]]&lt;br /&gt;
&lt;br /&gt;
[[hour|Hour() Function]]&lt;br /&gt;
&lt;br /&gt;
[[html|Html Statement]]&lt;br /&gt;
&lt;br /&gt;
[[if...then...else|If...Then...Else Statement]]&lt;br /&gt;
&lt;br /&gt;
[[imp|Imp() Function]]&lt;br /&gt;
&lt;br /&gt;
[[inputbox|InputBox() Function]]&lt;br /&gt;
&lt;br /&gt;
[[instr/instrrev|Instr/InstrRev() Function]]&lt;br /&gt;
&lt;br /&gt;
[[int|Int() Function]]&lt;br /&gt;
&lt;br /&gt;
[[is (operator)|Is Operator]]&lt;br /&gt;
&lt;br /&gt;
[[is (function)|Is() Function]]&lt;br /&gt;
&lt;br /&gt;
[[javascript...end javascript|Javascript...End Javascript Statement]]&lt;br /&gt;
&lt;br /&gt;
[[join|Join() Function]]&lt;br /&gt;
&lt;br /&gt;
[[json.parse|Json.Parse() Function]]&lt;br /&gt;
&lt;br /&gt;
[[json.stringify|Json.Stringify() Function]]&lt;br /&gt;
&lt;br /&gt;
[[lbound|Lbound() Function]]&lt;br /&gt;
&lt;br /&gt;
[[lcase|Lcase() Function]]&lt;br /&gt;
&lt;br /&gt;
[[left|Left() Function]]&lt;br /&gt;
&lt;br /&gt;
[[len|Len() Function]]&lt;br /&gt;
&lt;br /&gt;
[[localstorage|LocalStorage Object]]&lt;br /&gt;
&lt;br /&gt;
[[location|Location Object]]&lt;br /&gt;
&lt;br /&gt;
[[log|Log() Function]]&lt;br /&gt;
&lt;br /&gt;
[[log10|Log10() Function]]&lt;br /&gt;
&lt;br /&gt;
[[ltrim|Ltrim() Function]]&lt;br /&gt;
&lt;br /&gt;
[[mid|Mid() Function]]&lt;br /&gt;
&lt;br /&gt;
[[minute|Minute() Function]]&lt;br /&gt;
&lt;br /&gt;
[[mod|Mod Operator]]&lt;br /&gt;
&lt;br /&gt;
[[month|Month() Function]]&lt;br /&gt;
&lt;br /&gt;
[[monthname|MonthName() Function]]&lt;br /&gt;
&lt;br /&gt;
[[msgbox|MsgBox() Function]]&lt;br /&gt;
&lt;br /&gt;
[[not|Not Operator]]&lt;br /&gt;
&lt;br /&gt;
[[now|Now Function]]&lt;br /&gt;
&lt;br /&gt;
[[nsbversion|NsbVersion Global]]&lt;br /&gt;
&lt;br /&gt;
[[NSB.InputBox|NSB.InputBox() Function]]&lt;br /&gt;
&lt;br /&gt;
[[nsb.msgbox|Nsb.MsgBox() Function]]&lt;br /&gt;
&lt;br /&gt;
[[nsb.showprogress|Nsb.ShowProgress() Function]]&lt;br /&gt;
&lt;br /&gt;
[[oct|Oct() Function]]&lt;br /&gt;
&lt;br /&gt;
[[or|Or Operator]]&lt;br /&gt;
&lt;br /&gt;
[[print|Print() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[properties and methods|Properties and Methods Control]]&lt;br /&gt;
&lt;br /&gt;
[[readfile|ReadFile() Function]]&lt;br /&gt;
&lt;br /&gt;
[[redim|Redim() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[rem|Rem() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[replace|Replace() Function]]&lt;br /&gt;
&lt;br /&gt;
[[rgb|Rgb() Function]]&lt;br /&gt;
&lt;br /&gt;
[[right|Right() Function]]&lt;br /&gt;
&lt;br /&gt;
[[rnd|Rnd Function]]&lt;br /&gt;
&lt;br /&gt;
[[round|Round() Function]]&lt;br /&gt;
&lt;br /&gt;
[[rtrim|Rtrim() Function]]&lt;br /&gt;
&lt;br /&gt;
[[second|Second() Function]]&lt;br /&gt;
&lt;br /&gt;
[[select case|Select Case() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[sessionstorage|SessionStorage Object]]&lt;br /&gt;
&lt;br /&gt;
[[set|Set() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[settimeout|SetTimeOut Function]]&lt;br /&gt;
&lt;br /&gt;
[[sgn|Sgn() Function]]&lt;br /&gt;
&lt;br /&gt;
[[sin|Sin() Function]]&lt;br /&gt;
&lt;br /&gt;
[[sleep|Sleep Statement]]&lt;br /&gt;
&lt;br /&gt;
[[sort|Sort() Function]]&lt;br /&gt;
&lt;br /&gt;
[[space|Space() Function]]&lt;br /&gt;
&lt;br /&gt;
[[split|Split() Function]]&lt;br /&gt;
&lt;br /&gt;
[[sql|Sql() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[sqlexport|SqlExport() Function]]&lt;br /&gt;
&lt;br /&gt;
[[sqlimport|SqlImport() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[sqlopendatabase|SqlOpenDataBase() Function]]&lt;br /&gt;
&lt;br /&gt;
[[sqr|Sqr() Function]]&lt;br /&gt;
&lt;br /&gt;
[[strcomp|StrComp() Function]]&lt;br /&gt;
&lt;br /&gt;
[[string|String() Function]]&lt;br /&gt;
&lt;br /&gt;
[[strreverse|StrReverse() Function]]&lt;br /&gt;
&lt;br /&gt;
[[sub|Sub() Statement]]&lt;br /&gt;
&lt;br /&gt;
[[sysinfo|SysInfo() Function]]&lt;br /&gt;
&lt;br /&gt;
[[tan|Tan() Function]]&lt;br /&gt;
&lt;br /&gt;
[[time|Time Function]]&lt;br /&gt;
&lt;br /&gt;
[[timeserial|TimeSerial() Function]]&lt;br /&gt;
&lt;br /&gt;
[[timevalue|TimeValue() Function]]&lt;br /&gt;
&lt;br /&gt;
[[trim|Trim() Function]]&lt;br /&gt;
&lt;br /&gt;
[[try...catch|Try...Catch Statement]]&lt;br /&gt;
&lt;br /&gt;
[[typename|TypeName() Function]]&lt;br /&gt;
&lt;br /&gt;
[[ubound|Ubound() Function]]&lt;br /&gt;
&lt;br /&gt;
[[ucase|Ucase() Function]]&lt;br /&gt;
&lt;br /&gt;
[[vartype|VarType() Function]]&lt;br /&gt;
&lt;br /&gt;
[[waitcursor|WaitCursor Statement]]&lt;br /&gt;
&lt;br /&gt;
[[weekday|Weekday() Function]]&lt;br /&gt;
&lt;br /&gt;
[[weekdayname|WeekdayName() Function]]&lt;br /&gt;
&lt;br /&gt;
[[with...end with|With...End With Statement]]&lt;br /&gt;
&lt;br /&gt;
[[while...wend|While...Wend Statement]]&lt;br /&gt;
&lt;br /&gt;
[[xor|Xor Operator]]&lt;br /&gt;
&lt;br /&gt;
[[year|Year() Function]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Controls ==&lt;br /&gt;
&lt;br /&gt;
[[adsense|Adsense All]]&lt;br /&gt;
&lt;br /&gt;
[[audio|Audio All]]&lt;br /&gt;
&lt;br /&gt;
[[button|Button All]]&lt;br /&gt;
&lt;br /&gt;
[[buttonbar|ButtonBar iWebKit]]&lt;br /&gt;
&lt;br /&gt;
[[checkbox|CheckBox All]]&lt;br /&gt;
&lt;br /&gt;
[[combobox|ComboBox iWebKit]]&lt;br /&gt;
&lt;br /&gt;
[[date, datetime|Date, DateTime All]]&lt;br /&gt;
&lt;br /&gt;
[[facebook|Facebook All]]&lt;br /&gt;
&lt;br /&gt;
[[fliptoggle|FlipToggle jQuery]]&lt;br /&gt;
&lt;br /&gt;
[[footerbar|Footerbar jQuery]]&lt;br /&gt;
&lt;br /&gt;
[[grid|Grid All]]&lt;br /&gt;
&lt;br /&gt;
[[headerbar|HeaderBar jQuery]]&lt;br /&gt;
&lt;br /&gt;
[[htmlview|HtmlView All]]&lt;br /&gt;
&lt;br /&gt;
[[image|Image All]]&lt;br /&gt;
&lt;br /&gt;
[[label|Label All]]&lt;br /&gt;
&lt;br /&gt;
[[list|List jQuery]]&lt;br /&gt;
&lt;br /&gt;
[[menu|Menu iWebKit]]&lt;br /&gt;
&lt;br /&gt;
[[menunumbertitledescarrow|MenuNumberTitleDescArrow iWebKit]]&lt;br /&gt;
&lt;br /&gt;
[[menunumbertitletime|MenuNumberTitleTime iWebKit]]&lt;br /&gt;
&lt;br /&gt;
[[menutextblock|MenuTextBlock iWebKit]]&lt;br /&gt;
&lt;br /&gt;
[[Month (C)|Month All]]&lt;br /&gt;
&lt;br /&gt;
[[multiinput|MultiInput iWebKit]]&lt;br /&gt;
&lt;br /&gt;
[[navbar|NavBar jQuery]]&lt;br /&gt;
&lt;br /&gt;
[[paypal|Paypal All]]&lt;br /&gt;
&lt;br /&gt;
[[PictureBox|PictureBox All]]&lt;br /&gt;
&lt;br /&gt;
[[PopUp|PopUp jQuery]]&lt;br /&gt;
&lt;br /&gt;
[[radiobutton|RadioButton All]]&lt;br /&gt;
&lt;br /&gt;
[[select|Select jQuery]]&lt;br /&gt;
&lt;br /&gt;
[[slider|Slider All]]&lt;br /&gt;
&lt;br /&gt;
[[textarea|TextArea All]]&lt;br /&gt;
&lt;br /&gt;
[[textbox|TextBox All]]&lt;br /&gt;
&lt;br /&gt;
[[time (C)|Time All]]&lt;br /&gt;
&lt;br /&gt;
[[titlebar|TitleBar iWebKit]]&lt;br /&gt;
&lt;br /&gt;
[[ToolTip|ToolTip jQuery]]&lt;br /&gt;
&lt;br /&gt;
[[twitter|Twitter All]]&lt;br /&gt;
&lt;br /&gt;
[[video|Video All]]&lt;br /&gt;
&lt;br /&gt;
== Objects ==&lt;br /&gt;
&lt;br /&gt;
[[body|body]]&lt;br /&gt;
&lt;br /&gt;
[[document|document]]&lt;br /&gt;
&lt;br /&gt;
[[element|element]]&lt;br /&gt;
&lt;br /&gt;
[[event|event]]&lt;br /&gt;
&lt;br /&gt;
[[geolocation|geolocation]]&lt;br /&gt;
&lt;br /&gt;
[[navigator|navigator]]&lt;br /&gt;
&lt;br /&gt;
[[style|style]]&lt;br /&gt;
&lt;br /&gt;
[[window|window]]&lt;br /&gt;
&lt;br /&gt;
== Other ==&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=EXE.pythonEval&amp;diff=7538</id>
		<title>EXE.pythonEval</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=EXE.pythonEval&amp;diff=7538"/>
		<updated>2015-08-10T20:27:49Z</updated>

		<summary type="html">&lt;p&gt;Admin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;EXE.pythonEval(&#039;&#039;code&#039;&#039;[, &#039;&#039;callback&#039;&#039;])&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
EXE.pythonEval executes code in the EXE runtime wrapper. It only works in EXE apps. AppStudio&#039;s EXE apps work by wrapping your app in a executable wrapper which is written in Python. This function requires you to know Python to use it.&lt;br /&gt;
&lt;br /&gt;
Code has to be properly formatted Python code, following all Python syntax rules. In addition to the base Python language, the following libraries can be used:&lt;br /&gt;
* os&lt;br /&gt;
* wx&lt;br /&gt;
* jason&lt;br /&gt;
* yaml&lt;br /&gt;
&lt;br /&gt;
Other may be included in a future release.&lt;br /&gt;
&lt;br /&gt;
Calls to EXE.pythonEval are processed asynchronously. To return values, put {callback}(value) in your code, and supply the name of the function you want called as &#039;&#039;callback&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
== Example (BASIC) ==&lt;br /&gt;
&lt;br /&gt;
Do a simple calculation and return the result&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
EXE.pythonEval(&amp;quot;{callback}(4*4)&amp;quot;, &amp;quot;showResult&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
Function showResult(res)&lt;br /&gt;
  MsgBox res&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
EXE.pythonEval(&amp;quot;{callback}(4*4)&amp;quot;, &amp;quot;showResult&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
function showResult(res) {&lt;br /&gt;
    NSB.MsgBox(res);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other examples ==&lt;br /&gt;
&lt;br /&gt;
Exit the app&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
EXE.pythonEval(&amp;quot;sys.exit(0)&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Put up a wx Message Box:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
EXE.pythonEval(&amp;quot;wx.MessageBox(&#039;It works!&#039;, &#039;Info&#039;, wx.OK | wx.ICON_INFORMATION)&amp;quot;, &amp;quot;MessageBox&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Run a code snippet&lt;br /&gt;
&lt;br /&gt;
Put the following code into a TextArea:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Code must be in Python.&lt;br /&gt;
# note how to return results.&lt;br /&gt;
a=64&lt;br /&gt;
{callback}(a*a)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And execute it as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;EXE.pythonEval(TextArea1.value, &amp;quot;showResult&amp;quot;)&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Version_5&amp;diff=7537</id>
		<title>Version 5</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Version_5&amp;diff=7537"/>
		<updated>2015-08-10T20:26:24Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Version 5.0.13 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;If you own a previous version of AppStudio, you need to buy the upgrade to use Version 5. You can do this from within the app or from our [http://www.nsbasic.com/order.shtml order form.] &lt;br /&gt;
&lt;br /&gt;
Until you have bought the upgrade, you can use AppStudio 5 in Demo mode. Once you buy, your copy will convert automatically to the full version.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.15 ==&lt;br /&gt;
# Controls: [[Line]] bounds are now grouped.&lt;br /&gt;
# Controls: [[RadioButton]] width is now in the right place in the Property Window.&lt;br /&gt;
# [[Form|Forms]]: jQuery Mobile theme can now be set on a form.&lt;br /&gt;
# Localization: Files updated. Indonesian is now complete.&lt;br /&gt;
# [[Make Windows Executables|MakeEXE]]: Better messages and wait cursor.&lt;br /&gt;
# [[Make Windows Executables|MakeEXE]]: Debug window no longer appears.&lt;br /&gt;
# [[Make Windows Executables|MakeEXE]]: Windows Shell commands can now be executed.&lt;br /&gt;
# Samples: Possible error fixed when opening samples picker.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.14 ==&lt;br /&gt;
# Code Window: Don&#039;t case correct &amp;quot;parse&amp;quot;&lt;br /&gt;
# Controls: Add corner property to [[TextArea]], [[TextBox]].&lt;br /&gt;
# Controls: Allow multiline style properties&lt;br /&gt;
# Controls: Eliminate default text-shadow on TextArea, TextBox&lt;br /&gt;
# Controls: Enable theme support for TextArea, TextBox.&lt;br /&gt;
# Controls: Make [[Container]] Responsive Design aware.&lt;br /&gt;
# Controls: Redo how TextBox is created. &lt;br /&gt;
# Controls: [[RadioButton]] horizontal in a [[Container]] fixed.&lt;br /&gt;
# [[Make Windows Executables|MakeEXE]]: return error if evalPython fails.&lt;br /&gt;
# Samples: Add Globalization plugin to PhoneGapAPI sample.&lt;br /&gt;
# Samples: Add some folder descriptions.&lt;br /&gt;
# Translator: Fix a false negative.&lt;br /&gt;
# Translator: Fix bad translate of &#039;emptyData&#039;&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.13 ==&lt;br /&gt;
# Controls: Style and Class properties should work for all controls.&lt;br /&gt;
# Controls: [[Container|Containers]] cannot be nested.&lt;br /&gt;
# Controls: [[Grid]].addRows(), addCols() add one each if no arg.&lt;br /&gt;
# [[Code Window]]: Do not capitalize style.&lt;br /&gt;
# Setup: Get Info for Windows now shows all data.&lt;br /&gt;
# Sample: Fixes to Background, Sprite, LabRotation&lt;br /&gt;
# IDE: Problem opening projects with code files fixed. (like upload.nsx)&lt;br /&gt;
# IDE: Projects cannot be saved with illegal file names.&lt;br /&gt;
# MakeEXE: New [[windowStyle]] property.&lt;br /&gt;
# MakeEXE: New [[EXE.pythonEval]]() function.&lt;br /&gt;
# MakeEXE: new execPython sample.&lt;br /&gt;
# Properties Windows: return takes you to the next property.&lt;br /&gt;
# Docs: Locale files updated.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.12 ==&lt;br /&gt;
# Samples: All samples now have BASIC and JavaScript versions.&lt;br /&gt;
# Samples: new jPlayer streaming video sample (Thanks, Adrian!)&lt;br /&gt;
# Samples: new ResponsiveRotation sample.&lt;br /&gt;
# Build: Fix Mac OS &#039;Get Info&#039; data.&lt;br /&gt;
# Controls: Don&#039;t set button margin to 0 if position is relative.&lt;br /&gt;
# StyleHeaders: Process last, so its rules have precedence.&lt;br /&gt;
# StyleHeaders: Update Design Screen on close.&lt;br /&gt;
# Translater: Fix &#039;else&#039; embedded in variable name.&lt;br /&gt;
# Translator: Fix regular expression error in array/function.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.11 ==&lt;br /&gt;
# Controls: Add min, max values to [[Date, DateTime|Date]] Pickers - speeds up Android.&lt;br /&gt;
# Controls: Allow vh, vw sizes (viewport height, viewport width)&lt;br /&gt;
# Controls: Fix error in jqWidgets [[JqxTabs|Tabs]] control.&lt;br /&gt;
# Controls: [[NavBar]], [[Footerbar|FooterBar]]: All spaces are now converted to underscores for event argument.&lt;br /&gt;
# Controls: NavBar, FooterBar: Design time style now used at runtime.&lt;br /&gt;
# Deploy: Get project path to jqWidgets correctly.&lt;br /&gt;
# [[Form]]: Default form height is now 100vh.&lt;br /&gt;
# Make EXE: Unicode characters are now allowed.&lt;br /&gt;
# PhoneGap Build Status: Improve iOS message.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.10 ==&lt;br /&gt;
# [[Design Screen]]: Error when deleting control in a Container fixed.&lt;br /&gt;
# Samples: New sample using [http://www.chartjs.org/ Chartjs] library.&lt;br /&gt;
# Controls: [[Grid]] cellstyle property used when adding new rows.&lt;br /&gt;
# Controls: Make a number of controls behave better when using [[Responsive Design Made Simple|Responsive Design]].&lt;br /&gt;
# jqWidgets: The path to the jqWidgets controls is now a Project Property.&lt;br /&gt;
# Controls: Formatting of [[NSB.MsgBox]] improved.&lt;br /&gt;
# Script Window: Allow other windows to be edited.&lt;br /&gt;
&lt;br /&gt;
Breaking change:&lt;br /&gt;
# if you are using a local copy of jqWidgets, you need to set pathTo_jqWidgets in Project Properties.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.9 ==&lt;br /&gt;
# [[Code Window]]: Much faster. Lag between keystrokes eliminated.&lt;br /&gt;
# Script Window: Lets you display code, but no longer to modify it.&lt;br /&gt;
# [[Modal Forms]]: Overlay parameter fixed.&lt;br /&gt;
# [[Design Screen]]: CSS files work again.&lt;br /&gt;
# Samples: New OpenStreetMaps/Leaflet sample (Thanks, Adrian!)&lt;br /&gt;
# Controls: Tune [[Footerbar]] defaults.&lt;br /&gt;
# Controls: [[List]] control had a problem with empty list.&lt;br /&gt;
# Code Window: Function tips work consistently.&lt;br /&gt;
# Documentation: Offline Wiki files updated.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.8 ==&lt;br /&gt;
# [[Design Screen]]: Adding controls is now more than twice as fast.&lt;br /&gt;
# [[Project Explorer]]: Moving controls up and down about 8 times faster.&lt;br /&gt;
# [[Code Window]]: Intellisense for user functions much, much faster.&lt;br /&gt;
# [[ServerStorage]]: Docs for installing on your own server [https://github.com/artlogic/server-storage/blob/master/README.md are now available].&lt;br /&gt;
# Controls: [[jqxGrid]] now handles % heights properly.&lt;br /&gt;
# Design Screen: Copy and Paste of [[Container|Containers]] fixed.&lt;br /&gt;
# Design Screen: Zero value for designHeight, DesignWidth fixed.&lt;br /&gt;
# Project Explorer: Dragging and dropping sound files fixed.&lt;br /&gt;
# Design Screen: Scrollbar no longer appears when fullscreen is false.&lt;br /&gt;
# Controls: [[Select]] no longer shows gray circle for custom icon.&lt;br /&gt;
# Samples: New Swipe sample. (Thanks, Mike Burgher!)&lt;br /&gt;
# Localization: Thai is complete. (Thanks, Theprasit S.!)&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.7  ==&lt;br /&gt;
# Deploy: A message now appears if errors are encountered at runtime.&lt;br /&gt;
# Project Properties: New stopOnError property to hide runtime error messages.&lt;br /&gt;
# Controls: [[NSB.MsgBox|MsgBox]] appearance improved.&lt;br /&gt;
# [[Form|Forms]]: Modal forms now have onhide and onshow events.&lt;br /&gt;
# EXE Files: Put on Start menu, not Startup files list.&lt;br /&gt;
# [[Code Window|Code Window:]] False negative on location = fixed.&lt;br /&gt;
# DropBox: [[Using a Dropbox Datastore|DataStore API]] is being [https://blogs.dropbox.com/developers/2015/04/deprecating-the-sync-and-datastore-apis/ deprecated by DropBox].&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.6 ==&lt;br /&gt;
# EXE files: Icon handling improved.&lt;br /&gt;
# Forms: Bounds now in a group&lt;br /&gt;
# Forms: Bounds can now be percent, &amp;quot;auto&amp;quot; or a value.&lt;br /&gt;
# Deploy: Code is only minimized when requested.&lt;br /&gt;
# Design Screen: extra time during startup allowed for.&lt;br /&gt;
# Controls: Minor path error in [[JqxDateTimeInput|jqxDateTimeInput]] fixed.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.5 ==&lt;br /&gt;
# EXE files: Support added for localStorage.&lt;br /&gt;
# EXE files: new properties for publisher, icon, title, height and width.&lt;br /&gt;
# EXE files: now run as a localServer&lt;br /&gt;
# Controls: jqxGrid was not initiated properly in jqWidgets 3.8.&lt;br /&gt;
# Deploy: fix encoding mode on LaunchIcon57.png.&lt;br /&gt;
# Deploy: jsmin fixed.&lt;br /&gt;
# jQuery: updated to 2.1.4&lt;br /&gt;
# Properties Window: Properties now have groups.&lt;br /&gt;
# Properties Window: Borders, Bounds, Fonts are grouped.&lt;br /&gt;
# Properties: for Chrome Packaged Apps removed.&lt;br /&gt;
# Samples: Grid sample cellrenderer fixed for jqWidgets 3.8.&lt;br /&gt;
# ToolBox: Function list was sometimes not refreshing.&lt;br /&gt;
# Translator: add some semicolons&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.4 ==&lt;br /&gt;
# jqWidgets: Library conflict caused by jqWidgets 3.8 fixed.&lt;br /&gt;
# Samples: new PhoneGapFileSystem sample.&lt;br /&gt;
# Languages: locale files updated.&lt;br /&gt;
# Native Build Status: now shows a wait cursor.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.3 ==&lt;br /&gt;
# Deploy: Don&#039;t create manifest file if no caching.&lt;br /&gt;
# Deploy: PhoneGap CLI remembers to create config.xml&lt;br /&gt;
# Samples: new VisualEffects sample.&lt;br /&gt;
# Samples: several updates.&lt;br /&gt;
# Translator: Problems with Functions fixed.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.2 ==&lt;br /&gt;
# Check for Update: Set up text for translation.&lt;br /&gt;
# Controls: Allow multiple entries for [[ChangeForm]] where needed.&lt;br /&gt;
# Controls: [[jqxEditor]] control now has grab handles in Design Screen for resizing.&lt;br /&gt;
# Controls: [[Panel]] - Fix how it appears on Design Screen. Remove unused properties.&lt;br /&gt;
# Controls: [[jqxTabs]] control now appears properly.&lt;br /&gt;
# Deploy: &#039;no cache&#039; option added to Manifest File property.&lt;br /&gt;
# [[Form|Forms]]: Improved reset() function. Thanks, Buck!&lt;br /&gt;
# Internal: Went back to wxPython 2.9.5 to solve problem with Spanish locale.&lt;br /&gt;
# [[Make Windows Executables|Make EXE]]: correct delete file command in make script.&lt;br /&gt;
# Make EXE: Force a save before making exe.&lt;br /&gt;
# Samples: Update and rename ModalForm.&lt;br /&gt;
# Translation: Fix some tab characters.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.1 ==&lt;br /&gt;
# [[Code Window]]: Format code problem fixed.&lt;br /&gt;
# Deploy: Adding/deleting files to [[Project Explorer]] forces full Deploy.&lt;br /&gt;
# Deploy: Don&#039;t change name of file when deploying.&lt;br /&gt;
# Deploy: Fix formatting error in manifest.&lt;br /&gt;
# Deploy: Warn users of spaces in file names.&lt;br /&gt;
# [[Form|Forms]]: .reset() function is back.&lt;br /&gt;
# IDE: [[Design Screen]] now checks for Internet Explorer 11.&lt;br /&gt;
# Internals: pyExecJS not needed.&lt;br /&gt;
# [[Make Windows Executables|Make exe]]: All needed folders are now included.&lt;br /&gt;
# Run menu: Replace &amp;quot;Make Desktop App&amp;quot; with &#039;[[Make Windows Executables|Make exe&#039;]].&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.0 ==&lt;br /&gt;
&lt;br /&gt;
===Major New Features===&lt;br /&gt;
# [[Responsive Design Made Simple|Responsive Design]] lets your app adapt smoothly to different screen sizes.&lt;br /&gt;
# [[Make Windows Executables]] (exe) apps.&lt;br /&gt;
# Ten new controls, including [[Container]], [[Collapsible]], [[jqxEditor|Editor]], [[JqxEditor|Password]] Input and [[jqxWindow|Window]].&lt;br /&gt;
# Use [[ChangeForm|Visual Effects]] to show forms.&lt;br /&gt;
# Use [[Modal Forms]]&lt;br /&gt;
# Internet Explorer 11 support.&lt;br /&gt;
&lt;br /&gt;
===IDE - General===&lt;br /&gt;
# New look and feel for the IDE&lt;br /&gt;
# Tools Menu: New option to convert a BASIC project to JavaScript.&lt;br /&gt;
# [[Open Sample Dialog|Open Sample]]: Now allows nested folders, for better organization&lt;br /&gt;
# [[Open Sample Dialog|Open Sample]]: New Find option.&lt;br /&gt;
# [[About Screen]]: reformatted.&lt;br /&gt;
# Find: Opens with &amp;quot;Find What&amp;quot; selected.&lt;br /&gt;
# Help: now displays HTML formatted text with links.&lt;br /&gt;
# [[Open Sample Dialog|Open Sample]]: Samples are now sorted case insensitively.&lt;br /&gt;
# [[Properties Window|Project Properties]]: New styleheader property saves your styling rules.&lt;br /&gt;
# [[Properties Window]]: ChangeForm and firstform now have pickers.&lt;br /&gt;
# Properties Window: Events set properly on control copy and paste.&lt;br /&gt;
# Run menu: New [[Make Windows Executables]] (exe) App.&lt;br /&gt;
# Run menu: Improved menu names.&lt;br /&gt;
# Save: Saving a project no longer changes the Project ID.&lt;br /&gt;
# Startup: Projects with deprecated controls will get a message when loading is attempted.&lt;br /&gt;
# Startup: Splash screen on Mac OS startup no longer required.&lt;br /&gt;
# Startup: When project reopened, tabs are all reopened and same one returned to.&lt;br /&gt;
# View menu: New option to close all tabs.&lt;br /&gt;
# Installer: Checks if IE11 is installed on Windows&lt;br /&gt;
# Installer: Modifies registry so IE11 recognizes AppStudio.&lt;br /&gt;
&lt;br /&gt;
===Code Window===&lt;br /&gt;
# [[Code Window|Code Window:]] New clickable Function List appears in the Toolbox pane.&lt;br /&gt;
# Code Window: ToolTips now appear for user functions.&lt;br /&gt;
# Code Window: &#039;error&#039; is no longer auto capitalized.&lt;br /&gt;
# Code Window: Code converted to JS is now beautified.&lt;br /&gt;
# Code Window: Error when typing &#039;screen.&#039; fixed.&lt;br /&gt;
# Code Window: JSONP files are now edited as JSON files.&lt;br /&gt;
# Code Window: Problem with auto indentation fixed.&lt;br /&gt;
&lt;br /&gt;
===Design Screen===&lt;br /&gt;
# [[Design Screen]]: controls are relative if their parent is.&lt;br /&gt;
# Design Screen: new zoom icon. Use this to shrink size of Design Screen. Disables drag and drop.&lt;br /&gt;
# Design Screen: controls can be grouped using [[Container|Containers]].&lt;br /&gt;
# Design Screen: Right click to lock controls from accidental position changes.&lt;br /&gt;
# Design Screen: Double click opens [[Code Window]].&lt;br /&gt;
# Design Screen: Dump wxWebkit. Now smaller, faster.&lt;br /&gt;
# Design Screen: Internally uses IE to render controls.&lt;br /&gt;
# Design Screen: Paste now shows on the right click menu.&lt;br /&gt;
# Design Screen: Snap to grid is now gray, not black.&lt;br /&gt;
&lt;br /&gt;
===Project Explorer===&lt;br /&gt;
# Project Explorer: Folders can now be dragged and dropped.&lt;br /&gt;
# Project Explorer: JSON files can now be dragged and dropped.&lt;br /&gt;
# Project Explorer: SQLite databases can now be dragged and dropped.&lt;br /&gt;
# [[Project Explorer]]: Delete file now has confirmation message.&lt;br /&gt;
# Project Explorer: Warning if drag and drop of existing file.&lt;br /&gt;
&lt;br /&gt;
===Language===&lt;br /&gt;
# [[ChangeForm]]() now supports visual effects.&lt;br /&gt;
# [[Ajax]]() can now have a callback as a second argument.&lt;br /&gt;
# Ajax() can now take an object for its parameters.&lt;br /&gt;
# Ajax() now supports a fail callback.&lt;br /&gt;
# [[ReadFile]]() can now be used asynchronously.&lt;br /&gt;
# Case normalization is now handled in Code Window&lt;br /&gt;
# Case normalization moved out of hfunc.js, killing hundreds of lines of code.&lt;br /&gt;
# Language version bumped. Existing projects will take longer to compile first time they are run using the new version.&lt;br /&gt;
# Map is now a keyword.&lt;br /&gt;
# Overlay() function deleted - it was obsolete.&lt;br /&gt;
# Referencing a control by name itself will return its value.&lt;br /&gt;
# Referencing a control by name will return a numeric if possible.&lt;br /&gt;
# [[Style/End Style]] deprecated. See &#039;Breaking Changes&#039;.&lt;br /&gt;
# [[NSBCurrentForm]] changed to NSB.currentForm.&lt;br /&gt;
# Arrays no longer have to be declared in all modules.&lt;br /&gt;
&lt;br /&gt;
===Toolbox===&lt;br /&gt;
# New: [[Container]] control for text, html and other controls.&lt;br /&gt;
# All: New [[Properties and Methods|methods]] to hide and show controls: fadeIn, fadeOut, slideUp, slideDown.&lt;br /&gt;
# All: Updated to work with IE11.&lt;br /&gt;
# All: -webkit prefix removed from css.&lt;br /&gt;
# All: Border [[properties]] are now consistant.&lt;br /&gt;
# All: BorderColor and BorderWidth added all controls with borders.&lt;br /&gt;
# All: Bounds can now be &#039;inherit&#039; and &#039;initial&#039;.&lt;br /&gt;
# All: Disabled property fixed.&lt;br /&gt;
# All: font selectors normalized.&lt;br /&gt;
# All: HTML output for borders streamlined.&lt;br /&gt;
# All: New onresize [[events|event]].&lt;br /&gt;
# All: no longer load function code that is not needed.&lt;br /&gt;
# All: [[ToolBox Files|ToolBox Files]] can now share property definitions.&lt;br /&gt;
# [[Camera]]: value can now be set at Design Time.&lt;br /&gt;
# [[Date, DateTime|Date and Time]]: appearance improved.&lt;br /&gt;
# Dialog is now on top of scroll bars.&lt;br /&gt;
# [[Facebook]]: unneeded font property removed.&lt;br /&gt;
# Functions for AppStudio&#039;s controls moved from complexfunctions.js to nsbFunctions.js.&lt;br /&gt;
# Functions for jqMobile controls moved from complexfunctions.js to jqmFunctions.js.&lt;br /&gt;
# Functions for jqWidget controls moved from complexfunctions.js to jqxFunctions.js.&lt;br /&gt;
# [[Generic]]: Deprecated - replaced by Container.&lt;br /&gt;
# [[Grid]]: .cellstyle can be read at runtime.&lt;br /&gt;
# Grid: .colWidths can be read at runtime.&lt;br /&gt;
# Grid: Cells added at runtime are formatted with cellstyle.&lt;br /&gt;
# Grid: fix alignment style bug on first column.&lt;br /&gt;
# Grid: styling moved from complexfunctions to nsbstyle.css.&lt;br /&gt;
# Help now has pointers to Wiki.&lt;br /&gt;
# [[HTMLView|HTMLView]]: Emitted code improved.&lt;br /&gt;
# HTMLView: fix warning from Safari.&lt;br /&gt;
# HTMLView: Percentage widths fixed.&lt;br /&gt;
# [[NSB.MsgBox]]: Appearance improved on RTL systems.&lt;br /&gt;
# NSB.MsgBox: formatting error with two buttons fixed.&lt;br /&gt;
# NSB.MsgBox: iOS 6 style MsgBoxes are gone.&lt;br /&gt;
# NSB.MsgBox: now handles former _msgbox_confirm function.&lt;br /&gt;
# [[NSB.ShowProgress]] is now modal.&lt;br /&gt;
# [[PayPal]]: Allows user specified image.&lt;br /&gt;
# PayPal: Only deploy image which is used, not all four.&lt;br /&gt;
# [[Toolbox]]: Now has a Find area on the bottom.&lt;br /&gt;
# Toolbox: Right click now opens Wiki page for all controls.&lt;br /&gt;
&lt;br /&gt;
===Forms===&lt;br /&gt;
# New [[Modal Forms|modal]] property: can make form float modally over rest of app.&lt;br /&gt;
# New visual effects: fadeIn, fadeOut, slideUp, slideDown.&lt;br /&gt;
# New BackgroundColor property.&lt;br /&gt;
# New BorderColor property.&lt;br /&gt;
# New BorderWidth property.&lt;br /&gt;
# New parentForm property.&lt;br /&gt;
#  New position property. Can be absolute, fixed, etc. Good for [[Responsive Design Made Simple|Responsive Design]].&lt;br /&gt;
# Background renamed backgroundImage.&lt;br /&gt;
# Borders can be specified.&lt;br /&gt;
# Controls copy and pasted to new forms are not repositioned.&lt;br /&gt;
# Form submit properties removed from Toolbox.&lt;br /&gt;
# Forms are now a &amp;amp;lt;div&amp;gt; element, not &amp;amp;lt;form&amp;gt;&lt;br /&gt;
# Forms can now have bounds in percentages (if fullScreen is false).&lt;br /&gt;
&lt;br /&gt;
===Runtime===&lt;br /&gt;
# Comments between forms added to output code.&lt;br /&gt;
# Indenting of code improved.&lt;br /&gt;
# Main div renamed to NSBPage from Page_jqm.&lt;br /&gt;
# Needless blank lines removed.&lt;br /&gt;
# Output code cleaned up.&lt;br /&gt;
# Return value of function renamed returnValue (was savethefunction_rval)&lt;br /&gt;
# ReturnValue code not created if function does not return a value.&lt;br /&gt;
# CSS files moved to head for faster rendering.&lt;br /&gt;
# Generated code reformatted by JSBeautifier when possible.&lt;br /&gt;
&lt;br /&gt;
===Deploy===&lt;br /&gt;
# Option to create Windows Executable (exe) added to Run menu.&lt;br /&gt;
# Nicely formatted screen listing your deployed apps.&lt;br /&gt;
# Native Build Status: Starts automatically after build and auto refreshes.&lt;br /&gt;
# Drag and Drop to Project Explorer fills manifest automatically.&lt;br /&gt;
# Cache: error message improved.&lt;br /&gt;
# Cache: Mime types set on local server - Some Windows systems set incorrectly.&lt;br /&gt;
# Cache: New global [[NSB.cacheStatus]] is available to your app.&lt;br /&gt;
# Cache: User now prompted before web app is updated.&lt;br /&gt;
# Cache: To turn off update prompt, do NSB.confirmCacheUpdate=&amp;quot;&amp;quot;&lt;br /&gt;
# [[Menu Options|Check Deployment]]: Additional checking added.&lt;br /&gt;
# [[Build Native App|Native Build Status]]: Auto refresh every 3 seconds.&lt;br /&gt;
# Native Build Status: Links added for iOS &#039;Error&#039; message.&lt;br /&gt;
# Native Build Status: Links added to Tech Note for app stores.&lt;br /&gt;
# Native Build Status: Refresh button deleted.&lt;br /&gt;
# Native Build Status: Opens automatically after app submitted to PhoneGap.&lt;br /&gt;
# nsbapp.com: User image in nsb caused problems uploading to nsbapp.com fixed.&lt;br /&gt;
# [[PhoneGap CLI|PhoneGap]]: CLI progress window can now be closed.&lt;br /&gt;
# PhoneGap: Config.xml no longer gets deployed (It&#039;s only for PhoneGap)&lt;br /&gt;
# PhoneGap: Default configxml updated.&lt;br /&gt;
# PhoneGap: New PhoneGap Camera sample.&lt;br /&gt;
# PhoneGap: Project Location build uses [[PhoneGap AuthToken|AuthToken]].&lt;br /&gt;
# PhoneGap: [[SplashScreens|Splashscreen]] is now automatically added to manifest.&lt;br /&gt;
# PhoneGap: splashscreen property now uses image picker.&lt;br /&gt;
# PHP: Umlauts (and other extended characters) are now OK in PHP files.&lt;br /&gt;
# [[Preferences]]: Static localhost port# added.&lt;br /&gt;
# [[Project Explorer]]: Entire folders can be dragged and dropped. &lt;br /&gt;
# Project Explorer: JSON files can be dragged and dropped for deploy.&lt;br /&gt;
# Project Explorer: SQLite databases can be dragged and dropped for deploy.&lt;br /&gt;
# Run: from local filesystem uses default browser.&lt;br /&gt;
# Run: Local deploy is to 127.0.0.1 instead of localhost to deal with poorly configured systems.&lt;br /&gt;
# Run: Local deploy pathnames can now have spaces.&lt;br /&gt;
&lt;br /&gt;
===jQuery Mobile Framework===&lt;br /&gt;
# New: [[Collapsible]] control shows popup text.&lt;br /&gt;
# All: Toolbox files tweaked for proper display in IE11.&lt;br /&gt;
# All: jQuery Mobile 1.3 controls and samples have been removed.&lt;br /&gt;
# [[Button]], [[List]]: Text appearance improved.&lt;br /&gt;
# [[Button]]: Groups now have ID numbers.&lt;br /&gt;
# Icons now draw more sharply.&lt;br /&gt;
# [[Panel]]: icon now drawn correctly.&lt;br /&gt;
# [[Select]]: addItem can now accept multiple items&lt;br /&gt;
# [[TextArea]]: Added maxlength property.&lt;br /&gt;
&lt;br /&gt;
===jqWidgets Framework===&lt;br /&gt;
# New: [[jqxDateTimeInput|DateTimeInput]] control.&lt;br /&gt;
# New: [[jqxDocking|Docking]] control.&lt;br /&gt;
# New: [[jqxEditor|Editor]] control.&lt;br /&gt;
# New: [[jqxMaskedInput|MaskedInput]] control.&lt;br /&gt;
# New: [[jqxNavigationBar|NavigationBar]] control.&lt;br /&gt;
# New: [[jqxPasswordInput|PasswordInput]] control.&lt;br /&gt;
# New: [[jqxValidator|Validator]] control.&lt;br /&gt;
# New: [[jqxWindow|Window]] control.&lt;br /&gt;
# New themes: Android, Web, Bootstrap, Metro and Office.&lt;br /&gt;
# All: controls now have hidden, disabled, theme and rtl properties.&lt;br /&gt;
# All: Design settings are available at runtime in the NSB.jqxSettings[id] array.&lt;br /&gt;
# All: Functions for jqx controls moved from complexfunctions.js to jqxFunctions.js.&lt;br /&gt;
# All: Remove jqxSettings_ variables from global namespace. Now in NSB.jqxSettings[&amp;quot;controlName&amp;quot;]&lt;br /&gt;
# All: Toolbox files have been streamlined.&lt;br /&gt;
# [[jqxCheckBox|Checkbox]]: Icon updated.&lt;br /&gt;
# [[JqxMenu|Menu]]: wrong height on pulldown fixed.&lt;br /&gt;
# Samples: Numerous fixes to samples.&lt;br /&gt;
&lt;br /&gt;
===iWebKit Framework===&lt;br /&gt;
# All iWebKit controls and samples have been removed.&lt;br /&gt;
&lt;br /&gt;
=== Samples ===&lt;br /&gt;
# Samples can be searched for keywords.&lt;br /&gt;
# Samples are now organized into subdirectories.&lt;br /&gt;
# New [[Collapsible|Collapsable]] sample.&lt;br /&gt;
# New [[Modal Forms|Modal]] form sample.&lt;br /&gt;
# New PhoneGap Camera sample.&lt;br /&gt;
# New samples for all the new jqWidgets controls.&lt;br /&gt;
# All samples updated to use the new release.&lt;br /&gt;
# Desktop files for [[WebSockets]] samples moved to Wiki in zip format.&lt;br /&gt;
# Fix incorrect default splashscreen paths.&lt;br /&gt;
# Many updates and fixes.&lt;br /&gt;
# Update Ajax samples to use asynchronous calls.&lt;br /&gt;
&lt;br /&gt;
=== Documentation ===&lt;br /&gt;
# TechNotes: New [[Responsive Design Made Simple]]&lt;br /&gt;
&lt;br /&gt;
=== Internals ===&lt;br /&gt;
# Internals: PyV8 no longer used.&lt;br /&gt;
# Internals: wxWebkit is no longer used.&lt;br /&gt;
# Internals: wxPython updated to 3.0.0.&lt;br /&gt;
# Internals: node.js now now used for translation and syntax checking.&lt;br /&gt;
# Internals: PyInstaller is now used to create Mac installer instead of Py2App.&lt;br /&gt;
# Internals: Complexfunctions and hfunc cleaned up using jshint.&lt;br /&gt;
# Internals: Complexfunctions and hfunc reformatted.&lt;br /&gt;
# Internals: hfunc and functions files minified.&lt;br /&gt;
# Internals: exception handling improved.&lt;br /&gt;
# Internals: FastClick updated to 1.0.6&lt;br /&gt;
&lt;br /&gt;
==Breaking Changes==&lt;br /&gt;
# Windows XP and Vista are no longer supported, due to IE 11&#039;s minimum requirements. Microsoft is no longer issuing security patches for XP. http://windows.microsoft.com/en-ca/windows/end-support-help&lt;br /&gt;
# Internet Explorer 11 is now a prerequisite on Windows systems.&lt;br /&gt;
# iWebKit and jQuery Mobile 1.3 are no longer supported. The reason for the removal is that the developers of these controls were no longer maintaining them. The guys at iWebKit seem to have moved on to other projects, while jQuery Mobile 1.3 was replaced by jQuery Mobile 1.4 in 2013.&amp;lt;br&amp;gt;The affected controls have direct replacements. AppStudio 4 has a tool to automatically update the controls. When you launch AppStudio 4, it askes you whether you want to update your controls. It then makes a backup of your project and converts them. You may need to do some fine tuning to get them to look exactly as you want.&amp;lt;br&amp;gt;The best way to do this is with AppStudio 4. AppStudio 5 does not have the ability to convert the controls. To go back to AppStudio 4 to do this, uninstall AppStudio 5 and install 4. Here&#039;s the download info:&amp;lt;br&amp;gt;Mac: &amp;lt;https://dl.dropbox.com/u/4451197/AppStudio4.dmg&amp;gt;&amp;lt;br&amp;gt;Win: &amp;lt;https://dl.dropbox.com/u/4451197/AppStudio4.exe&amp;gt;&lt;br /&gt;
# Chrome Packaged Apps are no longer supported - replaced by full Windows exe apps.&lt;br /&gt;
# Form submit() removed from Toolbox. [[Ajax]] is a better way to do this.&lt;br /&gt;
# iOS 6 style [[NSB.MsgBox|MsgBoxes]] have been updated to current style.&lt;br /&gt;
# Style/End Style is no longer supported. Putting styling rules inline in code is messy and can cause performance problems. Copy the code inside your Style/End Style blocks and paste into the new styleheader Project property. It will then be put in the correct place at runtime.&lt;br /&gt;
# [[A Field Guide to App Studio Controls|jqWidgets]]: settings variable renamed from controlName_setting to NSB.jqxSettings[&amp;quot;controlName&amp;quot;]&lt;br /&gt;
# NSBCurrentForm replaced by NSB.currentForm&lt;br /&gt;
# [[Generic]] has been deprecated: use [[Container]] instead.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=EXE.pythonEval&amp;diff=7536</id>
		<title>EXE.pythonEval</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=EXE.pythonEval&amp;diff=7536"/>
		<updated>2015-08-10T20:25:27Z</updated>

		<summary type="html">&lt;p&gt;Admin: Admin moved page EXE.execPython to EXE.pythonEval without leaving a redirect: Error in docs&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;EXE.execPython(&#039;&#039;code&#039;&#039;[, &#039;&#039;callback&#039;&#039;])&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
EXE.execPython executes code in the EXE runtime wrapper. It only works in EXE apps. AppStudio&#039;s EXE apps work by wrapping your app in a executable wrapper which is written in Python. This function requires you to know Python ti use it.&lt;br /&gt;
&lt;br /&gt;
Code has to be properly formatted Python code, following all Python syntax rules. In addition to the base Python language, the following libraries can be used:&lt;br /&gt;
* os&lt;br /&gt;
* wx&lt;br /&gt;
* jason&lt;br /&gt;
* yaml&lt;br /&gt;
&lt;br /&gt;
Other may be included in a future release.&lt;br /&gt;
&lt;br /&gt;
Calls to EXE.execPython are processed asynchronously. To return values, put {callback}(value) in your code, and supply the name of the function you want called as &#039;&#039;callback&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
== Example (BASIC) ==&lt;br /&gt;
&lt;br /&gt;
Do a simple calculation and return the result&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
EXE.pythonEval(&amp;quot;{callback}(4*4)&amp;quot;, &amp;quot;showResult&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
Function showResult(res)&lt;br /&gt;
  MsgBox res&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
EXE.pythonEval(&amp;quot;{callback}(4*4)&amp;quot;, &amp;quot;showResult&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
function showResult(res) {&lt;br /&gt;
    NSB.MsgBox(res);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other examples ==&lt;br /&gt;
&lt;br /&gt;
Exit the app&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
EXE.pythonEval(&amp;quot;sys.exit(0)&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Put up a wx Message Box:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
EXE.pythonEval(&amp;quot;wx.MessageBox(&#039;It works!&#039;, &#039;Info&#039;, wx.OK | wx.ICON_INFORMATION)&amp;quot;, &amp;quot;MessageBox&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Run a code snippet&lt;br /&gt;
&lt;br /&gt;
Put the following code into a TextArea:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Code must be in Python.&lt;br /&gt;
# note how to return results.&lt;br /&gt;
a=64&lt;br /&gt;
{callback}(a*a)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And execute it as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;EXE.pythonEval(TextArea1.value, &amp;quot;showResult&amp;quot;)&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Version_5&amp;diff=7311</id>
		<title>Version 5</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Version_5&amp;diff=7311"/>
		<updated>2015-04-17T20:45:00Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* IDE - General */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;If you own a previous version of AppStudio, you need to buy the upgrade to use Version 5. You can do this from within the app or from our [http://www.nsbasic.com/order.shtml order form.] &lt;br /&gt;
&lt;br /&gt;
Until you have bought the upgrade, you can use AppStudio 5 in Demo mode. Once you buy, your copy will convert automatically to the full version.&lt;br /&gt;
&lt;br /&gt;
== Version 5.0.0 ==&lt;br /&gt;
&lt;br /&gt;
===Major New Features===&lt;br /&gt;
# [[Responsive Design Made Simple|Responsive Design]] lets your app adapt smoothly to different screen sizes.&lt;br /&gt;
# [[Make Windows Executables]] (exe) apps.&lt;br /&gt;
# Ten new controls, including [[Container]], [[Collapsible]], [[jqxEditor|Editor]], [[JqxEditor|Password]] Input and [[jqxWindow|Window]].&lt;br /&gt;
# Use [[ChangeForm|Visual Effects]] to show forms.&lt;br /&gt;
# Use [[Modal Forms]]&lt;br /&gt;
# Internet Explorer 11 support.&lt;br /&gt;
&lt;br /&gt;
===IDE - General===&lt;br /&gt;
# New look and feel for the IDE&lt;br /&gt;
# Tools Menu: New option to convert a BASIC project to JavaScript.&lt;br /&gt;
# [[Open Sample Dialog|Open Sample]]: Now allows nested folders, for better organization&lt;br /&gt;
# [[Open Sample Dialog|Open Sample]]: New Find option.&lt;br /&gt;
# [[About Screen]]: reformatted.&lt;br /&gt;
# Find: Opens with &amp;quot;Find What&amp;quot; selected.&lt;br /&gt;
# Help: now displays HTML formatted text with links.&lt;br /&gt;
# [[Open Sample Dialog|Open Sample]]: Samples are now sorted case insensitively.&lt;br /&gt;
# [[Properties Window|Project Properties]]: New styleheader property saves your styling rules.&lt;br /&gt;
# [[Properties Window]]: ChangeForm and firstform now have pickers.&lt;br /&gt;
# Properties Window: Events set properly on control copy and paste.&lt;br /&gt;
# Run menu: New [[Make Windows Executables]] (exe) App.&lt;br /&gt;
# Run menu: Improved menu names.&lt;br /&gt;
# Save: Saving a project no longer changes the Project ID.&lt;br /&gt;
# Startup: Projects with deprecated controls will get a message when loading is attempted.&lt;br /&gt;
# Startup: Splash screen on Mac OS startup no longer required.&lt;br /&gt;
# Startup: When project reopened, tabs are all reopened and same one returned to.&lt;br /&gt;
# View menu: New option to close all tabs.&lt;br /&gt;
# Installer: Checks if IE11 is installed on Windows&lt;br /&gt;
# Installer: Modifies registry so IE11 recognizes AppStudio.&lt;br /&gt;
&lt;br /&gt;
===Code Window===&lt;br /&gt;
# [[Code Window|Code Window:]] New clickable Function List appears in the Toolbox pane.&lt;br /&gt;
# Code Window: ToolTips now appear for user functions.&lt;br /&gt;
# Code Window: &#039;error&#039; is no longer auto capitalized.&lt;br /&gt;
# Code Window: Code converted to JS is now beautified.&lt;br /&gt;
# Code Window: Error when typing &#039;screen.&#039; fixed.&lt;br /&gt;
# Code Window: JSONP files are now edited as JSON files.&lt;br /&gt;
# Code Window: Problem with auto indentation fixed.&lt;br /&gt;
&lt;br /&gt;
===Design Screen===&lt;br /&gt;
# [[Design Screen]]: controls are relative if their parent is.&lt;br /&gt;
# Design Screen: new zoom icon. Use this to shrink size of Design Screen. Disables drag and drop.&lt;br /&gt;
# Design Screen: controls can be grouped using [[Container|Containers]].&lt;br /&gt;
# Design Screen: Right click to lock controls from accidental position changes.&lt;br /&gt;
# Design Screen: Double click opens [[Code Window]].&lt;br /&gt;
# Design Screen: Dump wxWebkit. Now smaller, faster.&lt;br /&gt;
# Design Screen: Internally uses IE to render controls.&lt;br /&gt;
# Design Screen: Paste now shows on the right click menu.&lt;br /&gt;
# Design Screen: Snap to grid is now gray, not black.&lt;br /&gt;
&lt;br /&gt;
===Project Explorer===&lt;br /&gt;
# Project Explorer: Folders can now be dragged and dropped.&lt;br /&gt;
# Project Explorer: JSON files can now be dragged and dropped.&lt;br /&gt;
# Project Explorer: SQLite databases can now be dragged and dropped.&lt;br /&gt;
# [[Project Explorer]]: Delete file now has confirmation message.&lt;br /&gt;
# Project Explorer: Warning if drag and drop of existing file.&lt;br /&gt;
&lt;br /&gt;
===Language===&lt;br /&gt;
# [[ChangeForm]]() now supports visual effects.&lt;br /&gt;
# [[Ajax]]() can now have a callback as a second argument.&lt;br /&gt;
# Ajax() can now take an object for its parameters.&lt;br /&gt;
# Ajax() now supports a fail callback.&lt;br /&gt;
# [[ReadFile]]() can now be used asynchronously.&lt;br /&gt;
# Case normalization is now handled in Code Window&lt;br /&gt;
# Case normalization moved out of hfunc.js, killing hundreds of lines of code.&lt;br /&gt;
# Language version bumped. Existing projects will take longer to compile first time they are run using the new version.&lt;br /&gt;
# Map is now a keyword.&lt;br /&gt;
# Overlay() function deleted - it was obsolete.&lt;br /&gt;
# Referencing a control by name itself will return its value.&lt;br /&gt;
# Referencing a control by name will return a numeric if possible.&lt;br /&gt;
# [[Style/End Style]] deprecated. See &#039;Breaking Changes&#039;.&lt;br /&gt;
# [[NSBCurrentForm]] changed to NSB.currentForm.&lt;br /&gt;
# Arrays no longer have to be declared in all modules.&lt;br /&gt;
&lt;br /&gt;
===Toolbox===&lt;br /&gt;
# New: [[Container]] control for text, html and other controls.&lt;br /&gt;
# All: New [[Properties and Methods|methods]] to hide and show controls: fadeIn, fadeOut, slideUp, slideDown.&lt;br /&gt;
# All: Updated to work with IE11.&lt;br /&gt;
# All: -webkit prefix removed from css.&lt;br /&gt;
# All: Border [[properties]] are now consistant.&lt;br /&gt;
# All: BorderColor and BorderWidth added all controls with borders.&lt;br /&gt;
# All: Bounds can now be &#039;inherit&#039; and &#039;initial&#039;.&lt;br /&gt;
# All: Disabled property fixed.&lt;br /&gt;
# All: font selectors normalized.&lt;br /&gt;
# All: HTML output for borders streamlined.&lt;br /&gt;
# All: New onresize [[events|event]].&lt;br /&gt;
# All: no longer load function code that is not needed.&lt;br /&gt;
# All: [[ToolBox Files|ToolBox Files]] can now share property definitions.&lt;br /&gt;
# [[Camera]]: value can now be set at Design Time.&lt;br /&gt;
# [[Date, DateTime|Date and Time]]: appearance improved.&lt;br /&gt;
# Dialog is now on top of scroll bars.&lt;br /&gt;
# [[Facebook]]: unneeded font property removed.&lt;br /&gt;
# Functions for AppStudio&#039;s controls moved from complexfunctions.js to nsbFunctions.js.&lt;br /&gt;
# Functions for jqMobile controls moved from complexfunctions.js to jqmFunctions.js.&lt;br /&gt;
# Functions for jqWidget controls moved from complexfunctions.js to jqxFunctions.js.&lt;br /&gt;
# [[Generic]]: Deprecated - replaced by Container.&lt;br /&gt;
# [[Grid]]: .cellstyle can be read at runtime.&lt;br /&gt;
# Grid: .colWidths can be read at runtime.&lt;br /&gt;
# Grid: Cells added at runtime are formatted with cellstyle.&lt;br /&gt;
# Grid: fix alignment style bug on first column.&lt;br /&gt;
# Grid: styling moved from complexfunctions to nsbstyle.css.&lt;br /&gt;
# Help now has pointers to Wiki.&lt;br /&gt;
# [[HTMLView|HTMLView]]: Emitted code improved.&lt;br /&gt;
# HTMLView: fix warning from Safari.&lt;br /&gt;
# HTMLView: Percentage widths fixed.&lt;br /&gt;
# [[NSB.MsgBox]]: Appearance improved on RTL systems.&lt;br /&gt;
# NSB.MsgBox: formatting error with two buttons fixed.&lt;br /&gt;
# NSB.MsgBox: iOS 6 style MsgBoxes are gone.&lt;br /&gt;
# NSB.MsgBox: now handles former _msgbox_confirm function.&lt;br /&gt;
# [[NSB.ShowProgress]] is now modal.&lt;br /&gt;
# [[PayPal]]: Allows user specified image.&lt;br /&gt;
# PayPal: Only deploy image which is used, not all four.&lt;br /&gt;
# [[Toolbox]]: Now has a Find area on the bottom.&lt;br /&gt;
# Toolbox: Right click now opens Wiki page for all controls.&lt;br /&gt;
&lt;br /&gt;
===Forms===&lt;br /&gt;
# New [[Modal Forms|modal]] property: can make form float modally over rest of app.&lt;br /&gt;
# New visual effects: fadeIn, fadeOut, slideUp, slideDown.&lt;br /&gt;
# New BackgroundColor property.&lt;br /&gt;
# New BorderColor property.&lt;br /&gt;
# New BorderWidth property.&lt;br /&gt;
# New parentForm property.&lt;br /&gt;
#  New position property. Can be absolute, fixed, etc. Good for [[Responsive Design Made Simple|Responsive Design]].&lt;br /&gt;
# Background renamed backgroundImage.&lt;br /&gt;
# Borders can be specified.&lt;br /&gt;
# Controls copy and pasted to new forms are not repositioned.&lt;br /&gt;
# Form submit properties removed from Toolbox.&lt;br /&gt;
# Forms are now a &amp;amp;lt;div&amp;gt; element, not &amp;amp;lt;form&amp;gt;&lt;br /&gt;
# Forms can now have bounds in percentages (if fullScreen is false).&lt;br /&gt;
&lt;br /&gt;
===Runtime===&lt;br /&gt;
# Comments between forms added to output code.&lt;br /&gt;
# Indenting of code improved.&lt;br /&gt;
# Main div renamed to NSBPage from Page_jqm.&lt;br /&gt;
# Needless blank lines removed.&lt;br /&gt;
# Output code cleaned up.&lt;br /&gt;
# Return value of function renamed returnValue (was savethefunction_rval)&lt;br /&gt;
# ReturnValue code not created if function does not return a value.&lt;br /&gt;
# CSS files moved to head for faster rendering.&lt;br /&gt;
# Generated code reformatted by JSBeautifier when possible.&lt;br /&gt;
&lt;br /&gt;
===Deploy===&lt;br /&gt;
# Option to create Windows Executable (exe) added to Run menu.&lt;br /&gt;
# Nicely formatted screen listing your deployed apps.&lt;br /&gt;
# Native Build Status: Starts automatically after build and auto refreshes.&lt;br /&gt;
# Drag and Drop to Project Explorer fills manifest automatically.&lt;br /&gt;
# Cache: error message improved.&lt;br /&gt;
# Cache: Mime types set on local server - Some Windows systems set incorrectly.&lt;br /&gt;
# Cache: New global [[NSB.cacheStatus]] is available to your app.&lt;br /&gt;
# Cache: User now prompted before web app is updated.&lt;br /&gt;
# Cache: To turn off update prompt, do NSB.confirmCacheUpdate=&amp;quot;&amp;quot;&lt;br /&gt;
# [[Menu Options|Check Deployment]]: Additional checking added.&lt;br /&gt;
# [[Build Native App|Native Build Status]]: Auto refresh every 3 seconds.&lt;br /&gt;
# Native Build Status: Links added for iOS &#039;Error&#039; message.&lt;br /&gt;
# Native Build Status: Links added to Tech Note for app stores.&lt;br /&gt;
# Native Build Status: Refresh button deleted.&lt;br /&gt;
# Native Build Status: Opens automatically after app submitted to PhoneGap.&lt;br /&gt;
# nsbapp.com: User image in nsb caused problems uploading to nsbapp.com fixed.&lt;br /&gt;
# [[PhoneGap CLI|PhoneGap]]: CLI progress window can now be closed.&lt;br /&gt;
# PhoneGap: Config.xml no longer gets deployed (It&#039;s only for PhoneGap)&lt;br /&gt;
# PhoneGap: Default configxml updated.&lt;br /&gt;
# PhoneGap: New PhoneGap Camera sample.&lt;br /&gt;
# PhoneGap: Project Location build uses [[PhoneGap AuthToken|AuthToken]].&lt;br /&gt;
# PhoneGap: [[SplashScreens|Splashscreen]] is now automatically added to manifest.&lt;br /&gt;
# PhoneGap: splashscreen property now uses image picker.&lt;br /&gt;
# PHP: Umlauts (and other extended characters) are now OK in PHP files.&lt;br /&gt;
# [[Preferences]]: Static localhost port# added.&lt;br /&gt;
# [[Project Explorer]]: Entire folders can be dragged and dropped. &lt;br /&gt;
# Project Explorer: JSON files can be dragged and dropped for deploy.&lt;br /&gt;
# Project Explorer: SQLite databases can be dragged and dropped for deploy.&lt;br /&gt;
# Run: from local filesystem uses default browser.&lt;br /&gt;
# Run: Local deploy is to 127.0.0.1 instead of localhost to deal with poorly configured systems.&lt;br /&gt;
# Run: Local deploy pathnames can now have spaces.&lt;br /&gt;
&lt;br /&gt;
===jQuery Mobile Framework===&lt;br /&gt;
# New: [[Collapsible]] control shows popup text.&lt;br /&gt;
# All: Toolbox files tweaked for proper display in IE11.&lt;br /&gt;
# All: jQuery Mobile 1.3 controls and samples have been removed.&lt;br /&gt;
# [[Button]], [[List]]: Text appearance improved.&lt;br /&gt;
# [[Button]]: Groups now have ID numbers.&lt;br /&gt;
# Icons now draw more sharply.&lt;br /&gt;
# [[Panel]]: icon now drawn correctly.&lt;br /&gt;
# [[Select]]: addItem can now accept multiple items&lt;br /&gt;
# [[TextArea]]: Added maxlength property.&lt;br /&gt;
&lt;br /&gt;
===jqWidgets Framework===&lt;br /&gt;
# New: [[jqxDateTimeInput|DateTimeInput]] control.&lt;br /&gt;
# New: [[jqxDocking|Docking]] control.&lt;br /&gt;
# New: [[jqxEditor|Editor]] control.&lt;br /&gt;
# New: [[jqxMaskedInput|MaskedInput]] control.&lt;br /&gt;
# New: [[jqxNavigationBar|NavigationBar]] control.&lt;br /&gt;
# New: [[jqxPasswordInput|PasswordInput]] control.&lt;br /&gt;
# New: [[jqxValidator|Validator]] control.&lt;br /&gt;
# New: [[jqxWindow|Window]] control.&lt;br /&gt;
# New themes: Android, Web, Bootstrap, Metro and Office.&lt;br /&gt;
# All: controls now have hidden, disabled, theme and rtl properties.&lt;br /&gt;
# All: Design settings are available at runtime in the NSB.jqxSettings[id] array.&lt;br /&gt;
# All: Functions for jqx controls moved from complexfunctions.js to jqxFunctions.js.&lt;br /&gt;
# All: Remove jqxSettings_ variables from global namespace. Now in NSB.jqxSettings[&amp;quot;controlName&amp;quot;]&lt;br /&gt;
# All: Toolbox files have been streamlined.&lt;br /&gt;
# [[jqxCheckBox|Checkbox]]: Icon updated.&lt;br /&gt;
# [[JqxMenu|Menu]]: wrong height on pulldown fixed.&lt;br /&gt;
# Samples: Numerous fixes to samples.&lt;br /&gt;
&lt;br /&gt;
===iWebKit Framework===&lt;br /&gt;
# All iWebKit controls and samples have been removed.&lt;br /&gt;
&lt;br /&gt;
=== Samples ===&lt;br /&gt;
# Samples can be searched for keywords.&lt;br /&gt;
# Samples are now organized into subdirectories.&lt;br /&gt;
# New [[Collapsible|Collapsable]] sample.&lt;br /&gt;
# New [[Modal Forms|Modal]] form sample.&lt;br /&gt;
# New PhoneGap Camera sample.&lt;br /&gt;
# New samples for all the new jqWidgets controls.&lt;br /&gt;
# All samples updated to use the new release.&lt;br /&gt;
# Desktop files for [[WebSockets]] samples moved to Wiki in zip format.&lt;br /&gt;
# Fix incorrect default splashscreen paths.&lt;br /&gt;
# Many updates and fixes.&lt;br /&gt;
# Update Ajax samples to use asynchronous calls.&lt;br /&gt;
&lt;br /&gt;
=== Documentation ===&lt;br /&gt;
# TechNotes: New [[Responsive Design Made Simple]]&lt;br /&gt;
&lt;br /&gt;
=== Internals ===&lt;br /&gt;
# Internals: PyV8 no longer used.&lt;br /&gt;
# Internals: wxWebkit is no longer used.&lt;br /&gt;
# Internals: wxPython updated to 3.0.0.&lt;br /&gt;
# Internals: node.js now now used for translation and syntax checking.&lt;br /&gt;
# Internals: PyInstaller is now used to create Mac installer instead of Py2App.&lt;br /&gt;
# Internals: Complexfunctions and hfunc cleaned up using jshint.&lt;br /&gt;
# Internals: Complexfunctions and hfunc reformatted.&lt;br /&gt;
# Internals: hfunc and functions files minified.&lt;br /&gt;
# Internals: exception handling improved.&lt;br /&gt;
# Internals: FastClick updated to 1.0.6&lt;br /&gt;
&lt;br /&gt;
===Breaking Changes===&lt;br /&gt;
# Windows XP and Vista are no longer supported, due to IE 11&#039;s minimum requirements. Microsoft is no longer issuing security patches for XP. http://windows.microsoft.com/en-ca/windows/end-support-help&lt;br /&gt;
# Internet Explorer 11 is now a prerequisite on Windows systems.&lt;br /&gt;
# iWebKit and jQuery Mobile 1.3 are no longer supported&lt;br /&gt;
# Chrome Packaged Apps are no longer supported - replaced by full Windows exe apps.&lt;br /&gt;
# Form submit() removed from Toolbox. [[Ajax]] is a better way to do this.&lt;br /&gt;
# iOS 6 style [[NSB.MsgBox|MsgBoxes]] have been updated to current style.&lt;br /&gt;
# Style/End Style is no longer supported. Putting styling rules inline in code is messy and can cause performance problems. Copy the code inside your Style/End Style blocks and paste into the new styleheader Project property. It will then be put in the correct place at runtime.&lt;br /&gt;
# [[A Field Guide to App Studio Controls|jqWidgets]]: settings variable renamed from controlName_setting to NSB.jqxSettings[&amp;quot;controlName&amp;quot;]&lt;br /&gt;
# NSBCurrentForm replaced by NSB.currentForm&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7135</id>
		<title>Form</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7135"/>
		<updated>2015-04-07T11:47:23Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Description */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Description ==&lt;br /&gt;
&lt;br /&gt;
Forms act as containers for controls. To go to a new form, use the [[ChangeForm]]() function.&lt;br /&gt;
&lt;br /&gt;
To add a Form to your app, choose Add Form from the Project menu at the top of the screen. Forms can be deleted in the Project Explorer.&lt;br /&gt;
&lt;br /&gt;
Scrolling forms are allowed, with a couple of notes. Footerbars won&#039;t work (since the bottom needs to scroll up), nor will scrolling controls (which confuse the scroller).&lt;br /&gt;
&lt;br /&gt;
The information on a form can be submitted to a URL by using the [[Ajax]] function.&lt;br /&gt;
&lt;br /&gt;
== Properties ==&lt;br /&gt;
&lt;br /&gt;
Standard [[properties and methods|properties]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; &lt;br /&gt;
|-&lt;br /&gt;
| backgroundImage || Will override the background with a pattern or an image. &amp;lt;pre&amp;gt;linear-gradient(#55aaee, #003366);&amp;lt;/pre&amp;gt;&lt;br /&gt;
or&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
url(http://www.nsbasic.com/images/eiffel.gif);&amp;lt;/pre&amp;gt; &lt;br /&gt;
If you are using jQuery Mobile, the best way to control the background color is to use themes. It will work better on PhoneGap Build.&lt;br /&gt;
|-&lt;br /&gt;
| fullscreen || True/False. If True, the form will automatically fill the entire device screen. The IDE will still use height and width at design time.&lt;br /&gt;
|-&lt;br /&gt;
| height || The height of the form in pixels. Default is 460.&lt;br /&gt;
|-&lt;br /&gt;
| left || The left position of the form. Use this for forms that are not full screen.&lt;br /&gt;
|-&lt;br /&gt;
| locked || If set to true, the controls on the Design Screen cannot be moved&lt;br /&gt;
|-&lt;br /&gt;
| language || The programming language used in the code for the form. Can be BASIC or JavaScript.&lt;br /&gt;
|-&lt;br /&gt;
| method || Get or Post. The method that the http form is sent by.&lt;br /&gt;
|-&lt;br /&gt;
| openMode || Should the form be open at startup? Use this for forms which are to remain open. There is no need to set this for the first form of the project: that is set in [[Properties Window|Project Properties]].&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| scroll_options || iScroll options. See iScroll docs at http://iscrolljs.com. &lt;br /&gt;
|-&lt;br /&gt;
| scrolling || Allow scrolling?&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| style || The CSS style for the form. &lt;br /&gt;
|-&lt;br /&gt;
| setFocusID || The control to get the focus when the form is shown.&lt;br /&gt;
|-&lt;br /&gt;
| Url || The URL to be called when the form is submitted using the submit() function.&lt;br /&gt;
|-&lt;br /&gt;
| width || The width of the form in pixels. Default is 320. Percents can be set at runtime.&lt;br /&gt;
|-&lt;br /&gt;
| reset() || Clear all fields on the form. Runtime only.&lt;br /&gt;
|-&lt;br /&gt;
| submit() || Submit the data on the form to the specified URL. Runtime only. See [[Location]] as well.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Standard [[events]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| onhide() || Called when form hidden as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onkeypress(event) || Called when a key is tapped on a form.&lt;br /&gt;
|-&lt;br /&gt;
| onshow() || Called by firstform and when form is shown as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onsubmit() || Called when a form is submitted.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example (Basic) ==&lt;br /&gt;
&lt;br /&gt;
Change color at runtime&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  Form1.style.backgroundColor=&amp;quot;red&amp;quot;&lt;br /&gt;
  Form1.style.width=&amp;quot;100%&amp;quot;  &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent the image from repeating to fill the full window:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  NSBPage.style.backgroundRepeat = &amp;quot;no-repeat&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  Form1.style.backgroundColor=&amp;quot;red&amp;quot;;&lt;br /&gt;
  Form1.style.width=&amp;quot;100%&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent the image from repeating to fill the full window:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  NSBPage.style.backgroundRepeat = &amp;quot;no-repeat&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
(Url is called with values in the query string)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[changeform|ChangeForm]], [[geturlparameter|GetUrlParameter]], [[properties and methods|Properties]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7134</id>
		<title>Form</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7134"/>
		<updated>2015-04-07T11:46:08Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Example (JavaScript) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Description ==&lt;br /&gt;
&lt;br /&gt;
Forms act as containers for controls. To go to a new form, use the [[ChangeForm]]() function.&lt;br /&gt;
&lt;br /&gt;
To add a Form to your app, choose Add Form from the Project menu at the top of the screen. Forms can be deleted in the Project Explorer.&lt;br /&gt;
&lt;br /&gt;
Scrolling forms are allowed, with a couple of notes. Footerbars won&#039;t work (since the bottom needs to scroll up), nor will scrolling controls (which confuse the scroller).&lt;br /&gt;
&lt;br /&gt;
The information on a form can be submitted to a URL by calling the form.submit() function. The values for all controls on the form which have their Name property defined will be appended to the URL as an HTML query string.&lt;br /&gt;
&lt;br /&gt;
== Properties ==&lt;br /&gt;
&lt;br /&gt;
Standard [[properties and methods|properties]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; &lt;br /&gt;
|-&lt;br /&gt;
| backgroundImage || Will override the background with a pattern or an image. &amp;lt;pre&amp;gt;linear-gradient(#55aaee, #003366);&amp;lt;/pre&amp;gt;&lt;br /&gt;
or&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
url(http://www.nsbasic.com/images/eiffel.gif);&amp;lt;/pre&amp;gt; &lt;br /&gt;
If you are using jQuery Mobile, the best way to control the background color is to use themes. It will work better on PhoneGap Build.&lt;br /&gt;
|-&lt;br /&gt;
| fullscreen || True/False. If True, the form will automatically fill the entire device screen. The IDE will still use height and width at design time.&lt;br /&gt;
|-&lt;br /&gt;
| height || The height of the form in pixels. Default is 460.&lt;br /&gt;
|-&lt;br /&gt;
| left || The left position of the form. Use this for forms that are not full screen.&lt;br /&gt;
|-&lt;br /&gt;
| locked || If set to true, the controls on the Design Screen cannot be moved&lt;br /&gt;
|-&lt;br /&gt;
| language || The programming language used in the code for the form. Can be BASIC or JavaScript.&lt;br /&gt;
|-&lt;br /&gt;
| method || Get or Post. The method that the http form is sent by.&lt;br /&gt;
|-&lt;br /&gt;
| openMode || Should the form be open at startup? Use this for forms which are to remain open. There is no need to set this for the first form of the project: that is set in [[Properties Window|Project Properties]].&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| scroll_options || iScroll options. See iScroll docs at http://iscrolljs.com. &lt;br /&gt;
|-&lt;br /&gt;
| scrolling || Allow scrolling?&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| style || The CSS style for the form. &lt;br /&gt;
|-&lt;br /&gt;
| setFocusID || The control to get the focus when the form is shown.&lt;br /&gt;
|-&lt;br /&gt;
| Url || The URL to be called when the form is submitted using the submit() function.&lt;br /&gt;
|-&lt;br /&gt;
| width || The width of the form in pixels. Default is 320. Percents can be set at runtime.&lt;br /&gt;
|-&lt;br /&gt;
| reset() || Clear all fields on the form. Runtime only.&lt;br /&gt;
|-&lt;br /&gt;
| submit() || Submit the data on the form to the specified URL. Runtime only. See [[Location]] as well.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Standard [[events]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| onhide() || Called when form hidden as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onkeypress(event) || Called when a key is tapped on a form.&lt;br /&gt;
|-&lt;br /&gt;
| onshow() || Called by firstform and when form is shown as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onsubmit() || Called when a form is submitted.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example (Basic) ==&lt;br /&gt;
&lt;br /&gt;
Change color at runtime&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  Form1.style.backgroundColor=&amp;quot;red&amp;quot;&lt;br /&gt;
  Form1.style.width=&amp;quot;100%&amp;quot;  &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent the image from repeating to fill the full window:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  NSBPage.style.backgroundRepeat = &amp;quot;no-repeat&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  Form1.style.backgroundColor=&amp;quot;red&amp;quot;;&lt;br /&gt;
  Form1.style.width=&amp;quot;100%&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent the image from repeating to fill the full window:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  NSBPage.style.backgroundRepeat = &amp;quot;no-repeat&amp;quot;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
(Url is called with values in the query string)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[changeform|ChangeForm]], [[geturlparameter|GetUrlParameter]], [[properties and methods|Properties]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7133</id>
		<title>Form</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7133"/>
		<updated>2015-04-07T11:45:31Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Example (Basic) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Description ==&lt;br /&gt;
&lt;br /&gt;
Forms act as containers for controls. To go to a new form, use the [[ChangeForm]]() function.&lt;br /&gt;
&lt;br /&gt;
To add a Form to your app, choose Add Form from the Project menu at the top of the screen. Forms can be deleted in the Project Explorer.&lt;br /&gt;
&lt;br /&gt;
Scrolling forms are allowed, with a couple of notes. Footerbars won&#039;t work (since the bottom needs to scroll up), nor will scrolling controls (which confuse the scroller).&lt;br /&gt;
&lt;br /&gt;
The information on a form can be submitted to a URL by calling the form.submit() function. The values for all controls on the form which have their Name property defined will be appended to the URL as an HTML query string.&lt;br /&gt;
&lt;br /&gt;
== Properties ==&lt;br /&gt;
&lt;br /&gt;
Standard [[properties and methods|properties]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; &lt;br /&gt;
|-&lt;br /&gt;
| backgroundImage || Will override the background with a pattern or an image. &amp;lt;pre&amp;gt;linear-gradient(#55aaee, #003366);&amp;lt;/pre&amp;gt;&lt;br /&gt;
or&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
url(http://www.nsbasic.com/images/eiffel.gif);&amp;lt;/pre&amp;gt; &lt;br /&gt;
If you are using jQuery Mobile, the best way to control the background color is to use themes. It will work better on PhoneGap Build.&lt;br /&gt;
|-&lt;br /&gt;
| fullscreen || True/False. If True, the form will automatically fill the entire device screen. The IDE will still use height and width at design time.&lt;br /&gt;
|-&lt;br /&gt;
| height || The height of the form in pixels. Default is 460.&lt;br /&gt;
|-&lt;br /&gt;
| left || The left position of the form. Use this for forms that are not full screen.&lt;br /&gt;
|-&lt;br /&gt;
| locked || If set to true, the controls on the Design Screen cannot be moved&lt;br /&gt;
|-&lt;br /&gt;
| language || The programming language used in the code for the form. Can be BASIC or JavaScript.&lt;br /&gt;
|-&lt;br /&gt;
| method || Get or Post. The method that the http form is sent by.&lt;br /&gt;
|-&lt;br /&gt;
| openMode || Should the form be open at startup? Use this for forms which are to remain open. There is no need to set this for the first form of the project: that is set in [[Properties Window|Project Properties]].&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| scroll_options || iScroll options. See iScroll docs at http://iscrolljs.com. &lt;br /&gt;
|-&lt;br /&gt;
| scrolling || Allow scrolling?&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| style || The CSS style for the form. &lt;br /&gt;
|-&lt;br /&gt;
| setFocusID || The control to get the focus when the form is shown.&lt;br /&gt;
|-&lt;br /&gt;
| Url || The URL to be called when the form is submitted using the submit() function.&lt;br /&gt;
|-&lt;br /&gt;
| width || The width of the form in pixels. Default is 320. Percents can be set at runtime.&lt;br /&gt;
|-&lt;br /&gt;
| reset() || Clear all fields on the form. Runtime only.&lt;br /&gt;
|-&lt;br /&gt;
| submit() || Submit the data on the form to the specified URL. Runtime only. See [[Location]] as well.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Standard [[events]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| onhide() || Called when form hidden as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onkeypress(event) || Called when a key is tapped on a form.&lt;br /&gt;
|-&lt;br /&gt;
| onshow() || Called by firstform and when form is shown as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onsubmit() || Called when a form is submitted.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example (Basic) ==&lt;br /&gt;
&lt;br /&gt;
Change color at runtime&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  Form1.style.backgroundColor=&amp;quot;red&amp;quot;&lt;br /&gt;
  Form1.style.width=&amp;quot;100%&amp;quot;  &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent the image from repeating to fill the full window:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  NSBPage.style.backgroundRepeat = &amp;quot;no-repeat&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
btnSendData.onclick = function() {&lt;br /&gt;
  Form1.submit();&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent a form from being submitted when the return key is entered in a field:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Form1.onsubmit = function(e) {&lt;br /&gt;
  e.cancelBubble=true;&lt;br /&gt;
  e.returnValue=false;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To change the background image on a form:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    Form1.style.backgroundImage=&amp;quot;url(https://www.nsbasic.com/images/lavalamp.gif)&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
(Url is called with values in the query string)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[changeform|ChangeForm]], [[geturlparameter|GetUrlParameter]], [[properties and methods|Properties]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7132</id>
		<title>Form</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7132"/>
		<updated>2015-04-07T11:44:09Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Properties */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Description ==&lt;br /&gt;
&lt;br /&gt;
Forms act as containers for controls. To go to a new form, use the [[ChangeForm]]() function.&lt;br /&gt;
&lt;br /&gt;
To add a Form to your app, choose Add Form from the Project menu at the top of the screen. Forms can be deleted in the Project Explorer.&lt;br /&gt;
&lt;br /&gt;
Scrolling forms are allowed, with a couple of notes. Footerbars won&#039;t work (since the bottom needs to scroll up), nor will scrolling controls (which confuse the scroller).&lt;br /&gt;
&lt;br /&gt;
The information on a form can be submitted to a URL by calling the form.submit() function. The values for all controls on the form which have their Name property defined will be appended to the URL as an HTML query string.&lt;br /&gt;
&lt;br /&gt;
== Properties ==&lt;br /&gt;
&lt;br /&gt;
Standard [[properties and methods|properties]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; &lt;br /&gt;
|-&lt;br /&gt;
| backgroundImage || Will override the background with a pattern or an image. &amp;lt;pre&amp;gt;linear-gradient(#55aaee, #003366);&amp;lt;/pre&amp;gt;&lt;br /&gt;
or&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
url(http://www.nsbasic.com/images/eiffel.gif);&amp;lt;/pre&amp;gt; &lt;br /&gt;
If you are using jQuery Mobile, the best way to control the background color is to use themes. It will work better on PhoneGap Build.&lt;br /&gt;
|-&lt;br /&gt;
| fullscreen || True/False. If True, the form will automatically fill the entire device screen. The IDE will still use height and width at design time.&lt;br /&gt;
|-&lt;br /&gt;
| height || The height of the form in pixels. Default is 460.&lt;br /&gt;
|-&lt;br /&gt;
| left || The left position of the form. Use this for forms that are not full screen.&lt;br /&gt;
|-&lt;br /&gt;
| locked || If set to true, the controls on the Design Screen cannot be moved&lt;br /&gt;
|-&lt;br /&gt;
| language || The programming language used in the code for the form. Can be BASIC or JavaScript.&lt;br /&gt;
|-&lt;br /&gt;
| method || Get or Post. The method that the http form is sent by.&lt;br /&gt;
|-&lt;br /&gt;
| openMode || Should the form be open at startup? Use this for forms which are to remain open. There is no need to set this for the first form of the project: that is set in [[Properties Window|Project Properties]].&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| scroll_options || iScroll options. See iScroll docs at http://iscrolljs.com. &lt;br /&gt;
|-&lt;br /&gt;
| scrolling || Allow scrolling?&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| style || The CSS style for the form. &lt;br /&gt;
|-&lt;br /&gt;
| setFocusID || The control to get the focus when the form is shown.&lt;br /&gt;
|-&lt;br /&gt;
| Url || The URL to be called when the form is submitted using the submit() function.&lt;br /&gt;
|-&lt;br /&gt;
| width || The width of the form in pixels. Default is 320. Percents can be set at runtime.&lt;br /&gt;
|-&lt;br /&gt;
| reset() || Clear all fields on the form. Runtime only.&lt;br /&gt;
|-&lt;br /&gt;
| submit() || Submit the data on the form to the specified URL. Runtime only. See [[Location]] as well.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Standard [[events]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| onhide() || Called when form hidden as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onkeypress(event) || Called when a key is tapped on a form.&lt;br /&gt;
|-&lt;br /&gt;
| onshow() || Called by firstform and when form is shown as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onsubmit() || Called when a form is submitted.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example (Basic) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function btnSendData_onclick()&lt;br /&gt;
  Form1.submit()&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent a form from being submitted when the return key is entered in a field:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function Form1_onsubmit(e)&lt;br /&gt;
  e.cancelBubble=True&lt;br /&gt;
  e.returnValue=False&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
btnSendData.onclick = function() {&lt;br /&gt;
  Form1.submit();&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent a form from being submitted when the return key is entered in a field:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Form1.onsubmit = function(e) {&lt;br /&gt;
  e.cancelBubble=true;&lt;br /&gt;
  e.returnValue=false;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To change the background image on a form:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    Form1.style.backgroundImage=&amp;quot;url(https://www.nsbasic.com/images/lavalamp.gif)&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
(Url is called with values in the query string)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[changeform|ChangeForm]], [[geturlparameter|GetUrlParameter]], [[properties and methods|Properties]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7131</id>
		<title>Form</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7131"/>
		<updated>2015-04-07T11:42:28Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Properties */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Description ==&lt;br /&gt;
&lt;br /&gt;
Forms act as containers for controls. To go to a new form, use the [[ChangeForm]]() function.&lt;br /&gt;
&lt;br /&gt;
To add a Form to your app, choose Add Form from the Project menu at the top of the screen. Forms can be deleted in the Project Explorer.&lt;br /&gt;
&lt;br /&gt;
Scrolling forms are allowed, with a couple of notes. Footerbars won&#039;t work (since the bottom needs to scroll up), nor will scrolling controls (which confuse the scroller).&lt;br /&gt;
&lt;br /&gt;
The information on a form can be submitted to a URL by calling the form.submit() function. The values for all controls on the form which have their Name property defined will be appended to the URL as an HTML query string.&lt;br /&gt;
&lt;br /&gt;
== Properties ==&lt;br /&gt;
&lt;br /&gt;
Standard [[properties and methods|properties]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; &lt;br /&gt;
|-&lt;br /&gt;
| backgroundImage || Will override the background with a pattern or an image. &amp;lt;pre&amp;gt;linear-gradient(#55aaee, #003366);&amp;lt;/pre&amp;gt;&lt;br /&gt;
or&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
url(http://www.nsbasic.com/images/eiffel.gif);&amp;lt;/pre&amp;gt; &lt;br /&gt;
At runtime, you need to force a redraw:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  Form1.style.background=&amp;quot;red&amp;quot;&lt;br /&gt;
  Form1.style.width=&amp;quot;100%&amp;quot;  &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
To prevent the image from repeating to fill the full window, do this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  NSBPage.style.backgroundRepeat = &amp;quot;no-repeat&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
If you are using jQuery Mobile, the best way to control the background color is to use themes. It will work better on PhoneGap Build.&lt;br /&gt;
|-&lt;br /&gt;
| fullscreen || True/False. If True, the form will automatically fill the entire device screen. The IDE will still use height and width at design time.&lt;br /&gt;
|-&lt;br /&gt;
| height || The height of the form in pixels. Default is 460.&lt;br /&gt;
|-&lt;br /&gt;
| left || The left position of the form. Use this for forms that are not full screen.&lt;br /&gt;
|-&lt;br /&gt;
| locked || If set to true, the controls on the Design Screen cannot be moved&lt;br /&gt;
|-&lt;br /&gt;
| language || The programming language used in the code for the form. Can be BASIC or JavaScript.&lt;br /&gt;
|-&lt;br /&gt;
| method || Get or Post. The method that the http form is sent by.&lt;br /&gt;
|-&lt;br /&gt;
| openMode || Should the form be open at startup? Use this for forms which are to remain open. There is no need to set this for the first form of the project: that is set in [[Properties Window|Project Properties]].&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| scroll_options || iScroll options. See iScroll docs at http://iscrolljs.com. &lt;br /&gt;
|-&lt;br /&gt;
| scrolling || Allow scrolling?&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| style || The CSS style for the form. &lt;br /&gt;
|-&lt;br /&gt;
| setFocusID || The control to get the focus when the form is shown.&lt;br /&gt;
|-&lt;br /&gt;
| Url || The URL to be called when the form is submitted using the submit() function.&lt;br /&gt;
|-&lt;br /&gt;
| width || The width of the form in pixels. Default is 320. Percents can be set at runtime.&lt;br /&gt;
|-&lt;br /&gt;
| reset() || Clear all fields on the form. Runtime only.&lt;br /&gt;
|-&lt;br /&gt;
| submit() || Submit the data on the form to the specified URL. Runtime only. See [[Location]] as well.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Standard [[events]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| onhide() || Called when form hidden as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onkeypress(event) || Called when a key is tapped on a form.&lt;br /&gt;
|-&lt;br /&gt;
| onshow() || Called by firstform and when form is shown as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onsubmit() || Called when a form is submitted.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example (Basic) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function btnSendData_onclick()&lt;br /&gt;
  Form1.submit()&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent a form from being submitted when the return key is entered in a field:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function Form1_onsubmit(e)&lt;br /&gt;
  e.cancelBubble=True&lt;br /&gt;
  e.returnValue=False&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
btnSendData.onclick = function() {&lt;br /&gt;
  Form1.submit();&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent a form from being submitted when the return key is entered in a field:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Form1.onsubmit = function(e) {&lt;br /&gt;
  e.cancelBubble=true;&lt;br /&gt;
  e.returnValue=false;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To change the background image on a form:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    Form1.style.backgroundImage=&amp;quot;url(https://www.nsbasic.com/images/lavalamp.gif)&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
(Url is called with values in the query string)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[changeform|ChangeForm]], [[geturlparameter|GetUrlParameter]], [[properties and methods|Properties]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7130</id>
		<title>Form</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Form&amp;diff=7130"/>
		<updated>2015-04-07T11:41:15Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Properties */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Description ==&lt;br /&gt;
&lt;br /&gt;
Forms act as containers for controls. To go to a new form, use the [[ChangeForm]]() function.&lt;br /&gt;
&lt;br /&gt;
To add a Form to your app, choose Add Form from the Project menu at the top of the screen. Forms can be deleted in the Project Explorer.&lt;br /&gt;
&lt;br /&gt;
Scrolling forms are allowed, with a couple of notes. Footerbars won&#039;t work (since the bottom needs to scroll up), nor will scrolling controls (which confuse the scroller).&lt;br /&gt;
&lt;br /&gt;
The information on a form can be submitted to a URL by calling the form.submit() function. The values for all controls on the form which have their Name property defined will be appended to the URL as an HTML query string.&lt;br /&gt;
&lt;br /&gt;
== Properties ==&lt;br /&gt;
&lt;br /&gt;
Standard [[properties and methods|properties]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; &lt;br /&gt;
|-&lt;br /&gt;
| backgroundImage || Will override the background with a pattern or an image. &amp;lt;pre&amp;gt;linear-gradient(#55aaee, #003366);&amp;lt;/pre&amp;gt;&lt;br /&gt;
or&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
url(http://www.nsbasic.com/images/eiffel.gif);&amp;lt;/pre&amp;gt; &lt;br /&gt;
At runtime, you need to force a redraw:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  Form1.style.background=&amp;quot;red&amp;quot;&lt;br /&gt;
  Form1.style.width=&amp;quot;100%&amp;quot;  &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
To prevent the image from repeating to fill the full window, do this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  Page_jqm.style.backgroundRepeat = &amp;quot;no-repeat&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
If you are using jQuery Mobile, the best way to control the background color is to use themes. It will work better on PhoneGap Build.&lt;br /&gt;
|-&lt;br /&gt;
| fullscreen || True/False. If True, the form will automatically fill the entire device screen. The IDE will still use height and width at design time.&lt;br /&gt;
|-&lt;br /&gt;
| height || The height of the form in pixels. Default is 460.&lt;br /&gt;
|-&lt;br /&gt;
| left || The left position of the form. Use this for forms that are not full screen.&lt;br /&gt;
|-&lt;br /&gt;
| locked || If set to true, the controls on the Design Screen cannot be moved&lt;br /&gt;
|-&lt;br /&gt;
| language || The programming language used in the code for the form. Can be BASIC or JavaScript.&lt;br /&gt;
|-&lt;br /&gt;
| method || Get or Post. The method that the http form is sent by.&lt;br /&gt;
|-&lt;br /&gt;
| openMode || Should the form be open at startup? Use this for forms which are to remain open. There is no need to set this for the first form of the project: that is set in [[Properties Window|Project Properties]].&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| scroll_options || iScroll options. See iScroll docs at http://iscrolljs.com. &lt;br /&gt;
|-&lt;br /&gt;
| scrolling || Allow scrolling?&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| style || The CSS style for the form. &lt;br /&gt;
|-&lt;br /&gt;
| setFocusID || The control to get the focus when the form is shown.&lt;br /&gt;
|-&lt;br /&gt;
| Url || The URL to be called when the form is submitted using the submit() function.&lt;br /&gt;
|-&lt;br /&gt;
| width || The width of the form in pixels. Default is 320. Percents can be set at runtime.&lt;br /&gt;
|-&lt;br /&gt;
| reset() || Clear all fields on the form. Runtime only.&lt;br /&gt;
|-&lt;br /&gt;
| submit() || Submit the data on the form to the specified URL. Runtime only. See [[Location]] as well.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Events ==&lt;br /&gt;
&lt;br /&gt;
Standard [[events]] are supported, plus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| onhide() || Called when form hidden as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onkeypress(event) || Called when a key is tapped on a form.&lt;br /&gt;
|-&lt;br /&gt;
| onshow() || Called by firstform and when form is shown as a result of [[ChangeForm]]()&lt;br /&gt;
|-&lt;br /&gt;
| onsubmit() || Called when a form is submitted.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example (Basic) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function btnSendData_onclick()&lt;br /&gt;
  Form1.submit()&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent a form from being submitted when the return key is entered in a field:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function Form1_onsubmit(e)&lt;br /&gt;
  e.cancelBubble=True&lt;br /&gt;
  e.returnValue=False&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
btnSendData.onclick = function() {&lt;br /&gt;
  Form1.submit();&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To prevent a form from being submitted when the return key is entered in a field:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Form1.onsubmit = function(e) {&lt;br /&gt;
  e.cancelBubble=true;&lt;br /&gt;
  e.returnValue=false;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To change the background image on a form:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    Form1.style.backgroundImage=&amp;quot;url(https://www.nsbasic.com/images/lavalamp.gif)&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
(Url is called with values in the query string)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[changeform|ChangeForm]], [[geturlparameter|GetUrlParameter]], [[properties and methods|Properties]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Responsive_Design_Made_Simple&amp;diff=7129</id>
		<title>Responsive Design Made Simple</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Responsive_Design_Made_Simple&amp;diff=7129"/>
		<updated>2015-04-07T11:40:43Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Forms */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction ==&lt;br /&gt;
&lt;br /&gt;
Responsive web design (RWD) is a web design approach aimed at crafting sites to provide an optimal viewing experience—easy reading and navigation with a minimum of resizing, panning, and scrolling—across a wide range of devices (from desktop computer monitors to mobile phones). Responsive Web Design is a method of building websites that are highly functional on wide range of desktops &amp;amp; provide “app-like” experiences on smart phones, tablets and e-readers. Responsive design is a preferable alternative to bespoke mobile versions as modern mobile devices are not set to a standard resolution. Producing a specific site for several resolutions would be incredibly time consuming and near impossible to get right.&lt;br /&gt;
&lt;br /&gt;
Traditionally, developers have laid out app with controls in fixed places. Tools like Visual Studio made this easy: drag and drop your control where you want them on the design screen and they are fixed in place.&lt;br /&gt;
&lt;br /&gt;
Websites have the ability to resize and flow their elements to adjust to different screen sizes dynamically.&lt;br /&gt;
&lt;br /&gt;
RWD combines the two approaches. Developers can still layout the controls on their apps, but make them responsive to the screen size so they automatically adjust and reflow. In AppStudio 5, we have added the ability to use this in your apps.&lt;br /&gt;
&lt;br /&gt;
== A Simple Example ==&lt;br /&gt;
&lt;br /&gt;
Let&#039;s start with an example. We&#039;ll set up a [[Container]] which holds some buttons:&lt;br /&gt;
&lt;br /&gt;
Container on a narrow screen:&lt;br /&gt;
[[File:Rwd01.png||none|Container on a narrow screen]]&lt;br /&gt;
&lt;br /&gt;
The same container on a wide screen:&lt;br /&gt;
[[File:Rwd02.png||none|Container on a wide screen]]&lt;br /&gt;
&lt;br /&gt;
It&#039;s the same container. No code is involved: the controls move themselves into position based on the screen width. The height of the container is set to auto, so the border adjusts based on the height of its contents. You don&#039;t need to have a border.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;How does this work?&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
One of the style attributes of any control is position. Before AppStudio 5, the only option for this was &#039;absolute&#039;. It can now also be &#039;relative&#039;. By default, all controls in a container have position set to &#039;relative&#039;. Forms also have this option: if position is set to relative, the controls on the form will all have their position set to relative.&lt;br /&gt;
&lt;br /&gt;
The rest of the positioning for the controls is set in the style property of the controls. To center all the controls in the container, we add this to the Container&#039;s style control:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
text-align:center; margin:auto;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For each button, style is set to &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
margin: 6px;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This forces a 6 pixel margin around each control.&lt;br /&gt;
&lt;br /&gt;
== A Detailed Example ==&lt;br /&gt;
&lt;br /&gt;
=== Add a couple of controls ===&lt;br /&gt;
&lt;br /&gt;
Let&#039;s start a new project with some labels and input fields. First, add a container, a label and a textbox.&lt;br /&gt;
&lt;br /&gt;
[[File:Rwd03.png]]&lt;br /&gt;
&lt;br /&gt;
* Select Container1 and right click on it. A list of possible children is displayed. Choose Label1.&lt;br /&gt;
* Do the same with TextBox1. &lt;br /&gt;
* Your Design Screen should now look like this:&lt;br /&gt;
&lt;br /&gt;
[[File:Rwd04.png]]&lt;br /&gt;
&lt;br /&gt;
* AppStudio makes some changes to the styling of Label1 and TextBox1 when it adds them to the container, so they will be well behaved responsive elements.&lt;br /&gt;
* The left and top properties are changed to &#039;initial&#039;, which lets them flow to where the browser sends them. &lt;br /&gt;
* The style property has the string &amp;quot;float:left;&amp;quot; added to it. This makes the controls float to the left as far as possible.&lt;br /&gt;
* Label1 floats to the left margin.&lt;br /&gt;
* TextBox1 floats to the left until it hits Label1.&lt;br /&gt;
&lt;br /&gt;
=== Add some Classes ===&lt;br /&gt;
&lt;br /&gt;
We plan to add a number of labels and textboxes beneath the first two. There are a number of style properties we need to set for each one. Let&#039;s make it easy on ourselves by using Classes.&lt;br /&gt;
&lt;br /&gt;
A Class is a collection of style properties. By adding the name of the Class into an control&#039;s class property, the control will automatically get the style properties of the class. It&#039;s a big timesaver. It&#039;s also easier to make a single change to a class than to modify every control. Controls can have multiple classes.&lt;br /&gt;
&lt;br /&gt;
* Open an editor window for &#039;styleheaders&#039; in Project Properties. Enter the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.myLabel {&lt;br /&gt;
  width: 120px !important; &lt;br /&gt;
  height: 30px !important; &lt;br /&gt;
  margin: 6px !important;&lt;br /&gt;
  line-height: 30px;&lt;br /&gt;
}&lt;br /&gt;
  &lt;br /&gt;
.myTextbox {&lt;br /&gt;
  width: 120px !important;&lt;br /&gt;
  margin: 6px !important;&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The above is in CSS ([http://en.wikipedia.org/wiki/Cascading_Style_Sheets Cascading Style Sheets]) format. It&#039;s a very powerful tool. The above statements set style properties. You can see the complete list [http://www.w3schools.com/cssref/ here]. &lt;br /&gt;
&lt;br /&gt;
Each rule starts with an identifer, followed by a list of styles wrapped in curly braces. The identifier indicates which controls will be affected by the rule. There are many options for identifiers, but here are a few important ones:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Identitier !! Applies to&lt;br /&gt;
|-&lt;br /&gt;
| .myClass || Any control which has &#039;myclass&#039; in its class property&lt;br /&gt;
|-&lt;br /&gt;
| #PictureBox1 || A control with the id of PictureBox1&lt;br /&gt;
|-&lt;br /&gt;
| button || Any element of type button.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Elements assemble their style attributes from a number of places. If the control is based on jQuery Mobile, it may have several classes already defined. AppStudio also applies some, based on the control&#039;s properties and definition. By putting !important after one of the properties, we indicate that we want this one to override any values for the same property.&lt;br /&gt;
 &lt;br /&gt;
* In the class property of Label1, enter myLabel.&lt;br /&gt;
* In the class property of Label2, enter myTextBox.&lt;br /&gt;
* Now, repeat this a few more times, adding labels and textboxes. &lt;br /&gt;
* You should end up with this:&lt;br /&gt;
&lt;br /&gt;
[[File:Rwd05.png]]&lt;br /&gt;
&lt;br /&gt;
== Forms ==&lt;br /&gt;
&lt;br /&gt;
So far, we have worked with Containers. The same techniques will work on [[Form|forms]]. Forms have a position property. If that is set to &#039;relative&#039;, all controls on that form will use relative positioning.&lt;br /&gt;
&lt;br /&gt;
== Media Queries ==&lt;br /&gt;
&lt;br /&gt;
[http://en.wikipedia.org/wiki/Media_queries Media Queries] are simple filters that can be applied to CSS styles. They make it easy to change styles based on the characteristics of the device rendering the content, including the display type, width, height, orientation and even resolution.&lt;br /&gt;
&lt;br /&gt;
Here&#039;s a simple example of how you would use a Media Query to adjust your app if it was running in Portrait or Landscape mode:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
@media (orientation=portrait) {&lt;br /&gt;
  #PictureBox1 {width:300px; height: 200px}&lt;br /&gt;
}&lt;br /&gt;
@media (orientation=landscape) {&lt;br /&gt;
  #PictureBox1 {width:600px; height: 400px}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
These rules draw the PictureBox1 in different sizes depending on the screen orientation.&lt;br /&gt;
&lt;br /&gt;
Here are the attributes you can test in a media query:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! attribute !! Result&lt;br /&gt;
|-&lt;br /&gt;
| min-width || Rules applied for any browser width over the value defined in the query.&lt;br /&gt;
|-&lt;br /&gt;
| max-width || Rules applied for any browser width below the value defined in the query.&lt;br /&gt;
|-&lt;br /&gt;
| min-height || Rules applied for any browser height over the value defined in the query.&lt;br /&gt;
|-&lt;br /&gt;
| max-height || Rules applied for any browser height below the value defined in the query.&lt;br /&gt;
|-&lt;br /&gt;
| orientation=portrait || Rules applied for any browser where the height is greater than or equal to the width.&lt;br /&gt;
|-&lt;br /&gt;
| orientation=landscape || Rules for any browser where the width is greater than the height.&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6591</id>
		<title>ServerStorage</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6591"/>
		<updated>2014-11-06T16:33:15Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Output */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;serverStorage(&#039;&#039;string&#039;&#039; | &#039;&#039;variable&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
ServerStorage allows you to save string data on the server so it is available next time you run the program. An entry can be created by assigning to serverStorage.setItem(&#039;&#039;variableName&#039;&#039;, &#039;&#039;value&#039;&#039;), where &#039;&#039;variableName&#039;&#039; is chosen by you. Data is retrieved a similar way. &lt;br /&gt;
&lt;br /&gt;
By default, the data is saved into a namespace with the same name as the app&#039;s ID. It can be set to any string, even that of another app, making it possible for apps to share data. &lt;br /&gt;
&lt;br /&gt;
ServerStorage is insecure: there is currently no protection against other apps reading or changing the data.&lt;br /&gt;
&lt;br /&gt;
This feature is currently experimental. It only works on apps deployed to nsbapp.com. It will not work locally or on your server at this time. Since the data is on the nsbapp.com test server, do not assume that data you save will be permanently available.&lt;br /&gt;
&lt;br /&gt;
== Properties and Methods ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| clear() || Clear all entries in the current namespace.&lt;br /&gt;
|-&lt;br /&gt;
| deleteItem(&#039;&#039;key&#039;&#039;) || Deletes item &#039;&#039;key&#039;&#039;.&lt;br /&gt;
|-&lt;br /&gt;
| getItem(&#039;&#039;key&#039;&#039;) || Get the item which is saved under &#039;&#039;key&#039;&#039;. String.&lt;br /&gt;
|-&lt;br /&gt;
| key(&#039;&#039;n&#039;&#039;) || Get the &#039;&#039;n&#039;&#039;th item in the namespace.&lt;br /&gt;
|-&lt;br /&gt;
| length || The number of items in the current namespace.&lt;br /&gt;
|-&lt;br /&gt;
| namespace || The group used by all serverStorage methods. Defaults to app ID. &lt;br /&gt;
|-&lt;br /&gt;
| setItem(&#039;&#039;key&#039;&#039;, &#039;&#039;value&#039;&#039;) || Sets item &#039;&#039;key&#039;&#039; to &#039;&#039;value&#039;&#039;. Creates item if it does not exist.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example - BASIC ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Sub Main()&lt;br /&gt;
  NameSpace.text = serverStorage.namespace&lt;br /&gt;
End Sub&lt;br /&gt;
&lt;br /&gt;
Function Button1_onclick()&lt;br /&gt;
  t=SysInfo(10)&lt;br /&gt;
  For i = 1 To 10&lt;br /&gt;
    serverStorage.setItem(&amp;quot;item&amp;quot; &amp;amp; i, i)&lt;br /&gt;
  Next&lt;br /&gt;
  MsgBox &amp;quot;Write 10 items into serverStorage(secs): &amp;quot; &amp;amp;  (SysInfo(10)-t)/1000&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Function Button2_onclick()&lt;br /&gt;
  NSB.Print(False)&lt;br /&gt;
  For i=0 To serverStorage.length-1&lt;br /&gt;
    key = serverStorage.key(i)&lt;br /&gt;
    Print key, serverStorage.getItem(key)&lt;br /&gt;
  Next&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Function Button3_onclick()&lt;br /&gt;
  serverStorage.clear()&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example - JavaScript ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
function Main() {&lt;br /&gt;
  NameSpace.text = serverStorage.namespace;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Button1.onclick = function() {&lt;br /&gt;
  t=SysInfo(10);&lt;br /&gt;
  for   (i = 1; i  &amp;lt;= 10; i ++) {&lt;br /&gt;
    serverStorage.setItem(&amp;quot;item&amp;quot;  +  i, i);&lt;br /&gt;
  }&lt;br /&gt;
  alert(&amp;quot;Write 10 items into serverStorage(secs): &amp;quot;  +   (SysInfo(10)-t)/1000);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Button2.onclick = function() { &lt;br /&gt;
  NSB.Print(False);&lt;br /&gt;
  for   (i=0; i &amp;lt;= serverStorage.length-1; i++) {&lt;br /&gt;
    key = serverStorage.key(i);&lt;br /&gt;
    NSB.Print((key+ &amp;quot; &amp;quot; + serverStorage.getItem(key)) + &amp;quot;&amp;lt;br&amp;gt;&amp;quot;);&lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Button3.onclick = function() {&lt;br /&gt;
  serverStorage.clear();&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
(see serverStorage sample)&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[localstorage|LocalStorage]], [[sessionstorage|SessionStorage]], [[sql|SQL]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6590</id>
		<title>ServerStorage</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6590"/>
		<updated>2014-11-06T16:32:38Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;serverStorage(&#039;&#039;string&#039;&#039; | &#039;&#039;variable&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
ServerStorage allows you to save string data on the server so it is available next time you run the program. An entry can be created by assigning to serverStorage.setItem(&#039;&#039;variableName&#039;&#039;, &#039;&#039;value&#039;&#039;), where &#039;&#039;variableName&#039;&#039; is chosen by you. Data is retrieved a similar way. &lt;br /&gt;
&lt;br /&gt;
By default, the data is saved into a namespace with the same name as the app&#039;s ID. It can be set to any string, even that of another app, making it possible for apps to share data. &lt;br /&gt;
&lt;br /&gt;
ServerStorage is insecure: there is currently no protection against other apps reading or changing the data.&lt;br /&gt;
&lt;br /&gt;
This feature is currently experimental. It only works on apps deployed to nsbapp.com. It will not work locally or on your server at this time. Since the data is on the nsbapp.com test server, do not assume that data you save will be permanently available.&lt;br /&gt;
&lt;br /&gt;
== Properties and Methods ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| clear() || Clear all entries in the current namespace.&lt;br /&gt;
|-&lt;br /&gt;
| deleteItem(&#039;&#039;key&#039;&#039;) || Deletes item &#039;&#039;key&#039;&#039;.&lt;br /&gt;
|-&lt;br /&gt;
| getItem(&#039;&#039;key&#039;&#039;) || Get the item which is saved under &#039;&#039;key&#039;&#039;. String.&lt;br /&gt;
|-&lt;br /&gt;
| key(&#039;&#039;n&#039;&#039;) || Get the &#039;&#039;n&#039;&#039;th item in the namespace.&lt;br /&gt;
|-&lt;br /&gt;
| length || The number of items in the current namespace.&lt;br /&gt;
|-&lt;br /&gt;
| namespace || The group used by all serverStorage methods. Defaults to app ID. &lt;br /&gt;
|-&lt;br /&gt;
| setItem(&#039;&#039;key&#039;&#039;, &#039;&#039;value&#039;&#039;) || Sets item &#039;&#039;key&#039;&#039; to &#039;&#039;value&#039;&#039;. Creates item if it does not exist.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example - BASIC ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Sub Main()&lt;br /&gt;
  NameSpace.text = serverStorage.namespace&lt;br /&gt;
End Sub&lt;br /&gt;
&lt;br /&gt;
Function Button1_onclick()&lt;br /&gt;
  t=SysInfo(10)&lt;br /&gt;
  For i = 1 To 10&lt;br /&gt;
    serverStorage.setItem(&amp;quot;item&amp;quot; &amp;amp; i, i)&lt;br /&gt;
  Next&lt;br /&gt;
  MsgBox &amp;quot;Write 10 items into serverStorage(secs): &amp;quot; &amp;amp;  (SysInfo(10)-t)/1000&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Function Button2_onclick()&lt;br /&gt;
  NSB.Print(False)&lt;br /&gt;
  For i=0 To serverStorage.length-1&lt;br /&gt;
    key = serverStorage.key(i)&lt;br /&gt;
    Print key, serverStorage.getItem(key)&lt;br /&gt;
  Next&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Function Button3_onclick()&lt;br /&gt;
  serverStorage.clear()&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example - JavaScript ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
function Main() {&lt;br /&gt;
  NameSpace.text = serverStorage.namespace;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Button1.onclick = function() {&lt;br /&gt;
  t=SysInfo(10);&lt;br /&gt;
  for   (i = 1; i  &amp;lt;= 10; i ++) {&lt;br /&gt;
    serverStorage.setItem(&amp;quot;item&amp;quot;  +  i, i);&lt;br /&gt;
  }&lt;br /&gt;
  alert(&amp;quot;Write 10 items into serverStorage(secs): &amp;quot;  +   (SysInfo(10)-t)/1000);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Button2.onclick = function() { &lt;br /&gt;
  NSB.Print(False);&lt;br /&gt;
  for   (i=0; i &amp;lt;= serverStorage.length-1; i++) {&lt;br /&gt;
    key = serverStorage.key(i);&lt;br /&gt;
    NSB.Print((key+ &amp;quot; &amp;quot; + serverStorage.getItem(key)) + &amp;quot;&amp;lt;br&amp;gt;&amp;quot;);&lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Button3.onclick = function() {&lt;br /&gt;
  serverStorage.clear();&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
This is Data.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[localstorage|LocalStorage]], [[sessionstorage|SessionStorage]], [[sql|SQL]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6589</id>
		<title>ServerStorage</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6589"/>
		<updated>2014-11-06T16:30:32Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Example */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;serverStorage(&#039;&#039;string&#039;&#039; | &#039;&#039;variable&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
ServerStorage allows you to save string data on the server so it is available next time you run the program. An entry can be created by assigning to serverStorage.setItem(&#039;&#039;variableName&#039;&#039;, &#039;&#039;value&#039;&#039;), where &#039;&#039;variableName&#039;&#039; is chosen by you. Data is retrieved a similar way. &lt;br /&gt;
&lt;br /&gt;
By default, the data is saved into a namespace with the same name as the app&#039;s ID. It can be set to any string, even that of another app, making it possible for apps to share data. &lt;br /&gt;
&lt;br /&gt;
ServerStorage is insecure: there is currently no protection against other apps reading or changing the data.&lt;br /&gt;
&lt;br /&gt;
This feature is currently experimental. It only works on apps deployed to nsbapp.com. It will not work locally or on your server at this time. Since the data is on the nsbapp.com test server, do not assume that data you save will be permanently available.&lt;br /&gt;
&lt;br /&gt;
== Properties and Methods ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| clear() || Clear all entries in the current namespace.&lt;br /&gt;
|-&lt;br /&gt;
| deleteItem(&#039;&#039;key&#039;&#039;) || Deletes item &#039;&#039;key&#039;&#039;.&lt;br /&gt;
|-&lt;br /&gt;
| getItem(&#039;&#039;key&#039;&#039;) || Get the item which is saved under &#039;&#039;key&#039;&#039;. String.&lt;br /&gt;
|-&lt;br /&gt;
| key(&#039;&#039;n&#039;&#039;) || Get the &#039;&#039;n&#039;&#039;th item in the namespace.&lt;br /&gt;
|-&lt;br /&gt;
| length || The number of items in the current namespace.&lt;br /&gt;
|-&lt;br /&gt;
| namespace || The group used by all serverStorage methods. Defaults to app ID. &lt;br /&gt;
|-&lt;br /&gt;
| setItem(&#039;&#039;key&#039;&#039;, &#039;&#039;value&#039;&#039;) || Sets item &#039;&#039;key&#039;&#039; to &#039;&#039;value&#039;&#039;. Creates item if it does not exist.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Sub Main()&lt;br /&gt;
  NameSpace.text = serverStorage.namespace&lt;br /&gt;
End Sub&lt;br /&gt;
&lt;br /&gt;
Function Button1_onclick()&lt;br /&gt;
  t=SysInfo(10)&lt;br /&gt;
  For i = 1 To 10&lt;br /&gt;
    serverStorage.setItem(&amp;quot;item&amp;quot; &amp;amp; i, i)&lt;br /&gt;
  Next&lt;br /&gt;
  MsgBox &amp;quot;Write 10 items into serverStorage(secs): &amp;quot; &amp;amp;  (SysInfo(10)-t)/1000&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Function Button2_onclick()&lt;br /&gt;
  NSB.Print(False)&lt;br /&gt;
  For i=0 To serverStorage.length-1&lt;br /&gt;
    key = serverStorage.key(i)&lt;br /&gt;
    Print key, serverStorage.getItem(key)&lt;br /&gt;
  Next&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Function Button3_onclick()&lt;br /&gt;
  serverStorage.clear()&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
This is Data.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[localstorage|LocalStorage]], [[sessionstorage|SessionStorage]], [[sql|SQL]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6588</id>
		<title>ServerStorage</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6588"/>
		<updated>2014-11-06T16:29:01Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Description */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;serverStorage(&#039;&#039;string&#039;&#039; | &#039;&#039;variable&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
ServerStorage allows you to save string data on the server so it is available next time you run the program. An entry can be created by assigning to serverStorage.setItem(&#039;&#039;variableName&#039;&#039;, &#039;&#039;value&#039;&#039;), where &#039;&#039;variableName&#039;&#039; is chosen by you. Data is retrieved a similar way. &lt;br /&gt;
&lt;br /&gt;
By default, the data is saved into a namespace with the same name as the app&#039;s ID. It can be set to any string, even that of another app, making it possible for apps to share data. &lt;br /&gt;
&lt;br /&gt;
ServerStorage is insecure: there is currently no protection against other apps reading or changing the data.&lt;br /&gt;
&lt;br /&gt;
This feature is currently experimental. It only works on apps deployed to nsbapp.com. It will not work locally or on your server at this time. Since the data is on the nsbapp.com test server, do not assume that data you save will be permanently available.&lt;br /&gt;
&lt;br /&gt;
== Properties and Methods ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| clear() || Clear all entries in the current namespace.&lt;br /&gt;
|-&lt;br /&gt;
| deleteItem(&#039;&#039;key&#039;&#039;) || Deletes item &#039;&#039;key&#039;&#039;.&lt;br /&gt;
|-&lt;br /&gt;
| getItem(&#039;&#039;key&#039;&#039;) || Get the item which is saved under &#039;&#039;key&#039;&#039;. String.&lt;br /&gt;
|-&lt;br /&gt;
| key(&#039;&#039;n&#039;&#039;) || Get the &#039;&#039;n&#039;&#039;th item in the namespace.&lt;br /&gt;
|-&lt;br /&gt;
| length || The number of items in the current namespace.&lt;br /&gt;
|-&lt;br /&gt;
| namespace || The group used by all serverStorage methods. Defaults to app ID. &lt;br /&gt;
|-&lt;br /&gt;
| setItem(&#039;&#039;key&#039;&#039;, &#039;&#039;value&#039;&#039;) || Sets item &#039;&#039;key&#039;&#039; to &#039;&#039;value&#039;&#039;. Creates item if it does not exist.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Rem serverStorage Save Example&lt;br /&gt;
serverStorage.data = &amp;quot;This is Data.&amp;quot;&lt;br /&gt;
(run and exit program)&lt;br /&gt;
Rem serverStorage Retrieve Example&lt;br /&gt;
Print serverStorage.data&lt;br /&gt;
 &lt;br /&gt;
Rem Test if Private Browsing is turned on&lt;br /&gt;
Try&lt;br /&gt;
  serverStorage.private = &amp;quot;test&amp;quot;&lt;br /&gt;
Catch err&lt;br /&gt;
   MsgBox &amp;quot;Please turn Private Browsing off&amp;quot;    &lt;br /&gt;
End Try&lt;br /&gt;
&lt;br /&gt;
Rem Some additional samples:&lt;br /&gt;
serverStorage.setItem(&amp;quot;key&amp;quot;, value) &#039;creates serverStorage.key with defined value&lt;br /&gt;
serverStorage[&amp;quot;key&amp;quot;] = value &#039;alternative method for above&lt;br /&gt;
serverStorage.getItem(&amp;quot;key&amp;quot;) &#039;calls serverStorage.key...useful to check if it exists &lt;br /&gt;
serverStorage.removeItem(&amp;quot;key&amp;quot;) &#039;deletes serverStorage.key&lt;br /&gt;
delete serverStorage.key &#039;alternative method for above&lt;br /&gt;
delete serverStorage[&amp;quot;key&amp;quot;] &#039;another alternative method for above&lt;br /&gt;
serverStorage.clear() &#039;nuclear deletion of all serverStorage variables in the domain. Use with care.&lt;br /&gt;
serverStorage[DBRecords.rows.item(0)[&amp;quot;ModsType&amp;quot;]] = &amp;quot;alpha&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
This is Data.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[localstorage|LocalStorage]], [[sessionstorage|SessionStorage]], [[sql|SQL]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6587</id>
		<title>ServerStorage</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6587"/>
		<updated>2014-11-06T16:24:59Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Properties and Methods */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;serverStorage(&#039;&#039;string&#039;&#039; | &#039;&#039;variable&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
serverStorage allows you to save string data on the server so it is available next time you run the program. An entry can be created by assigning to serverStorage.setItem(&#039;&#039;variableName&#039;&#039;, &#039;&#039;value&#039;&#039;), where &#039;&#039;variableName&#039;&#039; is chosen by you. Data is retrieved the same way. &lt;br /&gt;
&lt;br /&gt;
serverStorage is shared among all apps deployed from the same web server. This can be useful if you have a family of apps which need to share data.&lt;br /&gt;
&lt;br /&gt;
This feature is currently experimental. It only works on apps deployed to nsbapp.com. It will not work locally or on your server at this time. Since the data is on the nsbapp.com test server, do not assume that data you save will be permanently available.&lt;br /&gt;
&lt;br /&gt;
== Properties and Methods ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| clear() || Clear all entries in the current namespace.&lt;br /&gt;
|-&lt;br /&gt;
| deleteItem(&#039;&#039;key&#039;&#039;) || Deletes item &#039;&#039;key&#039;&#039;.&lt;br /&gt;
|-&lt;br /&gt;
| getItem(&#039;&#039;key&#039;&#039;) || Get the item which is saved under &#039;&#039;key&#039;&#039;. String.&lt;br /&gt;
|-&lt;br /&gt;
| key(&#039;&#039;n&#039;&#039;) || Get the &#039;&#039;n&#039;&#039;th item in the namespace.&lt;br /&gt;
|-&lt;br /&gt;
| length || The number of items in the current namespace.&lt;br /&gt;
|-&lt;br /&gt;
| namespace || The group used by all serverStorage methods. Defaults to app ID. &lt;br /&gt;
|-&lt;br /&gt;
| setItem(&#039;&#039;key&#039;&#039;, &#039;&#039;value&#039;&#039;) || Sets item &#039;&#039;key&#039;&#039; to &#039;&#039;value&#039;&#039;. Creates item if it does not exist.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Rem serverStorage Save Example&lt;br /&gt;
serverStorage.data = &amp;quot;This is Data.&amp;quot;&lt;br /&gt;
(run and exit program)&lt;br /&gt;
Rem serverStorage Retrieve Example&lt;br /&gt;
Print serverStorage.data&lt;br /&gt;
 &lt;br /&gt;
Rem Test if Private Browsing is turned on&lt;br /&gt;
Try&lt;br /&gt;
  serverStorage.private = &amp;quot;test&amp;quot;&lt;br /&gt;
Catch err&lt;br /&gt;
   MsgBox &amp;quot;Please turn Private Browsing off&amp;quot;    &lt;br /&gt;
End Try&lt;br /&gt;
&lt;br /&gt;
Rem Some additional samples:&lt;br /&gt;
serverStorage.setItem(&amp;quot;key&amp;quot;, value) &#039;creates serverStorage.key with defined value&lt;br /&gt;
serverStorage[&amp;quot;key&amp;quot;] = value &#039;alternative method for above&lt;br /&gt;
serverStorage.getItem(&amp;quot;key&amp;quot;) &#039;calls serverStorage.key...useful to check if it exists &lt;br /&gt;
serverStorage.removeItem(&amp;quot;key&amp;quot;) &#039;deletes serverStorage.key&lt;br /&gt;
delete serverStorage.key &#039;alternative method for above&lt;br /&gt;
delete serverStorage[&amp;quot;key&amp;quot;] &#039;another alternative method for above&lt;br /&gt;
serverStorage.clear() &#039;nuclear deletion of all serverStorage variables in the domain. Use with care.&lt;br /&gt;
serverStorage[DBRecords.rows.item(0)[&amp;quot;ModsType&amp;quot;]] = &amp;quot;alpha&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
This is Data.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[localstorage|LocalStorage]], [[sessionstorage|SessionStorage]], [[sql|SQL]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6586</id>
		<title>ServerStorage</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6586"/>
		<updated>2014-11-06T16:19:26Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Properties and Methods */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;serverStorage(&#039;&#039;string&#039;&#039; | &#039;&#039;variable&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
serverStorage allows you to save string data on the server so it is available next time you run the program. An entry can be created by assigning to serverStorage.setItem(&#039;&#039;variableName&#039;&#039;, &#039;&#039;value&#039;&#039;), where &#039;&#039;variableName&#039;&#039; is chosen by you. Data is retrieved the same way. &lt;br /&gt;
&lt;br /&gt;
serverStorage is shared among all apps deployed from the same web server. This can be useful if you have a family of apps which need to share data.&lt;br /&gt;
&lt;br /&gt;
This feature is currently experimental. It only works on apps deployed to nsbapp.com. It will not work locally or on your server at this time. Since the data is on the nsbapp.com test server, do not assume that data you save will be permanently available.&lt;br /&gt;
&lt;br /&gt;
== Properties and Methods ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| clear() || The name of the form to go to if this button is clicked.&lt;br /&gt;
|-&lt;br /&gt;
| getItem(key) || round or square. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| key(n) || If you have a group of buttons, set this to Start Vertical, Start Horizontal, Start Vertical Mini or start Horizontal Mini. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| length || If you have a group of buttons, set this to Yes on the last one. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| namespace || Set to false for no icon. You have a choice of 18 standard icons otherwise. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| setItem(key, value) || Position of the icon. Can be none, left, right, top, bottom or notext. jQuery Mobile only.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Rem serverStorage Save Example&lt;br /&gt;
serverStorage.data = &amp;quot;This is Data.&amp;quot;&lt;br /&gt;
(run and exit program)&lt;br /&gt;
Rem serverStorage Retrieve Example&lt;br /&gt;
Print serverStorage.data&lt;br /&gt;
 &lt;br /&gt;
Rem Test if Private Browsing is turned on&lt;br /&gt;
Try&lt;br /&gt;
  serverStorage.private = &amp;quot;test&amp;quot;&lt;br /&gt;
Catch err&lt;br /&gt;
   MsgBox &amp;quot;Please turn Private Browsing off&amp;quot;    &lt;br /&gt;
End Try&lt;br /&gt;
&lt;br /&gt;
Rem Some additional samples:&lt;br /&gt;
serverStorage.setItem(&amp;quot;key&amp;quot;, value) &#039;creates serverStorage.key with defined value&lt;br /&gt;
serverStorage[&amp;quot;key&amp;quot;] = value &#039;alternative method for above&lt;br /&gt;
serverStorage.getItem(&amp;quot;key&amp;quot;) &#039;calls serverStorage.key...useful to check if it exists &lt;br /&gt;
serverStorage.removeItem(&amp;quot;key&amp;quot;) &#039;deletes serverStorage.key&lt;br /&gt;
delete serverStorage.key &#039;alternative method for above&lt;br /&gt;
delete serverStorage[&amp;quot;key&amp;quot;] &#039;another alternative method for above&lt;br /&gt;
serverStorage.clear() &#039;nuclear deletion of all serverStorage variables in the domain. Use with care.&lt;br /&gt;
serverStorage[DBRecords.rows.item(0)[&amp;quot;ModsType&amp;quot;]] = &amp;quot;alpha&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
This is Data.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[localstorage|LocalStorage]], [[sessionstorage|SessionStorage]], [[sql|SQL]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6585</id>
		<title>ServerStorage</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=ServerStorage&amp;diff=6585"/>
		<updated>2014-11-06T16:18:53Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Description */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;serverStorage(&#039;&#039;string&#039;&#039; | &#039;&#039;variable&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
serverStorage allows you to save string data on the server so it is available next time you run the program. An entry can be created by assigning to serverStorage.setItem(&#039;&#039;variableName&#039;&#039;, &#039;&#039;value&#039;&#039;), where &#039;&#039;variableName&#039;&#039; is chosen by you. Data is retrieved the same way. &lt;br /&gt;
&lt;br /&gt;
serverStorage is shared among all apps deployed from the same web server. This can be useful if you have a family of apps which need to share data.&lt;br /&gt;
&lt;br /&gt;
This feature is currently experimental. It only works on apps deployed to nsbapp.com. It will not work locally or on your server at this time. Since the data is on the nsbapp.com test server, do not assume that data you save will be permanently available.&lt;br /&gt;
&lt;br /&gt;
== Properties and Methods ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| clear() || The name of the form to go to if this button is clicked.&lt;br /&gt;
|-&lt;br /&gt;
| getItem(key) || round or square. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| key(n) || If you have a group of buttons, set this to Start Vertical, Start Horizontal, Start Vertical Mini or start Horizontal Mini. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| length || If you have a group of buttons, set this to Yes on the last one. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| namespace || Set to false for no icon. You have a choice of 18 standard icons otherwise. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| setItem(key, value) || Position of the icon. Can be none, left, right, top, bottom or notext. jQuery Mobile only.&lt;br /&gt;
||}&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Rem serverStorage Save Example&lt;br /&gt;
serverStorage.data = &amp;quot;This is Data.&amp;quot;&lt;br /&gt;
(run and exit program)&lt;br /&gt;
Rem serverStorage Retrieve Example&lt;br /&gt;
Print serverStorage.data&lt;br /&gt;
 &lt;br /&gt;
Rem Test if Private Browsing is turned on&lt;br /&gt;
Try&lt;br /&gt;
  serverStorage.private = &amp;quot;test&amp;quot;&lt;br /&gt;
Catch err&lt;br /&gt;
   MsgBox &amp;quot;Please turn Private Browsing off&amp;quot;    &lt;br /&gt;
End Try&lt;br /&gt;
&lt;br /&gt;
Rem Some additional samples:&lt;br /&gt;
serverStorage.setItem(&amp;quot;key&amp;quot;, value) &#039;creates serverStorage.key with defined value&lt;br /&gt;
serverStorage[&amp;quot;key&amp;quot;] = value &#039;alternative method for above&lt;br /&gt;
serverStorage.getItem(&amp;quot;key&amp;quot;) &#039;calls serverStorage.key...useful to check if it exists &lt;br /&gt;
serverStorage.removeItem(&amp;quot;key&amp;quot;) &#039;deletes serverStorage.key&lt;br /&gt;
delete serverStorage.key &#039;alternative method for above&lt;br /&gt;
delete serverStorage[&amp;quot;key&amp;quot;] &#039;another alternative method for above&lt;br /&gt;
serverStorage.clear() &#039;nuclear deletion of all serverStorage variables in the domain. Use with care.&lt;br /&gt;
serverStorage[DBRecords.rows.item(0)[&amp;quot;ModsType&amp;quot;]] = &amp;quot;alpha&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
This is Data.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[localstorage|LocalStorage]], [[sessionstorage|SessionStorage]], [[sql|SQL]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Format&amp;diff=5748</id>
		<title>Format</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Format&amp;diff=5748"/>
		<updated>2014-04-02T16:40:48Z</updated>

		<summary type="html">&lt;p&gt;Admin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Format(&#039;&#039;string&#039;&#039;, &#039;&#039;replace0&#039;&#039;[,&#039;&#039;replace1&#039;&#039;...])&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
Replaces {n} placeholders with arguments. One or more arguments can be passed, in addition to the string itself, to insert into the string.&lt;br /&gt;
== Example (Basic) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Print Format(&amp;quot;1{0}2&amp;quot;,&amp;quot;a&amp;quot;)&lt;br /&gt;
Print Format(&amp;quot;My name is {0} and I live in {1}.&amp;quot;, &amp;quot;Cartman&amp;quot;, &amp;quot;South Park&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
NSB.Print(Format(&amp;quot;1{0}2&amp;quot;,&amp;quot;a&amp;quot;));&lt;br /&gt;
NSB.Print(Format(&amp;quot;My name is {0} and I live in {1}.&amp;quot;, &amp;quot;Cartman&amp;quot;, &amp;quot;South Park&amp;quot;));&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
1a2&lt;br /&gt;
My name is Cartman and I live in South Park.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Strings]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Format&amp;diff=5747</id>
		<title>Format</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Format&amp;diff=5747"/>
		<updated>2014-04-02T16:40:17Z</updated>

		<summary type="html">&lt;p&gt;Admin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Format(&#039;&#039;string&#039;&#039;, &#039;&#039;replace0&#039;&#039;[,&#039;&#039;replace1&#039;&#039;...])&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
Replaces {n} placeholders with arguments. One or more arguments can be passed, in addition to the string template itself, to insert into the string.&lt;br /&gt;
== Example (Basic) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Print Format(&amp;quot;1{0}2&amp;quot;,&amp;quot;a&amp;quot;)&lt;br /&gt;
Print Format(&amp;quot;My name is {0} and I live in {1}.&amp;quot;, &amp;quot;Cartman&amp;quot;, &amp;quot;South Park&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
NSB.Print(Format(&amp;quot;1{0}2&amp;quot;,&amp;quot;a&amp;quot;));&lt;br /&gt;
NSB.Print(Format(&amp;quot;My name is {0} and I live in {1}.&amp;quot;, &amp;quot;Cartman&amp;quot;, &amp;quot;South Park&amp;quot;));&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
1a2&lt;br /&gt;
My name is Cartman and I live in South Park.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Strings]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Format&amp;diff=5746</id>
		<title>Format</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Format&amp;diff=5746"/>
		<updated>2014-04-02T16:39:59Z</updated>

		<summary type="html">&lt;p&gt;Admin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Format(&#039;&#039;string&#039;&#039;, &#039;&#039;replace0&#039;&#039;[,&#039;&#039;replace1&#039;&#039;...])&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
Replaces {n} placeholders with arguments. One or more arguments can be passed, in addition to the string template itself, to insert into the string.&lt;br /&gt;
== Example (Basic) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Print Format(&amp;quot;1{0}2&amp;quot;,&amp;quot;a&amp;quot;)&lt;br /&gt;
Print Format(&amp;quot;My name is {0} and I live in {1}.&amp;quot;, &amp;quot;Cartman&amp;quot;, &amp;quot;South Park&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Print(Format(&amp;quot;1{0}2&amp;quot;,&amp;quot;a&amp;quot;));&lt;br /&gt;
Print(Format(&amp;quot;My name is {0} and I live in {1}.&amp;quot;, &amp;quot;Cartman&amp;quot;, &amp;quot;South Park&amp;quot;));&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
1a2&lt;br /&gt;
My name is Cartman and I live in South Park.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Strings]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Format&amp;diff=5745</id>
		<title>Format</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Format&amp;diff=5745"/>
		<updated>2014-04-02T16:39:16Z</updated>

		<summary type="html">&lt;p&gt;Admin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Format(&#039;&#039;string&#039;&#039;, &#039;&#039;replace0&#039;&#039;[,&#039;&#039;replace1&#039;&#039;...])&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
Replaces {n} placeholders with arguments. One or more arguments can be passed, in addition to the string template itself, to insert into the string.&lt;br /&gt;
== Example (Basic) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Print Format(&amp;quot;1{0}2&amp;quot;,&amp;quot;a&amp;quot;)&lt;br /&gt;
Print Format(&amp;quot;My name is {0} and I live in {1}.&amp;quot;, &amp;quot;Kartman&amp;quot;, &amp;quot;South Park&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Example (JavaScript) ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
NSB.Print(FormatCurrency(-3.5, 2, 0, true));&lt;br /&gt;
NSB.Print(FormatCurrency(123456, 2, true, false, true));&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Output ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
1a2&lt;br /&gt;
My name is Kartman and I live in South Park.&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Strings]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Version_4&amp;diff=5321</id>
		<title>Version 4</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Version_4&amp;diff=5321"/>
		<updated>2014-01-28T22:01:03Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Version 4.0.0 alpha 2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Documentation for AppStudio 4 (Unreleased)&lt;br /&gt;
&lt;br /&gt;
If you own a previous version of AppStudio, you need to buy the upgrade to use version 4. You can do this from within the app or from our [http://www.nsbasic.com/order.shtml order form.] &lt;br /&gt;
&lt;br /&gt;
Until you have bought the upgrade, you can use AppStudio 4 in Demo mode. Once you buy, your copy will convert automatically to the full version.&lt;br /&gt;
&lt;br /&gt;
== Version 4.0.0 alpha 3 ==&lt;br /&gt;
&lt;br /&gt;
# Code Modules: More file types can be editing in the Code Window.&lt;br /&gt;
# Code Modules: Files keep their names when drag and dropped to Code Window.&lt;br /&gt;
# Code Window: User can now choose font, font size, reverse colors and indents.&lt;br /&gt;
# Controls: New jQM [[PopUp]] control with sample.&lt;br /&gt;
# Controls:Footerbar no longer needs refresh().&lt;br /&gt;
# Design Screen: Controls can now be resized using percentages.&lt;br /&gt;
# Design Screen: Fix problem with alignment lines too short sometimes.&lt;br /&gt;
# Dropbox: Support for [[Using_Dropbox_to_save_files|Dropbox files]].&lt;br /&gt;
# Dropbox: Support for [[Using_a_Dropbox_Datastore|Dropbox Datastores]].&lt;br /&gt;
# Forms: New locked property stops changes to form layout.&lt;br /&gt;
# Forms: New setFocusID sets input field with initial focus.&lt;br /&gt;
# IDE: New, more modern look and feel.&lt;br /&gt;
# IDE: Windows do not reverse screen on right to left languages.&lt;br /&gt;
# IDE: New RTL Project Property for right to left languages.&lt;br /&gt;
# IDE: iWebKit text and buttons convert to jQuery Mobile on load.&lt;br /&gt;
# Language: add [[Format]] string function.&lt;br /&gt;
# Language: add [[Push]] array function.&lt;br /&gt;
# Language: add [[Splice]] array function.&lt;br /&gt;
# Language: New [[GetJSON]] function: see StockQuote sample.&lt;br /&gt;
# Language: New [[WaitCursor]] statement.&lt;br /&gt;
# Libraries: Obsolete Sencha and Cordova libraries removed.&lt;br /&gt;
# Libraries: jquery.js is always included.&lt;br /&gt;
# Libraries: jQuery updated to Version 2.1.0.&lt;br /&gt;
# Libraries: messages.js merged into hfunc.js.&lt;br /&gt;
# Libraries: new Shake library adds onshake() event.&lt;br /&gt;
# Preferences: New panel for Code Window.&lt;br /&gt;
# Project Properties: New rtl property for languages like Arabic, Farsi and Hebrew.&lt;br /&gt;
# Samples: Many new and updated samples.&lt;br /&gt;
# Samples: iWebKit samples removed.&lt;br /&gt;
&lt;br /&gt;
jQuery Mobile&lt;br /&gt;
# jQM 1.4 is now the officially supported version.&lt;br /&gt;
# jQM 1.3 is deprecated.&lt;br /&gt;
# All jQM samples have been converted to jQM 1.4.&lt;br /&gt;
# New option to convert jQM projects to JQM 1.4 on project load&lt;br /&gt;
# jQM 1.4 has a much more modern look and feel.&lt;br /&gt;
# RTL appearance for control now available.&lt;br /&gt;
# Just two built in themes now: white(a) and black(b).&lt;br /&gt;
# FontFamily, FontSize, FontStyle and FontWeight can now be set in the Properties Window.&lt;br /&gt;
# More controls now have a square corners option.&lt;br /&gt;
# More controls now have a mini option for a smaller version of the control.&lt;br /&gt;
# Where possible, controls now set their height automatically.&lt;br /&gt;
# Icons updated, with many new ones added.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
iWebKit&lt;br /&gt;
# iWebKit has been deprecated.&lt;br /&gt;
# iWebKit sample folder has been removed.&lt;br /&gt;
# All references to iWebKit in other samples have been converted.&lt;br /&gt;
# iWebKit Buttons, Text, Textarea and TitleBar controls can be converted to jQM 1.4 controls on project load.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Version_4&amp;diff=5320</id>
		<title>Version 4</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Version_4&amp;diff=5320"/>
		<updated>2014-01-28T21:50:34Z</updated>

		<summary type="html">&lt;p&gt;Admin: /* Version 4.0.0 alpha 2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Documentation for AppStudio 4 (Unreleased)&lt;br /&gt;
&lt;br /&gt;
If you own a previous version of AppStudio, you need to buy the upgrade to use version 4. You can do this from within the app or from our [http://www.nsbasic.com/order.shtml order form.] &lt;br /&gt;
&lt;br /&gt;
Until you have bought the upgrade, you can use AppStudio 4 in Demo mode. Once you buy, your copy will convert automatically to the full version.&lt;br /&gt;
&lt;br /&gt;
== Version 4.0.0 alpha 2 ==&lt;br /&gt;
&lt;br /&gt;
# Code Window: User can now choose font, font size, reverse colors and indents.&lt;br /&gt;
# Controls: New jQM [[PopUp]] control with sample.&lt;br /&gt;
# Controls:Footerbar no longer needs refresh().&lt;br /&gt;
# Design Screen: Controls can now be resized using percentages.&lt;br /&gt;
# Design Screen: Fix problem with alignment lines too short sometimes.&lt;br /&gt;
# Dropbox: Support for [[Using_Dropbox_to_save_files|Dropbox files]].&lt;br /&gt;
# Dropbox: Support for [[Using_a_Dropbox_Datastore|Dropbox Datastores]].&lt;br /&gt;
# Forms: New locked property stops changes to form layout.&lt;br /&gt;
# IDE: Windows do not reverse screen on right to left languages.&lt;br /&gt;
# IDE: New RTL Project Property for right to left languages.&lt;br /&gt;
# Language: add [[Push]] array function.&lt;br /&gt;
# Language: add [[Splice]] array function.&lt;br /&gt;
# Language: New [[GetJSON]] function: see StockQuote sample.&lt;br /&gt;
# Language: New [[WaitCursor]] statement&lt;br /&gt;
# Libraries: Obsolete Sencha and Cordova libraries removed.&lt;br /&gt;
# Libraries: jQuery updated to Version 2.0.3.&lt;br /&gt;
# Preferences: New panel for Code Window.&lt;br /&gt;
# Project Properties: New rtl property for languages like Arabic, Farsi and Hebrew.&lt;br /&gt;
# Samples: Many new and updated samples.&lt;br /&gt;
&lt;br /&gt;
jQuery Mobile&lt;br /&gt;
# jQM 1.4 is now the officially supported version.&lt;br /&gt;
# jQM 1.3 is deprecated.&lt;br /&gt;
# All jQM samples have been converted to jQM 1.4.&lt;br /&gt;
# New option to convert jQM projects to JQM 1.4 on project load&lt;br /&gt;
# jQM 1.4 has a much more modern look and feel.&lt;br /&gt;
# RTL appearance for control now available.&lt;br /&gt;
# Just two built in themes now: white(a) and black(b).&lt;br /&gt;
# FontFamily, FontSize, FontStyle and FontWeight can now be set in the Properties Window.&lt;br /&gt;
# More controls now have a square corners option.&lt;br /&gt;
# More controls now have a mini option for a smaller version of the control.&lt;br /&gt;
# Where possible, controls now set their height automatically.&lt;br /&gt;
# Icons updated, with many new ones added.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
iWebKit&lt;br /&gt;
# iWebKit has been deprecated.&lt;br /&gt;
# iWebKit sample folder has been removed.&lt;br /&gt;
# All references to iWebKit in other samples have been converted.&lt;br /&gt;
# iWebKit Buttons, Text, Textarea and TitleBar controls can be converted to jQM 1.4 controls on project load.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=GetJSON&amp;diff=5318</id>
		<title>GetJSON</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=GetJSON&amp;diff=5318"/>
		<updated>2014-01-28T21:49:35Z</updated>

		<summary type="html">&lt;p&gt;Admin: Admin moved page GetJSONP to GetJSON&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;GetJSON(&#039;&#039;url&#039;&#039;,&#039;&#039;data&#039;&#039;,&#039;&#039;callback&#039;&#039;)&lt;br /&gt;
&lt;br /&gt;
== Description ==&lt;br /&gt;
&lt;br /&gt;
GetJSON loads JSON-encoded data from the server using a GET HTTP request. &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;url&#039;&#039; is the location that data is being requested from.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;data&#039;&#039; is the information about the request. If multiple fields are being passed, include them in a single string, separated by ampersand (&amp;amp;) characters. It&#039;s best to do an [[EncodeURIComponent/decodeURIComponent|encodeURIComponent]]() to the data to make sure that spaces and other special characters are properly formatted.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;callback&#039;&#039; is the name of the function in your program to be called when the request is complete. Since the request may take a little while to complete, your app will continue execution immediately after the GetJSON() function is called. The results will not be available until the &#039;&#039;callback&#039;&#039; function is called. The returned data is passed to the &#039;&#039;callback&#039;&#039; function.&lt;br /&gt;
&lt;br /&gt;
This function is a wrapper for the jQuery $.getJSON() function. It works identically.&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function btnLoad_onclick()&lt;br /&gt;
  Dim city = encodeURIComponent(txtCity.value)&lt;br /&gt;
  GetJSON(&amp;quot;http://api.openweathermap.org/data/2.5/weather&amp;quot;,&amp;quot;q=&amp;quot; &amp;amp; city, weatherData)&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Sub weatherData(data)&lt;br /&gt;
  MsgBox &amp;quot;Temperature is &amp;quot; &amp;amp; data.main.temp - 273.15&lt;br /&gt;
End Sub&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Related Items ==&lt;br /&gt;
&lt;br /&gt;
[[ajax|Ajax]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Language Reference]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Miscellaneous]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Deploying&amp;diff=5111</id>
		<title>Deploying</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Deploying&amp;diff=5111"/>
		<updated>2014-01-07T06:24:45Z</updated>

		<summary type="html">&lt;p&gt;Admin: 25 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Differences between AppStudio and AppStudioEDU =&lt;br /&gt;
&lt;br /&gt;
* In these sessions, we have been using the full version of AppStudio.&lt;br /&gt;
* In the classroom, the students will be using AppStudioEDU.&lt;br /&gt;
* AppStudioEDU has the following restrictions:&lt;br /&gt;
# Cannot deploy to other than the Ministry&#039;s servers.&lt;br /&gt;
# Cannot compile apps with PhoneGap&lt;br /&gt;
# Cannot create Chrome Desktop Apps.&lt;br /&gt;
# Commercial apps cannot be produced.&lt;br /&gt;
* As part of this training, everyone here gets the full version.&lt;br /&gt;
* Students and and teachers will be able to buy the full version for half price.&lt;br /&gt;
&lt;br /&gt;
= Servers =&lt;br /&gt;
&lt;br /&gt;
* In these sessions, we have been using the nsbasic.com server.&lt;br /&gt;
* The students will be using the school&#039;s servers.&lt;br /&gt;
* These servers need to be able to process http requests to run apps.&lt;br /&gt;
* They also need to support ftp so apps can be uploaded to them.&lt;br /&gt;
* Files that end in .appcache need to be served with mime type text/manifest.&lt;br /&gt;
* To test this, use http://web-sniffer.net/.&lt;br /&gt;
* Servers can be Apache or Microsoft IIS.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= PHP =&lt;br /&gt;
&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Php PHP] is a server side programming language&lt;br /&gt;
* When a web app talks to a server, the program on the server is most often PHP.&lt;br /&gt;
* There is increasing interest in [http://en.wikipedia.org/wiki/Node.js JavaScript] as a replacement.&lt;br /&gt;
* Not all servers have PHP installed or enabled.&lt;br /&gt;
&lt;br /&gt;
= Web Apps vs Hybrid Apps =&lt;br /&gt;
&lt;br /&gt;
http://www.youtube.com/watch?v=fchbLzwtexk&lt;br /&gt;
&lt;br /&gt;
* So far, we have been running as our apps as Web Apps.&lt;br /&gt;
* But it is also possible to turn them into native apps.&lt;br /&gt;
* Native apps have a built in web browser control.&lt;br /&gt;
* If create a native app with one of those browsers, it can run an AppStudio in that browser.&lt;br /&gt;
* It&#039;s a combination of native code + HTML = Hybrid App.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
{|  class=&amp;quot;wikitable&amp;quot; &lt;br /&gt;
!  width=20% | &lt;br /&gt;
!  width=40% | Web App&lt;br /&gt;
!  width=40% | PhoneGap App&lt;br /&gt;
|- &lt;br /&gt;
| Size of created apps (minimum)&lt;br /&gt;
| About 100K&lt;br /&gt;
| About 250K&lt;br /&gt;
|- &lt;br /&gt;
| Maximum size of app + data&lt;br /&gt;
| 25 megs (iOS)&lt;br /&gt;
| Limited by device itself; 40 megs for PhoneGap Build.&lt;br /&gt;
|- &lt;br /&gt;
| Can apps run offline?&lt;br /&gt;
| yes&lt;br /&gt;
| yes&lt;br /&gt;
|- &lt;br /&gt;
| Where are apps stored on device?&lt;br /&gt;
| In browser&#039;s sandbox.&lt;br /&gt;
| In regular file store.&lt;br /&gt;
|- &lt;br /&gt;
| Performance&lt;br /&gt;
| Excellent&lt;br /&gt;
| Slower for CPU bound operations.&lt;br /&gt;
|- &lt;br /&gt;
| Eligible for Store?&lt;br /&gt;
| No.&lt;br /&gt;
| iOS: Yes. Can go into App Store.&amp;lt;br&amp;gt;&lt;br /&gt;
Android. Yes. Can go into Marketplace.&lt;br /&gt;
|- &lt;br /&gt;
| Distribute without going through store?&lt;br /&gt;
| Yes.&lt;br /&gt;
| iOS: No.&amp;lt;br&amp;gt;&lt;br /&gt;
Android. Yes.&lt;br /&gt;
|- &lt;br /&gt;
| Percent you have to give up&lt;br /&gt;
| 0%&lt;br /&gt;
| iOS: 30%&amp;lt;br&amp;gt;&lt;br /&gt;
Android. 30% (MarketPlace)&lt;br /&gt;
|- &lt;br /&gt;
| Security of code&lt;br /&gt;
| OK: obfuscated&lt;br /&gt;
| OK: obfuscated&lt;br /&gt;
|- &lt;br /&gt;
| Additional Plugins&lt;br /&gt;
| &lt;br /&gt;
| Many - see the complete list [https://build.phonegap.com/plugins on PhoneGap&#039;s site].&lt;br /&gt;
|- &lt;br /&gt;
| How to deploy&lt;br /&gt;
| To the test server: hit F6.&lt;br /&gt;
To your own server: Set up username and password, then hit F6.&lt;br /&gt;
Then, on the device, enter the app&#039;s URL into the browser, then save to Home screen.&lt;br /&gt;
| [[Submitting to the iOS App Store|iOS]]: join Apple&#039;s developer program, get certificates (Mac required), enter certificates into PhoneGap Build, use Apple&#039;s upload tool to submit to App Store, wait for approval or rejection. Customer can then get app through App Store.&lt;br /&gt;
[[Submitting to the Google Play and Amazon Stores|Android]]: Download result file from PhoneGap Build and distribute &lt;br /&gt;
directly or through Google marketplace.&lt;br /&gt;
|- &lt;br /&gt;
| How to update a deployed app&lt;br /&gt;
| Deploy the app to the server. Next time the user starts the app, it will be automatically updated.&lt;br /&gt;
| iOS: Go through the whole submission process again. Once complete, app will show up as an update in the App Store.&lt;br /&gt;
Android: distribute  directly or through Google marketplace.&lt;br /&gt;
|- &lt;br /&gt;
| How to delete a deployed app&lt;br /&gt;
| User can delete manually. If app is deleted from server, it will be automatically deleted from user&#039;s device.&lt;br /&gt;
| User can delete manually.&lt;br /&gt;
|- &lt;br /&gt;
| How to delete app&#039;s data&lt;br /&gt;
| User can delete manually in Settings. If app is deleted from server, it will be automatically deleted from user&#039;s device.&lt;br /&gt;
| Will be deleted with app.&lt;br /&gt;
|- &lt;br /&gt;
| Sharing data between apps&lt;br /&gt;
| Apps from the same server can share SQLite databases (subject to browser space limit)&lt;br /&gt;
| Apps are sandboxed and cannot interfere with each other&#039;s data.&lt;br /&gt;
|- &lt;br /&gt;
| Other software needed&lt;br /&gt;
| Nothing.&lt;br /&gt;
| iOS: iOS Application Installer&amp;lt;br&amp;gt;&lt;br /&gt;
Android: Nothing&lt;br /&gt;
|- &lt;br /&gt;
| Development OS&lt;br /&gt;
| Windows XP, Vista, 7 or 8&lt;br /&gt;
| iOS: OS X&amp;lt;br&amp;gt;&lt;br /&gt;
Android: Windows, OS X or Linux&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= PhoneGap Build =&lt;br /&gt;
&lt;br /&gt;
* [https://build.phonegap.com/ PhoneGap Build] is a webservice provided by Adobe.&lt;br /&gt;
* It takes a web app and turns it into a hybrid app.&lt;br /&gt;
* PhoneGap Build can make native apps for iOS, Android and Windows Phone.&lt;br /&gt;
* It&#039;s free for a single project.&lt;br /&gt;
&lt;br /&gt;
Try an app compiled with PhoneGap Build here:&lt;br /&gt;
https://dl.dropboxusercontent.com/u/4451197/hello.apk&lt;br /&gt;
 &lt;br /&gt;
== Additional Project Properties ==&lt;br /&gt;
&lt;br /&gt;
{| class = &amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| PhoneGap configxml || Configuration information for [https://build.phonegap.com/docs/config-xml PhoneGap Build]. Includes things like icons, splash screens, autorotation (orientation) and more.&lt;br /&gt;
|-&lt;br /&gt;
| phonegapBuildID || Build number returned by PhoneGap Build.&lt;br /&gt;
|-&lt;br /&gt;
| phoneGapLanguages || Languages supported if PhoneGap project. &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Quick Demo ==&lt;br /&gt;
&lt;br /&gt;
# Check PhoneGap configxml. Everything OK?&lt;br /&gt;
# Build Native App with PhoneGap&lt;br /&gt;
# Check PhoneGap status&lt;br /&gt;
# When complete, download the Android version (apk).&lt;br /&gt;
# Put it on a server&lt;br /&gt;
# Navigate to the URL using the device browser.&lt;br /&gt;
# Download the apk file.&lt;br /&gt;
# Look for it in the Downloads folder.&lt;br /&gt;
# Tap on it to install.&lt;br /&gt;
# Installing to iOS is much more complex!&lt;br /&gt;
# For full details, see the the TechNotes for [[Submitting to the Google Play and Amazon Stores|Android]] and [[Submitting to the iOS App Store|iOS]].&lt;br /&gt;
&lt;br /&gt;
== PhoneGap PlugIns ==&lt;br /&gt;
&lt;br /&gt;
* [https://build.phonegap.com/plugins Plugins] are native code modules which can be included in PhoneGap projects.&lt;br /&gt;
* They can be called from AppStudio programs.&lt;br /&gt;
* There are currently 20 PhoneGap developed plugins and 64 third party developed ones.&lt;br /&gt;
* Most popular are BarcodeScanner, File, PushPlugin and Facebook Connect.&lt;br /&gt;
* These provide functionality that could not be done in AppStudio alone.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Chrome Packaged Apps =&lt;br /&gt;
&lt;br /&gt;
== Features ==&lt;br /&gt;
* AppStudio can make distributable Windows desktop apps, by making them into [[Making Desktop Apps with App Studio|Chrome Packaged Apps]]. &lt;br /&gt;
* Users need need to have Chrome installed on their systems. &lt;br /&gt;
* The apps can be sold or given away for free in the Chrome Web Store.&lt;br /&gt;
* Mac support just added. &lt;br /&gt;
* Packaged apps deliver an experience as capable as a native app, but as safe as a web page. &lt;br /&gt;
* Packaged apps look and behave like native apps.&lt;br /&gt;
* They have native-like capabilities that are much more powerful than those available to web apps.&lt;br /&gt;
* There are additional API functions available.&lt;br /&gt;
&lt;br /&gt;
== Restrictions ==&lt;br /&gt;
# Do not use alert, confirm or prompt (JavaScript) or [[MsgBox]] (BASIC). Use NSB.MsgBox instead.&lt;br /&gt;
# Do not use [[eval]]().&lt;br /&gt;
# Do not use [[localStorage]] or [[Sql|SQLite]]. Use the [https://developer.chrome.com/apps/app_storage.html FileSystem API] or [http://www.html5rocks.com/en/tutorials/indexeddb/todo/ IndexedDB].&lt;br /&gt;
# Follow the rules in [http://developer.chrome.com/apps/contentSecurityPolicy.html Chrome&#039;s Content Security Policy].&lt;br /&gt;
# Check to see that you are not using any other [https://developer.chrome.com/apps/app_deprecated.html disabled web features].&lt;br /&gt;
&lt;br /&gt;
== Quick Demo ==&lt;br /&gt;
# Get your app ready&lt;br /&gt;
# Check ChromeAppLaunch in Project Properties&lt;br /&gt;
# Check ChromeManifest in Project Properties&lt;br /&gt;
# Click on &amp;quot;Build Desktop App&amp;quot; in the Run menu&lt;br /&gt;
# Sign on to your Google Developer Account&lt;br /&gt;
# Upload your zip file&lt;br /&gt;
# Publish Changes&lt;br /&gt;
# Let it bake.&lt;br /&gt;
# Download the App&lt;br /&gt;
# Start App using Chrome App Launcher&lt;br /&gt;
# Start App using a shortcut&lt;br /&gt;
# Run the App&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Lab_Session:_Screen_size_and_rotation&amp;diff=5085</id>
		<title>Lab Session: Screen size and rotation</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Lab_Session:_Screen_size_and_rotation&amp;diff=5085"/>
		<updated>2014-01-07T06:24:42Z</updated>

		<summary type="html">&lt;p&gt;Admin: 6 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In this lab, you&#039;ll make changes to &#039;&#039;frmSavedData&#039;&#039; to make it rotate and resize properly in order to gain experience with these technologies.&lt;br /&gt;
&lt;br /&gt;
== Student Outline ==&lt;br /&gt;
&lt;br /&gt;
# Open LabRotation.nsx.&lt;br /&gt;
# Remove the [[orientation]] control you added previously, since we&#039;ll be handling orientation changes for ourselves (at least for &#039;&#039;frmSavedData&#039;&#039;).&lt;br /&gt;
# Add an onorientation event to &#039;&#039;frmSavedData&#039;&#039; and verify the device reacts to orientation changes.&lt;br /&gt;
# The layout of &#039;&#039;frmSavedData&#039;&#039; will look better as two columns when in landscape mode.  Change the top and left values of the 3 lower data labels and values so they sit beside the top three when orientation is in landscape mode.&lt;br /&gt;
# On a larger screen (such as a tablet), you may want more spacing between the labels and values.  The easiest way to do this is by setting the left value to a percentage.  Try this in portrait mode first.  Verify that the labels change positions when the screen size changes.&lt;br /&gt;
# You&#039;ll notice the percentages need to be changed when the orientation changes to landscape mode.  Experiment to find the correct values and verify this form now is properly arranged for many screen sizes and orientations.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=IOS_and_Android&amp;diff=5078</id>
		<title>IOS and Android</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=IOS_and_Android&amp;diff=5078"/>
		<updated>2014-01-07T06:24:40Z</updated>

		<summary type="html">&lt;p&gt;Admin: 7 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Quirks, Things to know =&lt;br /&gt;
&lt;br /&gt;
* Mobile device develop much more rapidly than desktop systems.&lt;br /&gt;
* There is much more variation in the marketplace.&lt;br /&gt;
* Parts of this presentation will no longer be valid in 6 months.&lt;br /&gt;
* HTML5 standards are being gradually adopted.&lt;br /&gt;
* You cannot assume all devices have all features.&lt;br /&gt;
* To check if an OS has a particular feature, check http://www.caniuse.com&lt;br /&gt;
&lt;br /&gt;
== iOS ==&lt;br /&gt;
* 75% of users are on iOS 7 (the latest) already&lt;br /&gt;
* Less than 5% are older than iOS 6.&lt;br /&gt;
* All devices made by Apple&lt;br /&gt;
&lt;br /&gt;
== Android ==&lt;br /&gt;
* 45% of users are in Android 4.x&lt;br /&gt;
* More than 50% are in Android 2.x&lt;br /&gt;
* Android 2.x devices are still being manufactured&lt;br /&gt;
* Two versions of the brower: Android Browser and Chrome.&lt;br /&gt;
* Android browser is no longer being developed.&lt;br /&gt;
* Chrome browser is much more advanced.&lt;br /&gt;
* Chrome browser only runs on Android 4+&lt;br /&gt;
* Devices are made by hundreds of manufacturers&lt;br /&gt;
* Since Android is open source, there is no standard on how Android is configured.&lt;br /&gt;
* Some manufacturers (Amazon, Samsung) put their own software on top of Android.&lt;br /&gt;
* As a result, Android devices have more quirks than iOS.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= Dealing with different screen sizes =&lt;br /&gt;
&lt;br /&gt;
* Making apps which look good on all the devices they run on is hard.&lt;br /&gt;
&lt;br /&gt;
== Different screen sizes ==&lt;br /&gt;
&lt;br /&gt;
* Physical screen sizes on phone devices run from 3.5 inches to more than 5&lt;br /&gt;
* The ratio of width to height is not always the same.&lt;br /&gt;
* For example, the iPhone 4 is 320x480, while the iPhone 5 is 320x568.&lt;br /&gt;
* Actually, since the iPhone 5 is a retina, it is 640x1136.&lt;br /&gt;
* Positions on retina devices are based on the 320x578.&lt;br /&gt;
* Text and images are drawn more precisely using the extra pixels.&lt;br /&gt;
* Use [[SysInfo]](2) and [[SysInfo]](3) to get the current width and height.&lt;br /&gt;
* It is usually correct.&lt;br /&gt;
* No method has been found yet that gets the correct width and height for all devices!&lt;br /&gt;
&lt;br /&gt;
== Orientation ==&lt;br /&gt;
&lt;br /&gt;
* If you want to run your app in both portrait and landscape, you have to program this yourself.&lt;br /&gt;
* Simply scaling the controls will not work in most cases.&lt;br /&gt;
* You may even want to rethink the design for usability.&lt;br /&gt;
&lt;br /&gt;
== Tablets ==&lt;br /&gt;
&lt;br /&gt;
* You cannot simply scale all the controls up in size.&lt;br /&gt;
* If you do, your app will look terrible.&lt;br /&gt;
* Consider using the extra space for more usability.&lt;br /&gt;
* For example, display two forms size by side.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Lab_Session:_Use_a_library&amp;diff=5070</id>
		<title>Lab Session: Use a library</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Lab_Session:_Use_a_library&amp;diff=5070"/>
		<updated>2014-01-07T06:24:39Z</updated>

		<summary type="html">&lt;p&gt;Admin: 1 revision&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In this lab session, you will add the jQuery library to your application and modify some code to use it.&lt;br /&gt;
&lt;br /&gt;
== Student Outline ==&lt;br /&gt;
&lt;br /&gt;
# Open LabLibrary.nsx&lt;br /&gt;
# Add the jQuery library to the project.&lt;br /&gt;
# Replace instances of &amp;lt;pre&amp;gt;label.textContent = &amp;quot;value&amp;quot;&amp;lt;/pre&amp;gt; with &amp;lt;pre&amp;gt;$(&amp;quot;#label&amp;quot;).text(&amp;quot;value&amp;quot;)&amp;lt;/pre&amp;gt; to verify jQuery is working.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=JavaScript,_HTML,_CSS&amp;diff=5068</id>
		<title>JavaScript, HTML, CSS</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=JavaScript,_HTML,_CSS&amp;diff=5068"/>
		<updated>2014-01-07T06:24:38Z</updated>

		<summary type="html">&lt;p&gt;Admin: 33 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= What&#039;s behind the scenes? =&lt;br /&gt;
&lt;br /&gt;
* In this section, we will learn more about the internals of AppStudio.&lt;br /&gt;
* AppStudio is built on top of [http://en.wikipedia.org/wiki/Html5 HTML5], [http://en.wikipedia.org/wiki/Css css3] and [http://en.wikipedia.org/wiki/Javascript JavaScript].&lt;br /&gt;
* We deliberately left those parts accessible.&lt;br /&gt;
* Makes it easy to learn more about HTML5, CSS and JavaScript.&lt;br /&gt;
* Advanced users can build almost anything.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== Translator ==&lt;br /&gt;
&lt;br /&gt;
[[File:Translator.png|600px]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
* When an AppStudio program is run, all BASIC code is converted to JavaScript.&lt;br /&gt;
* JavaScript is [https://www.nsbasic.com/speedtest.htm fast]!&lt;br /&gt;
* JavaScript on a iPhone 5S is almost twice as fast as VB.Net on a desktop!&lt;br /&gt;
* Latest iPhones are 100x faster than the original.&lt;br /&gt;
* Translation happens only to code modules which have changed.&lt;br /&gt;
* You can see your BASIC translated to JavaScript by right clicking in the [[Code Window]].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Controls ==&lt;br /&gt;
&lt;br /&gt;
* The forms and controls in your project generate css and HTML&lt;br /&gt;
* The css defines the controls.&lt;br /&gt;
* Controls are identified by their ids.&lt;br /&gt;
* The ids are declared in the DOM window object.&lt;br /&gt;
* While is why we can do TextBox1.value.&lt;br /&gt;
* For each control, a string of HTML is also created.&lt;br /&gt;
* These strings are put into an array.&lt;br /&gt;
* The array is joined together and put into the form&#039;s innerHTML.&lt;br /&gt;
* Just like what we were doing the HTMLview!&lt;br /&gt;
* Let&#039;s look at the css for a button:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#Button1 {position:absolute; left:43px; right:auto; top:96px; &lt;br /&gt;
bottom:auto; height:29px; width:100px}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Here is the generated HTML and JavaScript for that same button:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Form1.innerHTML=[  &amp;quot;&amp;amp;lt;div id=&#039;Button1&#039; data-role=&#039;button&#039; data-inline=true &lt;br /&gt;
data-theme=c data-icon=false data-iconpos=none data-mini=true &lt;br /&gt;
data-corners=&#039;true&#039; class=&#039; &#039; style=&#039;margin:0px; overflow:visible; &lt;br /&gt;
font-size:12px; font-family:helvetica; font-style:normal; font-weight:bold; &lt;br /&gt;
color:; background-color:; &#039;&amp;gt;Button&amp;amp;lt;/div&amp;gt;&amp;quot;,&lt;br /&gt;
  ].join(&#039;&#039;);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== Generated Index.html ==&lt;br /&gt;
&lt;br /&gt;
* The translated code for the app and the css, HTML and Javascript for the controls are all written to a file called Index.html.&lt;br /&gt;
&lt;br /&gt;
* Let&#039;s have a look at the file.&lt;br /&gt;
* First, there is the manifest.&lt;br /&gt;
* This file contains the list of files to be saved locally on the device.&lt;br /&gt;
* An app cannot run offline unless all files are listed here.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp;lt;!DOCTYPE HTML&amp;gt;&lt;br /&gt;
&amp;amp;lt;html manifest=&amp;quot;OfflineApp.appcache&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The &amp;amp;lt;head&amp;gt; section sets up general information about the app.&lt;br /&gt;
* Much of it comes from the information in Project Properties.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp;lt;head&amp;gt;&lt;br /&gt;
&amp;amp;lt;meta charset=&amp;quot;utf-8&amp;quot;&amp;gt;&lt;br /&gt;
&amp;amp;lt;title&amp;gt;Project2&amp;amp;lt;/title&amp;gt;&lt;br /&gt;
&amp;amp;lt;meta name=&amp;quot;generator&amp;quot; content=&amp;quot;NSB/AppStudio 3.3.0.0$mgvb&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;amp;lt;meta name=&amp;quot;date&amp;quot; content=&amp;quot;2013-12-12 13:44:58.613000&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;amp;lt;meta name=&amp;quot;version&amp;quot; content=&amp;quot;1.0.0&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;amp;lt;meta name=&amp;quot;viewport&amp;quot; content=&amp;quot;width=device-width minimum-scale=1.0, maximum-scale=0.6667, user-scalable=no&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;amp;lt;meta name=&amp;quot;apple-mobile-web-app-capable&amp;quot; content=&amp;quot;YES&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;amp;lt;meta name=&amp;quot;mobile-web-app-capable&amp;quot; content=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;amp;lt;meta name=&amp;quot;apple-mobile-web-app-status-bar-style&amp;quot; content=&amp;quot;black-translucent&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;amp;lt;meta name=&amp;quot;apple-mobile-web-app-title&amp;quot; content=&amp;quot;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;amp;lt;meta name=&amp;quot;copyright&amp;quot; content=&amp;quot;Copyright 2013 ABC Company&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;amp;lt;link rel=&amp;quot;apple-touch-icon&amp;quot; href=&amp;quot;nsb/images/LauncherIcon57.png&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;amp;lt;link rel=&amp;quot;apple-touch-startup-image&amp;quot; href=&amp;quot;nsb/images/SplashScreen.png&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;amp;lt;link rel=&amp;quot;shortcut icon&amp;quot; sizes=&amp;quot;196x196&amp;quot; href=&amp;quot;nsb/images/196.png&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* This is where the files the app uses get loaded. &lt;br /&gt;
* JavaScript files use a script tag.&lt;br /&gt;
* css files use a link tag.&lt;br /&gt;
* The list of files depends on the controls which are used.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp;lt;script src=&amp;quot;nsb/hfunc.js&amp;quot;&amp;gt;&amp;amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;amp;lt;script src=&amp;quot;nsb/messages.js&amp;quot;&amp;gt;&amp;amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;amp;lt;link href=&amp;quot;nsb/nsbstyle.css&amp;quot; rel=&amp;quot;stylesheet&amp;quot;&amp;gt;&lt;br /&gt;
&amp;amp;lt;script src=&amp;quot;nsb/fastclick.js&amp;quot;&amp;gt;&amp;amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;amp;lt;script src=&amp;quot;nsb/jquery.js&amp;quot;&amp;gt;&amp;amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;amp;lt;script src=&amp;quot;nsb/jquery.mobile.js&amp;quot;&amp;gt;&amp;amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;amp;lt;link href=&amp;quot;nsb/jquery.mobile.css&amp;quot; rel=&amp;quot;stylesheet&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Next comes the css for the controls&lt;br /&gt;
* and we define the default font for the form, also a Project Property.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp;lt;style type=&amp;quot;text/css&amp;quot;&amp;gt;&lt;br /&gt;
#Button1 {position:absolute; left:43px; right:auto; top:96px; bottom:auto; height:29px; width:100px}&lt;br /&gt;
body * {font-family:helvetica}&lt;br /&gt;
&amp;amp;lt;/style&amp;gt;&lt;br /&gt;
&amp;amp;lt;/head&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Now it&#039;s time the body of our app.&lt;br /&gt;
* [https://github.com/ftlabs/fastclick FastClick] is a library which makes touch events as fast as clicks.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp;lt;body style=&amp;quot;margin:0px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;amp;lt;script&amp;gt;window.addEventListener(&#039;load&#039;, function() {new FastClick(document.body)}, false)&amp;amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Now it&#039;s time to define our forms.&lt;br /&gt;
* This project only has one: Form1&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp;lt;div data-role=&amp;quot;page&amp;quot; id=&amp;quot;Page_Project2&amp;quot; data-theme=&amp;quot;c&amp;quot; style=&amp;quot;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;amp;lt;form id=&amp;quot;Form1&amp;quot; action=&amp;quot;&amp;quot; method=&amp;quot;GET&amp;quot; onsubmit=&amp;quot;return false;&amp;quot; style=&amp;quot;display:none; height:100%; position:absolute; top:0px; left:0px; width:100%; &amp;quot;&amp;gt;&lt;br /&gt;
&amp;amp;lt;script&amp;gt;&lt;br /&gt;
Form1.innerHTML=[  &amp;quot;&amp;amp;lt;div id=&#039;Button1&#039; data-role=&#039;button&#039; data-inline=true data-theme=c data-icon=false data-iconpos=none data-mini=true data-corners=&#039;true&#039; class=&#039; &#039; style=&#039;margin:0px; overflow:visible; font-size:12px; font-family:helvetica; font-style:normal; font-weight:bold; color:; background-color:; &#039;&amp;gt;Button&amp;amp;lt;/div&amp;gt;&amp;quot;,&lt;br /&gt;
  ].join(&#039;&#039;);&lt;br /&gt;
&amp;amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;amp;lt;/form&amp;gt;&lt;br /&gt;
&amp;amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* With all that set up, we can start on the code.&lt;br /&gt;
* General housekeeping comes first.&lt;br /&gt;
* Put all the ids into the DOM window:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp;lt;script&amp;gt;&lt;br /&gt;
(function(){var all=document.getElementsByTagName(&#039;*&#039;);for(var i=0;i&amp;amp;lt;all.length;i++)if(typeof all[i].id!=&#039;undefined&#039;&amp;amp;&amp;amp;typeof window[all[i].id]==&#039;undefined&#039;)window[all[i].id]=all[i];})()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Put up a message if the browser does not support AppStudio&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
browserWarningMessage(&#039;Please use Google Chrome, Apple Safari or another supported browser.&#039;);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Use a different splashscreen if running on an iPad&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
if (navigator.userAgent.indexOf(&#039;iPad&#039;) !== -1) {&lt;br /&gt;
  var splashscreen = document.createElement(&#039;link&#039;);&lt;br /&gt;
  splashscreen.rel = &#039;apple-touch-startup-image&#039;;&lt;br /&gt;
  splashscreen.href = &#039;&#039;;&lt;br /&gt;
  document.getElementsByTagName(&#039;head&#039;)[0].appendChild(splashscreen);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Add some properties to the controls and form so they act more like VB&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
window.addEventListener(&#039;load&#039;, function() {&lt;br /&gt;
  Form1.style.display = &#039;block&#039;;&lt;br /&gt;
  NSB.addDisableProperty(Button1);&lt;br /&gt;
  NSB.addProperties(Button1);&lt;br /&gt;
&lt;br /&gt;
  Form1.style.display = &#039;none&#039;;&lt;br /&gt;
}, false);&lt;br /&gt;
Form1.onsubmit=function(event){window.event.stopPropagation();window.event.preventDefault()};&lt;br /&gt;
NSB.addProperties(Form1);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Here is our actual code, converted to JavaScript&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Button1.onclick = function() { savethefunction_rvar=&amp;quot;&amp;quot;;&lt;br /&gt;
  _msgbox_confirm(&amp;quot;Hello World!&amp;quot;);&lt;br /&gt;
return savethefunction_rvar; }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* When loading is done, show the first form and call Sub Main()&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
window.addEventListener(&#039;load&#039;, function() {&lt;br /&gt;
  Form1.style.display = &#039;block&#039;;&lt;br /&gt;
  Main();&lt;br /&gt;
  if (typeof(Form1.onshow)==&#039;function&#039;) Form1.onshow();&lt;br /&gt;
}, false);&lt;br /&gt;
&lt;br /&gt;
var NSBCurrentForm = Form1;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* and the rest is HTML formatting.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;amp;lt;/body&amp;gt;&lt;br /&gt;
&amp;amp;lt;/html&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Note that the details of the above may change in future releases.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= JavaScript Libraries =&lt;br /&gt;
&lt;br /&gt;
* AppStudio makes it easy to include JavaScript libraries.&lt;br /&gt;
* These are equally easy to use from BASIC or JavaScript.&lt;br /&gt;
* If something can be done in JavaScript, there probably is a library for it already.&lt;br /&gt;
&lt;br /&gt;
== Ways to include ==&lt;br /&gt;
&lt;br /&gt;
# Drag it into the [[Project Explorer]]. It will get loaded into your Index.html when your app is generated.&lt;br /&gt;
# Create a new Code Module. Set its language to JavaScript. Paste the code in.&lt;br /&gt;
# Create a &amp;amp;lt;script&amp;gt; line in the extraheaders Project Property.&lt;br /&gt;
# Put it in the middle of your BASIC code. Using the JavaScript statement, you can mix JavaScript and BASIC in the same module.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
x = x + 1                    &#039;BASIC&lt;br /&gt;
JavaScript&lt;br /&gt;
  if(x==3){alert(&#039;x=3!&#039;);    //JavaScript&lt;br /&gt;
End JavaScript&lt;br /&gt;
x = x + 1                    &#039;BASIC&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Included Libraries ==&lt;br /&gt;
[[File:Toolboxlibraries.png]]&lt;br /&gt;
* A number of libraries are installed with AppStudio&lt;br /&gt;
* To use them, select Project Properties and Global code in the [[Project Explorer]]&lt;br /&gt;
* The ToolBox will then show the list of libraries.&lt;br /&gt;
* Include one by clicking on its checkbox.&lt;br /&gt;
* Sample for these are in the folder 8 of the Samples directory.&lt;br /&gt;
&lt;br /&gt;
=== Add to Home Screen ===&lt;br /&gt;
&lt;br /&gt;
* This library is iOS only. When your app is run in the browser, it prompts you to save to the Home Screen.&lt;br /&gt;
&lt;br /&gt;
=== jQuery ===&lt;br /&gt;
&lt;br /&gt;
* This library is the most widely used JavaScript library on the net.&lt;br /&gt;
* jQuery Mobile and jqWidgets both use it.&lt;br /&gt;
* Usually no need to select it, since it will already be included.&lt;br /&gt;
&lt;br /&gt;
=== Retina Display Support ===&lt;br /&gt;
* Displays Hi Res versions of images where supported.&lt;br /&gt;
* Requires two sets of all images in your project.&lt;br /&gt;
* Hi Res set is named filename@2x.jpg.&lt;br /&gt;
&lt;br /&gt;
=== Sencha Touch ===&lt;br /&gt;
&lt;br /&gt;
* This is large, fairly well known framework. &lt;br /&gt;
* Not so much used with AppStudio any more.&lt;br /&gt;
&lt;br /&gt;
=== Spinning Wheel ===&lt;br /&gt;
&lt;br /&gt;
* Nice spin control for selecting dates, etc.&lt;br /&gt;
&lt;br /&gt;
=== Stanford Crypto Library ===&lt;br /&gt;
&lt;br /&gt;
* Allow strings to be strongly encrypted for transmission over the net.&lt;br /&gt;
* Here&#039;s how to use it:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function btnEncrypt_onclick()&lt;br /&gt;
  txtEncrypted.value=sjcl.encrypt(txtPassword.value, txtPlain.value)&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Function btnDecrypt_onclick()&lt;br /&gt;
  txtPlain.value=sjcl.decrypt(txtPassword.value, txtEncrypted.value)&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== xml2json ===&lt;br /&gt;
&lt;br /&gt;
* Convert XML formatted data to a JSON structure.&lt;br /&gt;
&lt;br /&gt;
== Other Libraries ==&lt;br /&gt;
&lt;br /&gt;
* There are several repositories which list hundred or even thousands of JavaScript libraries&lt;br /&gt;
* http://www.javascriptsource.com&lt;br /&gt;
* http://javascriptlibraries.com&lt;br /&gt;
* http://www.jsdb.io&lt;br /&gt;
* Lots more!&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Lab_Session:_Add_Twitter_feed_to_the_app&amp;diff=5034</id>
		<title>Lab Session: Add Twitter feed to the app</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Lab_Session:_Add_Twitter_feed_to_the_app&amp;diff=5034"/>
		<updated>2014-01-07T06:24:33Z</updated>

		<summary type="html">&lt;p&gt;Admin: 7 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In this lab session, you will add AppStudio&#039;s twitter feed to your app.&lt;br /&gt;
&lt;br /&gt;
== Student Outline ==&lt;br /&gt;
&lt;br /&gt;
# Open LabTwitter.nsx.&lt;br /&gt;
# Create a Twitter widget ID (or use AppStudio&#039;s: 408316144626302976).&lt;br /&gt;
# Use the two Twitter controls to add a feed to the &#039;&#039;frmAbout&#039;&#039;.  One follow and one widget.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Social_Media&amp;diff=5026</id>
		<title>Social Media</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Social_Media&amp;diff=5026"/>
		<updated>2014-01-07T06:24:32Z</updated>

		<summary type="html">&lt;p&gt;Admin: 31 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Twitter =&lt;br /&gt;
[[File:twitter.png|framed|center]]&lt;br /&gt;
&lt;br /&gt;
* This sample shows a couple of [https://dev.twitter.com/docs/tfw-javascript Twitter APIs]&lt;br /&gt;
&lt;br /&gt;
* No code needs to be written: Twitter does all the work.&lt;br /&gt;
&lt;br /&gt;
* The display to be generated is set by a Twitter Widget ID&lt;br /&gt;
&lt;br /&gt;
* To create a Twitter widget, sign onto Twitter&lt;br /&gt;
&lt;br /&gt;
* Go to https://twitter.com/settings/widgets&lt;br /&gt;
&lt;br /&gt;
* In the above image, the top widget is a Follow widget&lt;br /&gt;
&lt;br /&gt;
* Beneath that, is a Timeline widget.&lt;br /&gt;
&lt;br /&gt;
* There are many, many options to explore on Twitter&#039;s site.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= Facebook = &lt;br /&gt;
[[File:facebook.png|framed|center]]&lt;br /&gt;
&lt;br /&gt;
* The above image is a dump of the Facebook graph.&lt;br /&gt;
* The [https://developers.facebook.com/docs/reference/javascript/ complete FaceBook API] is rich and complex.&lt;br /&gt;
* Docs are at https://developers.facebook.com/docs/reference/javascript/&lt;br /&gt;
* To get a Facebook graph of a facebook account, first make the request:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function btnRetrieve_onclick()&lt;br /&gt;
  $.getJSON(&amp;quot;https://graph.facebook.com/&amp;quot; &amp;amp; txtId.value, &amp;quot;callback=?&amp;quot;, gotResult)&lt;br /&gt;
End Function&amp;lt;/pre&amp;gt;&lt;br /&gt;
* $getJSON is a wrapper for an Ajax call&lt;br /&gt;
* We put the name of the person we want in the URL&lt;br /&gt;
* We supply the name of the function to call on return (&amp;quot;gotResult&amp;quot;).&lt;br /&gt;
* This is an asynchronous call: we can do other things while waiting for the result.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function gotResult(data)&lt;br /&gt;
  txtData.value = &amp;quot;&amp;quot;&lt;br /&gt;
  If data[&amp;quot;error&amp;quot;] Then&lt;br /&gt;
    txtData.value = data.error.message&lt;br /&gt;
  Else&lt;br /&gt;
    For Each item in data&lt;br /&gt;
      txtData.value = txtData.value &amp;amp; Eval(&amp;quot;item&amp;quot;) &amp;amp; &amp;quot;: &amp;quot; &amp;amp; item &amp;amp; vbCRLF&lt;br /&gt;
    Next&lt;br /&gt;
  End If&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* The data returned will be a JSON object, stored in data.&lt;br /&gt;
* This code dumps the name and value of the fields in data.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= PayPal =&lt;br /&gt;
[[File:Paypal1.jpg]]&lt;br /&gt;
&amp;lt;br clear=&amp;quot;all&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The [[PayPal]] control allows you to collect money from PayPal for sales, subscriptions and donations. &lt;br /&gt;
* Much easier to set up and use than a credit card.&lt;br /&gt;
* First, set yourself up as a PayPal Merchant. &lt;br /&gt;
* Assuming you already have a PayPal account, go to the Merchant Services tab on the main screen. &lt;br /&gt;
* On the left, click on a tab called “Website Payments Standard”. &lt;br /&gt;
* Once you are set up as a merchant, you will need to set up your product. &lt;br /&gt;
* Use the Merchant Services page: Choose the “Buy Now button” option. &lt;br /&gt;
* Enter a number of fields, including item name, item ID (a reference number for your own use), price, currency (21 choices!), shipping and tax info. &lt;br /&gt;
* Once complete, click on ‘Create Button’.&lt;br /&gt;
* It will go to a new page, showing the code for the button. &lt;br /&gt;
* You’re interested in the string just after “value=”. &lt;br /&gt;
* Copy into hostedButtonID in the control’s properties.&lt;br /&gt;
* When the user taps on &amp;quot;Buy Now&amp;quot;, PayPal takes over using the information you set up in hostedButtonID.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Lab_Session:_Multimedia&amp;diff=4994</id>
		<title>Lab Session: Multimedia</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Lab_Session:_Multimedia&amp;diff=4994"/>
		<updated>2014-01-07T06:24:28Z</updated>

		<summary type="html">&lt;p&gt;Admin: 10 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is an independent lab in which you&#039;ll explore Audio, Video, and HTMLViews.&lt;br /&gt;
&lt;br /&gt;
# Create a new project.&lt;br /&gt;
# Add appropriate forms and navigation so that you have a main form, along with forms for audio, video, and HTMLView experiments.&lt;br /&gt;
# For the audio and video forms, include some of your favorite audio or video files.  If you don&#039;t have files available, feel free to use Super.wav and https://www.nsbasic.com/SpaceOddity.mp4&lt;br /&gt;
# For the HTMLView form, embed some content you enjoy, for instance a YouTube video, map, or pdf.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=MultiMedia&amp;diff=4983</id>
		<title>MultiMedia</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=MultiMedia&amp;diff=4983"/>
		<updated>2014-01-07T06:24:26Z</updated>

		<summary type="html">&lt;p&gt;Admin: 38 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= PictureBox: Drawing, text, images, sprites =&lt;br /&gt;
&lt;br /&gt;
The [[PictureBox]] control is a powerful container for images, drawing and text. &lt;br /&gt;
&lt;br /&gt;
* Based on the [http://en.wikipedia.org/wiki/Canvas_element HTML5 Canvas] element.&lt;br /&gt;
&lt;br /&gt;
* Before you can output anything to a PictureBox, a context must be created:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pb = PictureBox1.getContext(&amp;quot;2d&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* All drawing, images, etc. are done to the context.&lt;br /&gt;
&lt;br /&gt;
* Declare the context variable globally if needed.&lt;br /&gt;
&lt;br /&gt;
* There are really only 3 things you can do with a PictureBox: Everything else deals with the context:&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| getContext(&amp;quot;2d&amp;quot;) || Gets the drawing context. Returns the object that the PictureBox Context functions use. &amp;quot;2d&amp;quot; is currently the only valid argument.&lt;br /&gt;
|-&lt;br /&gt;
| refresh() || Redraws the entire PictureBox. Required after resizing the box or scrolling.&lt;br /&gt;
|-&lt;br /&gt;
| toDataURL(type) || Returns the current picturebox in a Base64 string image. If type is not specified, it is in PNG format. Type can also be &amp;quot;image/jpeg&amp;quot; or &amp;quot;image/gif&amp;quot;.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
[[File:Picturebox.png|framed|center|320px]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== Drawing ==&lt;br /&gt;
&lt;br /&gt;
* Here are some of the drawing commands.&lt;br /&gt;
* More are listed in the [[PictureBox|full documentation]]&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
| arc(x, y, radius, startAngle, endAngle, counterclockwise) || Adds an arc to the current path using a radius and specified angles(in radians).&lt;br /&gt;
|-&lt;br /&gt;
| arcTo(x1, y1, x2, y2, radius) || Adds an arc of a circle to the current sub path by using a radius and tangent points.&lt;br /&gt;
|-&lt;br /&gt;
| beginPath() || Creates a new path in the canvas and sets the starting point to the coordinate (0,0).&lt;br /&gt;
|-&lt;br /&gt;
| bezierCurveTo(cpx1, cpy1, cpx2, cpy2, x, y) || Adds a cubic Bezier&#039;s curve to the current sub path using two control points.&lt;br /&gt;
|-&lt;br /&gt;
| clearRect(x, y, width, height) || Clears the specified rectangle region and makes it transparent.&lt;br /&gt;
|-&lt;br /&gt;
| closePath() || Closes an open path and attempts to draw a straight line from the current point to starting point of the path. The use of closePath() is optional. &lt;br /&gt;
|-&lt;br /&gt;
| fill() || Closes the current path and paints the area within it.&lt;br /&gt;
|-&lt;br /&gt;
| fillRect(x, y, width, height) || Draws a filled rectangle.&lt;br /&gt;
|-&lt;br /&gt;
| fillStyle || color|gradient|pattern&lt;br /&gt;
|-&lt;br /&gt;
| lineCap || Sets style of end caps for a line. &amp;quot;butt&amp;quot;, &amp;quot;round&amp;quot; or &amp;quot;square&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
| lineJoin || Set style where two lines meet. &amp;quot;bevel&amp;quot;, &amp;quot;round&amp;quot; or &amp;quot;mitre&amp;quot;.&lt;br /&gt;
|-&lt;br /&gt;
| lineWidth || The current line width, in pixels.&lt;br /&gt;
|-&lt;br /&gt;
| lineTo(x, y) || Adds a line segment from the current point to the specified coordinate.&lt;br /&gt;
|-&lt;br /&gt;
| rect(x, y, width, height) || Adds a rectangle.&lt;br /&gt;
|-&lt;br /&gt;
| stroke() || Actually draws the path you have defined&lt;br /&gt;
|-&lt;br /&gt;
| strokeRect(x, y, width, height) || Draws a rectangular outline.&lt;br /&gt;
|-&lt;br /&gt;
| strokeStyle || color|gradient|pattern&lt;br /&gt;
|-&lt;br /&gt;
| strokeText(text, x, y, maxWidth) || Draws text (with no fill) on the canvas.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
* Here is an example of some drawing:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  &#039;start by setting our colors.&lt;br /&gt;
  pb.strokeStyle = vbBlack&lt;br /&gt;
  pb.fillStyle = vbRed&lt;br /&gt;
  &#039;Now, we define the lines we want to draw in a path.&lt;br /&gt;
  pb.beginPath()&lt;br /&gt;
  pb.arc(150,150,50,0,Math.PI*2,True)&lt;br /&gt;
  pb.closePath()&lt;br /&gt;
  &#039;Path is complete: draw it&lt;br /&gt;
  pb.stroke()&lt;br /&gt;
  &#039;and paint the area inside the path&lt;br /&gt;
  pb.fill()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== Text ==&lt;br /&gt;
* Here are the text functions&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| fillText(text, x, y) || Writes text using current settings of font, textAlign and textBaseline.&lt;br /&gt;
|-&lt;br /&gt;
| font || The font to use for text. It is a string with three parts: &amp;quot;&#039;&#039;style&#039;&#039; &#039;&#039;size&#039;&#039; &#039;&#039;fontname&#039;&#039;&amp;quot;. &#039;&#039;style&#039;&#039; can be normal, italic or bold. Example: &amp;quot;italic 40px Calibri&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| measureText(text) || Returns a rectangle object with text&#039;s size.&lt;br /&gt;
|-&lt;br /&gt;
| strokeText(text, x, y, maxWidth) || Draws text (with no fill) on the canvas.&lt;br /&gt;
|-&lt;br /&gt;
| textAlign || Controls text alignment. Possible values are &amp;lt;code&amp;gt;start&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;end&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;left&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;right&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;center&amp;lt;/code&amp;gt;.&lt;br /&gt;
|-&lt;br /&gt;
| textBaseline || Controls where the text is drawn relative to the starting point. Possible values are &amp;lt;code&amp;gt;top&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;hanging&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;middle&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;alphabetic&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;ideographic&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;bottom&amp;lt;/code&amp;gt;.&lt;br /&gt;
|-&lt;br /&gt;
| style(x, y, width, height) || Any valid style string.&lt;br /&gt;
|}&lt;br /&gt;
* Here is some sample code&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  pb.textBaseline = &amp;quot;top&amp;quot;&lt;br /&gt;
  pb.font=&amp;quot;16px sans-serif&amp;quot;&lt;br /&gt;
  pb.fillText(&amp;quot;This is a picturebox&amp;quot;,100,0)  &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== Images ==&lt;br /&gt;
* Images are loaded asynchronously, since they may take time to load.&lt;br /&gt;
* A global image object needs to be created to load the image into.&lt;br /&gt;
* When load is complete, a function with the image object _onload is called.&lt;br /&gt;
* It can then be drawn on the PictureBox.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myImage=new Image()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Here are the image functions:&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| createImageData(width, height) || Creates a new, blank ImageData object.&lt;br /&gt;
|-&lt;br /&gt;
| drawImage(image, x, y, width, height) || Draw an image.&lt;br /&gt;
|-&lt;br /&gt;
| getImageData(x,y,height,width) || Return the image data for a portion of the image. Includes width, height, data array [rgba].&lt;br /&gt;
|-&lt;br /&gt;
| globalCompositeOperation(source-over, source-atop, source-in, source-out, destination-over, destination-atop, destination-in, destination-out, lighter, copy, xor ) || Sets or returns how a source (new) images are drawn onto a destination (existing) image.&lt;br /&gt;
|-&lt;br /&gt;
| putImageData(imgData, x, y, dirtyX, dirtyY, dirtyWidth, dirtyHeight) || Puts the image data (from a specified ImageData object) back onto the canvas.&lt;br /&gt;
|}&lt;br /&gt;
* Here is how the code looks:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myImage=new Image()&lt;br /&gt;
Function Button3_onclick()&lt;br /&gt;
  &#039;Set the image. When it finishes loading, Image1_onload will be called.&lt;br /&gt;
  myImage.src=&amp;quot;mario.jpg&amp;quot;  &lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Function myImage_onload()&lt;br /&gt;
  pb.drawImage(myImage,0,0)&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Do not set the image in global code - the PictureBox will not be ready.&lt;br /&gt;
* Doing so in Sub Main or a button is fine.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== Sprites ==&lt;br /&gt;
* PictureBoxes can be moved on the screen so they act as sprites&lt;br /&gt;
* Here we move the complete PictureBox and flip it upside down.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  PictureBox1.Left=PictureBox1.Left+5&lt;br /&gt;
  PictureBox1.style.webkitTransform=&amp;quot;rotate(180deg)&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Animate a sprite by using a SetTimeout function to be run every few milliseconds.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  SetTimeout(&amp;quot;moveMario()&amp;quot;,10)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Multimedia =&lt;br /&gt;
&lt;br /&gt;
== Audio ==&lt;br /&gt;
[[File:Audiovideo.png|framed|center]]&lt;br /&gt;
The [[Audio]] control is used to play sounds. &lt;br /&gt;
&lt;br /&gt;
* Sound files can be any common format, including mp3, ogg, uncompressed wav and aac. &lt;br /&gt;
&lt;br /&gt;
Here are some options for it:&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| autoplay || Audio will start playing as soon as ready. Not supported on iOS.&lt;br /&gt;
|-&lt;br /&gt;
| controls || Controls will be displayed, such as a Play.&lt;br /&gt;
|-&lt;br /&gt;
| loop || Audio will start over again when finished.&lt;br /&gt;
|-&lt;br /&gt;
| preload  || Audio should be loaded when the page loads. Ignored if autoplay is present.&lt;br /&gt;
|-&lt;br /&gt;
| src || The name of the file. For example, Super.wav. It can be in the project folder or on a website.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function Button1_onclick()&lt;br /&gt;
  Audio1.play()&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== [[Video]] ==&lt;br /&gt;
&lt;br /&gt;
The Video control is used to play a video. &lt;br /&gt;
&lt;br /&gt;
* The video has to be in a specific format. Generally, H.264+AAC+MP4 will work.&lt;br /&gt;
&lt;br /&gt;
{| class = &amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| autoplay || Video will start playing as soon as ready.&lt;br /&gt;
|-&lt;br /&gt;
| controls || Controls will be displayed, such as a Play.&lt;br /&gt;
|-&lt;br /&gt;
| loop || Video will start over again when finished.&lt;br /&gt;
|-&lt;br /&gt;
| preload || Video should be loaded when the page loads. Ignored if autoplay is present.&lt;br /&gt;
|-&lt;br /&gt;
| src || The name of the file. For example, http://www.nsbasic.com/videotest.mp4. It should be in the project folder or on a web site.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function Button2_onclick()&lt;br /&gt;
  Video1.play()&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= HTMLView =&lt;br /&gt;
&lt;br /&gt;
The HTMLView control is a general purpose control which can be used as a container for various kinds of data.&lt;br /&gt;
&lt;br /&gt;
* Based on the HTML &amp;amp;lt;div&amp;gt; element&lt;br /&gt;
&lt;br /&gt;
* It can display any kind of HTML&lt;br /&gt;
&lt;br /&gt;
* Anything that is valid HTML and assigned to innerHTML will display.&lt;br /&gt;
&lt;br /&gt;
* If the image is too large for the display area, it can be scrolled.&lt;br /&gt;
&lt;br /&gt;
== HTML ==&lt;br /&gt;
[[File:Htmlview1.png|framed|center]]&lt;br /&gt;
* Pure HTML can be displayed by assigning to innerHTML&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  HTMLview1.innerHTML=&amp;quot;This is an &amp;lt;b&amp;gt;HTMLview&amp;lt;/b&amp;gt; with scrolling.&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;&amp;quot; &amp;amp; _&lt;br /&gt;
    &amp;quot;&amp;lt;img src=mario.jpg width=100 height=200&amp;gt;&amp;lt;br&amp;gt;&amp;quot; &amp;amp; _&lt;br /&gt;
    &amp;quot;&amp;lt;img src=mario.jpg width=100 height=200&amp;gt;&amp;quot;&lt;br /&gt;
  &#039;reset the scroll area&lt;br /&gt;
  HTMLview1.refresh()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* The refresh() call is needed after adding data to reset the scrolling parameters.&lt;br /&gt;
* Information can be appende to the existing data in the view:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  HTMLview1.innerHTML=HTMLview1.innerHTML &amp;amp; &amp;quot;&amp;lt;br&amp;gt;Length is &amp;quot; &amp;amp; Len(HTMLview1.innerHTML)&lt;br /&gt;
  HTMLview1.refresh()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== Show a Map ==&lt;br /&gt;
[[File:Htmlview2.png|framed|center]]&lt;br /&gt;
* Static data returned from a website can be displayed&lt;br /&gt;
&lt;br /&gt;
* In this example, we are getting an image from [http://en.wikipedia.org/wiki/Google_maps Google Maps].&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  longitude = 48.8582&lt;br /&gt;
  latitude = 2.2945&lt;br /&gt;
  zoomsize=18 &#039;specify zoom (0-21; bigger is closer)&lt;br /&gt;
&lt;br /&gt;
  &#039; fill HTMLview box with GoogleMap with specified center and zoom level&lt;br /&gt;
  HTMLview1.innerHTML=&amp;quot;&amp;lt;img height=640 width=640 &amp;quot; _&lt;br /&gt;
    &amp;quot;src=http://maps.google.com/maps/api/staticmap?&amp;quot; _&lt;br /&gt;
    &amp;amp; &amp;quot;center=&amp;quot; latitude &amp;amp; &amp;quot;,&amp;quot; &amp;amp; longitude &amp;amp; &amp;quot;&amp;amp;zoom=&amp;quot;&amp;amp;zoomsize _&lt;br /&gt;
    &amp;amp; &amp;quot;&amp;amp;size=640x640&amp;amp;maptype=hybrid&amp;amp;sensor=false&amp;gt;&amp;lt;/img&amp;gt;&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* It&#039;s the Eiffel Tower in Paris!&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== Show HTML file ==&lt;br /&gt;
[[File:Htmlview3.png|framed|center]]&lt;br /&gt;
* We can also display an HTML file.&lt;br /&gt;
&lt;br /&gt;
* However, it has to be from the same server.&lt;br /&gt;
&lt;br /&gt;
* Otherwise, there will be a [http://en.wikipedia.org/wiki/Same-origin_policy Cross Origin request] error.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  htm=ReadFile(&amp;quot;year.htm&amp;quot;)&lt;br /&gt;
  If htm.status = 200 Then      &lt;br /&gt;
    HTMLview1.innerHTML=htm.responseText&lt;br /&gt;
    HTMLview1.refresh()&lt;br /&gt;
  Else&lt;br /&gt;
    MsgBox &amp;quot;Could not read file. Are you running from a deployed app? It will not work locally.&amp;quot;&lt;br /&gt;
  End If  &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* ReadFile is a simplified version of AJAX.&lt;br /&gt;
* It reads the entire contents of the file.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== Show PDF file ==&lt;br /&gt;
[[File:Htmlview4.png|framed|center]]&lt;br /&gt;
&lt;br /&gt;
* pdf files can be included with the app&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  HTMLview1.innerHTML=&amp;quot;&amp;lt;iframe src=&#039;year.pdf&#039; width=310 height=260 &amp;gt;&amp;lt;/iframe&amp;gt;&amp;quot;&lt;br /&gt;
  HTMLview1.refresh()  &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* scrolling is automatically enabled&lt;br /&gt;
* The refresh() resets the scrolling area.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== Show YouTube video ==&lt;br /&gt;
[[File:Htmlview5.png|framed|center]]&lt;br /&gt;
&lt;br /&gt;
* Embedded YouTube videos can be shown&lt;br /&gt;
* Get the YouTube video ID from YouTube&lt;br /&gt;
* Substitute it in the innerHTML string below&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  HTMLview1.innerHTML=&amp;quot;&amp;lt;iframe frameborder=&#039;0&#039; allowfullscreen &amp;quot; _&lt;br /&gt;
    &amp;amp; &amp;quot;src=&#039;http://www.youtube.com/embed/eDF7QRC3c3Y?feature=player_detailpage&#039;&amp;gt;&amp;quot; _&lt;br /&gt;
    &amp;amp; &amp;quot;&amp;lt;/iframe&amp;gt;&#039;&amp;quot;&lt;br /&gt;
  HTMLview1.refresh()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* More info on integrating YouTube with your apps here: https://developers.google.com/youtube/&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Lab_Session:_Saving_data_into_SQLite&amp;diff=4944</id>
		<title>Lab Session: Saving data into SQLite</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Lab_Session:_Saving_data_into_SQLite&amp;diff=4944"/>
		<updated>2014-01-07T06:24:20Z</updated>

		<summary type="html">&lt;p&gt;Admin: 4 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In this lab you will modify your app so you can save historical weather data in SQLite.&lt;br /&gt;
&lt;br /&gt;
== Student Outline ==&lt;br /&gt;
&lt;br /&gt;
# Open LabSqlite.nsx&lt;br /&gt;
# Update your initialization code in &#039;&#039;Sub Main&#039;&#039; to create a table in the database, if it doesn&#039;t exist already.&lt;br /&gt;
# Update your &#039;&#039;btnSave&#039;&#039; click event to INSERT records into the table you created in the first step.&lt;br /&gt;
# Update your onshow event for &#039;&#039;frmSaves&#039;&#039; so it SELECTs the entries in an array that&#039;s used to populate the list.&lt;br /&gt;
# Modify your click event for &#039;&#039;lstSaves&#039;&#039; to use the array you populated in the previous step.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Lab_Session:_Saving_data_to_localStorage&amp;diff=4939</id>
		<title>Lab Session: Saving data to localStorage</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Lab_Session:_Saving_data_to_localStorage&amp;diff=4939"/>
		<updated>2014-01-07T06:24:19Z</updated>

		<summary type="html">&lt;p&gt;Admin: 5 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In this lab you will modify your app so you can save historical weather data in localStorage.&lt;br /&gt;
&lt;br /&gt;
== Student Outline ==&lt;br /&gt;
&lt;br /&gt;
# Open LabLocalStorage.nsx.&lt;br /&gt;
# Modify &#039;&#039;Sub Main&#039;&#039; to check &#039;&#039;localStorage&#039;&#039; for an element called &#039;&#039;weatherSaves&#039;&#039;.  If it does not exist, initialize it to an empty array.  Remove the &#039;&#039;lstSaves&#039;&#039; initialization code.&lt;br /&gt;
# Modify the click code for &#039;&#039;btnSave&#039;&#039; so that it adds a new entry to the &#039;&#039;weatherSaves&#039;&#039; array of &#039;&#039;localStorage&#039;&#039;.  The entry should be an object containing all the weather data including the current date.&lt;br /&gt;
# Add an onshow event for &#039;&#039;frmSaves&#039;&#039; that initializes &#039;&#039;lstSaves&#039;&#039; with the entries from the &#039;&#039;weatherSaves&#039;&#039; array.&lt;br /&gt;
# Add a click event to &#039;&#039;lstSaves&#039;&#039; that retrieves the proper entry from &#039;&#039;weatherSaves&#039;&#039; when clicked, sets the proper values in &#039;&#039;frmSavedData&#039;&#039;, and displays it.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Lab_Session:_Play_with_Features&amp;diff=4933</id>
		<title>Lab Session: Play with Features</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Lab_Session:_Play_with_Features&amp;diff=4933"/>
		<updated>2014-01-07T06:24:17Z</updated>

		<summary type="html">&lt;p&gt;Admin: 8 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In this lab, you will add a compass to your application, allow it to pull weather data by your location, and have it choose a random location on shake.&lt;br /&gt;
&lt;br /&gt;
== Student Outline ==&lt;br /&gt;
&lt;br /&gt;
The following lab contains three parts.  Start by opening LabFeatures2.nsx.&lt;br /&gt;
&lt;br /&gt;
=== Compass ===&lt;br /&gt;
&lt;br /&gt;
Using the resources and code from the Compass sample, add a compass to &#039;&#039;frmCompass&#039;&#039; in your app.&lt;br /&gt;
&lt;br /&gt;
=== Geolocation ===&lt;br /&gt;
&lt;br /&gt;
# Attach an onchange event to &#039;&#039;flpCurrentLocation&#039;&#039;.  When it is switched to On, you should retrieve the current location using [[https://developer.mozilla.org/en-US/docs/Web/API/Geolocation.getCurrentPosition navigator.geolocation.getCurrentPosition]] and disable &#039;&#039;txtCity&#039;&#039; and &#039;&#039;btnLoad&#039;&#039;.  When switched to off, &#039;&#039;txtCity&#039;&#039; and &#039;&#039;btnLoad&#039;&#039; should be re-enabled.&lt;br /&gt;
# When the current location has been retrieved, enable &#039;&#039;btnLoad&#039;&#039;.&lt;br /&gt;
# When &#039;&#039;btnLoad&#039;&#039; is pressed and &#039;&#039;flpCurrentLocation&#039;&#039; is in the On position, load the weather information via latitude and longitude, using the following API: http://api.openweathermap.org/data/2.5/weather?lat=35&amp;amp;lon=139&lt;br /&gt;
&lt;br /&gt;
=== Accelerometer ===&lt;br /&gt;
&lt;br /&gt;
# A shaking motion can be sensed by setting a threshold for change in [[Event|accelerationIncludingGravity]].  Experiment to determine what an acceptable threshold is for your device. (an example of this in JavaScript is available here: http://stackoverflow.com/a/4475330)&lt;br /&gt;
# When on &#039;&#039;frmMain&#039;&#039;, listen for accelerometer events that could indicate a shaking motion.  Set the location to a random latitude and longitude to load weather for that location.&lt;br /&gt;
&lt;br /&gt;
== Bonus ==&lt;br /&gt;
&lt;br /&gt;
* Modify the compass so it points somewhere other than north.&lt;br /&gt;
* As you saw in the lecture, it&#039;s possible to update the current location continuously.  Modify your code to function this way, rather than only retrieving the location once.&lt;br /&gt;
* When retrieving a random location, it might be helpful to display what cities you are near, or what the latitude and longitude is.  Modify your app to provide this functionality.&lt;br /&gt;
* The accelerometer is capable of detecting many movements beyond shakes.  Now that you&#039;ve modified your app to display the random location you&#039;ve retrieved, modify it so that after a random location is retrieved tilting the phone will modify that location, increasing or decreasing the latitude or longitude.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Mobile_Device_Features_2&amp;diff=4924</id>
		<title>Mobile Device Features 2</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Mobile_Device_Features_2&amp;diff=4924"/>
		<updated>2014-01-07T06:24:15Z</updated>

		<summary type="html">&lt;p&gt;Admin: 21 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Compass =&lt;br /&gt;
&lt;br /&gt;
[[File:Compass.png|framed|right]]&lt;br /&gt;
&lt;br /&gt;
* Certain devices have a built in compass sensor.&lt;br /&gt;
&lt;br /&gt;
* If they do, they call the ondeviceorientation() function when the compass reading changes.&lt;br /&gt;
&lt;br /&gt;
* An event object is passed to the function with the compass reading in evt.webkitCompassHeading.&lt;br /&gt;
&amp;lt;br clear=&amp;quot;all&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
function window_ondeviceorientation(evt)&lt;br /&gt;
  TextBox1.value=evt.webkitCompassHeading&lt;br /&gt;
End function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* The Compass sample uses this information to rotate an image of a compass.&lt;br /&gt;
&lt;br /&gt;
* The webKitTransform function rotates an image efficiently.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
pos=&amp;quot;0&amp;quot;&lt;br /&gt;
&lt;br /&gt;
function window_ondeviceorientation(e)&lt;br /&gt;
  imgCompass.style.webkitTransform=&amp;quot;rotate(&amp;quot; &amp;amp; pos &amp;amp; &amp;quot;deg)&amp;quot;&lt;br /&gt;
  pos = e.webkitCompassHeading&lt;br /&gt;
  imgCompass.style.webkitTransform=&amp;quot;rotate(-&amp;quot; &amp;amp; pos &amp;amp; &amp;quot;deg)&amp;quot;&lt;br /&gt;
End function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Geolocation =&lt;br /&gt;
&lt;br /&gt;
[[File:Geolocation.jpg|framed|left]]&lt;br /&gt;
&lt;br /&gt;
* Geolocation uses GPS sensors to return the current location of the device.&lt;br /&gt;
&lt;br /&gt;
* The watchPosition() function sets the frequency of the Geolocation events.&lt;br /&gt;
&lt;br /&gt;
* When a Geolocation event is triggered, the function named in the watchPosition function is called.&lt;br /&gt;
&lt;br /&gt;
* The following data is passed to the event:&lt;br /&gt;
&amp;lt;br clear=&amp;quot;all&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|location.coords.longitude || The current longitude of the device. GPS required.&lt;br /&gt;
|-&lt;br /&gt;
|location.coords.latitude || The current latitude of the device. GPS required.&lt;br /&gt;
|-&lt;br /&gt;
|location.coords.altitude|| The height of the location. GPS required.&lt;br /&gt;
|-&lt;br /&gt;
|location.coords.accuracy || The accuracy of the location. GPS required.&lt;br /&gt;
|-&lt;br /&gt;
|location.coords.altitudeAccuracy || The accuracy of the altitude. GPS required.&lt;br /&gt;
|-&lt;br /&gt;
|location.coords.heading|| Degrees clockwise from North. GPS required.&lt;br /&gt;
|-&lt;br /&gt;
|location.coords.speed|| Speed, meter per second. GPS required.&lt;br /&gt;
|-&lt;br /&gt;
|location.coords.timestamp || time and date of the observation. GPS required.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
* Here&#039;s the code to start generating geolocation events:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Dim gps&lt;br /&gt;
function btnStart_onclick()&lt;br /&gt;
  options={timeout: 5000, maximumAge: 5000, enableHighAccuracy: True}&lt;br /&gt;
  gps=navigator.geolocation.watchPosition(onGeolocation, errorCallBack, options)&lt;br /&gt;
End function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This code will call onGeolocation every 5 seconds.&lt;br /&gt;
* If GPS data cannot be obtained, the errorCallBack function is called.&lt;br /&gt;
* Cancel it by executing:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  navigator.geolocation.clearWatch(gps)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Here&#039;s what the onGeolocation looks like. It gets called every 5 seconds.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
function onGeolocation(location)&lt;br /&gt;
  Dim s&lt;br /&gt;
  s = &amp;quot;Longitude: &amp;quot; + location.coords.longitude &amp;amp; vbCRLF&lt;br /&gt;
  s = s &amp;amp; &amp;quot;Latitude: &amp;quot; + location.coords.latitude &amp;amp; vbCRLF&lt;br /&gt;
  s = s &amp;amp; &amp;quot;Speed: &amp;quot; + location.coords.speed &amp;amp; &amp;quot; &amp;quot; &lt;br /&gt;
  s = s &amp;amp; &amp;quot;Altitude: &amp;quot; + location.coords.altitude &amp;amp; vbCRLF&lt;br /&gt;
  s = s &amp;amp; &amp;quot;Accuracy: &amp;quot; + location.coords.accuracy &amp;amp; &amp;quot; &amp;quot;&lt;br /&gt;
  s = s &amp;amp; &amp;quot;Accuracy(altitude): &amp;quot; + location.coords.altitudeAccuracy &amp;amp; &amp;quot; &amp;quot; &amp;amp; vbCRLF&lt;br /&gt;
  &#039;Convert timestamp if needed.&lt;br /&gt;
  if IsNumeric(location.timestamp) Then&lt;br /&gt;
    gpsDate=new Date(location.timestamp)&lt;br /&gt;
  else&lt;br /&gt;
    gpsDate=location.timestamp&lt;br /&gt;
  End if&lt;br /&gt;
  TextArea1.value = s &amp;amp; &amp;quot;Timestamp: &amp;quot; + gpsDate&lt;br /&gt;
  ShowMap(location.coords.latitude, location.coords.longitude)&lt;br /&gt;
End function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This function displays the GPS results in a TextArea.&lt;br /&gt;
* The code has to deal with the problem of different browsers returning timestamp in different formats.&lt;br /&gt;
* The ShowMap() function near the end displays a map from Google Maps.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
function ShowMap(latitude, longitude)&lt;br /&gt;
  if SysInfo(10)-lastRefresh&amp;lt;10000 Then Exit function&lt;br /&gt;
  lastRefresh=SysInfo(10)&lt;br /&gt;
  s = &amp;quot;&#039;https://maps.google.com/maps/api/staticmap?center=&amp;quot; &amp;amp; _&lt;br /&gt;
  latitude &amp;amp; &amp;quot;,&amp;quot; &amp;amp; longitude &amp;amp; _&lt;br /&gt;
  &amp;quot;&amp;amp;zoom=14&amp;amp;size=300x200&amp;amp;maptype=roadmap&amp;amp;sensor=true&amp;amp;output=embed&#039;&amp;quot;&lt;br /&gt;
  Map.innerHTML=&amp;quot;&amp;lt;img width=300 height=200 src=&amp;quot; &amp;amp; s  &amp;amp; &amp;quot;&amp;gt;&amp;lt;/img&amp;gt;&amp;quot;&lt;br /&gt;
End function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This function displays a Google map.&lt;br /&gt;
* The map is updated every 10 seconds&lt;br /&gt;
* More info on Google maps here: http://code.google.com/apis/maps/documentation/staticmaps/&lt;br /&gt;
* We pack the latitude and longitude into a URL query string.&lt;br /&gt;
* We display the results of the URL in an HTMLview.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Accelerometer =&lt;br /&gt;
&lt;br /&gt;
[[File:Accelerometer.jpg|framed|left]]&lt;br /&gt;
&lt;br /&gt;
The Accelerometer is a sensor that returns information about the device&#039;s movement.&lt;br /&gt;
&lt;br /&gt;
* Results are returned in meters per second squared. &lt;br /&gt;
* Results can be with or without taking gravity into effect.&lt;br /&gt;
* Whenever motion is detected, the  window_ondevicemotion function is called.&lt;br /&gt;
&amp;lt;br clear=&amp;quot;all&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Sub window_ondevicemotion(event)&lt;br /&gt;
  ax = event.accelerationIncludingGravity.x;&lt;br /&gt;
  ay = event.accelerationIncludingGravity.y;&lt;br /&gt;
End Sub&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* This code sets a couple of global variables: acceleration in the x direction (horizontal) and the y direction (vertical)&lt;br /&gt;
* We can use this data to move a ball around on the screen.&lt;br /&gt;
* We will sample the the movement 100 times per second.&lt;br /&gt;
* Based on how high the movement rate is, move the ball varying distances.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
delay = 10&lt;br /&gt;
SetInterval(moveBall, delay)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* SetInterval is an AppStudio function which calls a function repeatedly.&lt;br /&gt;
* moveBall is the name of the function to call.&lt;br /&gt;
* delay is the time, in milliseconds.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Sub moveBall()&lt;br /&gt;
  vy = vy + -(ay)&lt;br /&gt;
  vx = vx + ax&lt;br /&gt;
&lt;br /&gt;
  y = parseInt(y + vy * vMultiplier)&lt;br /&gt;
  x = parseInt(x + vx * vMultiplier)&lt;br /&gt;
&lt;br /&gt;
  &#039;do bounds checking&lt;br /&gt;
  If x&amp;lt;0 Then&lt;br /&gt;
    x = 0&lt;br /&gt;
    vx = 0&lt;br /&gt;
  End if&lt;br /&gt;
  If y&amp;lt;0 Then&lt;br /&gt;
    y = 0&lt;br /&gt;
    vy = 0&lt;br /&gt;
  End if&lt;br /&gt;
  If x&amp;gt;document.documentElement.clientWidth-20 Then&lt;br /&gt;
    x = document.documentElement.clientWidth-20&lt;br /&gt;
    vx = 0&lt;br /&gt;
  End if&lt;br /&gt;
  If y&amp;gt;document.documentElement.clientHeight-20 Then&lt;br /&gt;
    y = document.documentElement.clientHeight-20&lt;br /&gt;
    vy = 0&lt;br /&gt;
  End if&lt;br /&gt;
&lt;br /&gt;
  ball.style.top = y + &amp;quot;px&amp;quot;&lt;br /&gt;
  ball.style.left = x + &amp;quot;px&amp;quot;&lt;br /&gt;
End Sub  &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* The first 4 statements calculate the new position.&lt;br /&gt;
* The next section checks to make sure the ball does not roll off the screen.&lt;br /&gt;
* The last two statements do the actual movement.&lt;br /&gt;
&lt;br /&gt;
The complete sample is called Accelerometer.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Lab_Session:_Device_features&amp;diff=4902</id>
		<title>Lab Session: Device features</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Lab_Session:_Device_features&amp;diff=4902"/>
		<updated>2014-01-07T06:24:12Z</updated>

		<summary type="html">&lt;p&gt;Admin: 7 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In this lab session, you will add features to your app that allow you to take a picture, record your feelings on the weather with emoji, and respond to device rotation.&lt;br /&gt;
&lt;br /&gt;
== Student Outline ==&lt;br /&gt;
&lt;br /&gt;
# Open LabFeatures.nsx&lt;br /&gt;
# Add the [[Orientation]] control&lt;br /&gt;
# Put your application in portrait mode and verify that it displays an error when rotated to landscape.&lt;br /&gt;
# Add code to &#039;&#039;frmPhoto&#039;&#039; that allows the user to take a photo and display it.  You&#039;ll have to add the appropriate [[TextBox]] and [[PictureBox]].&lt;br /&gt;
# Replace the default values of &#039;&#039;selEmoji&#039;&#039; with a few Emoji characters so the user can select how they feel about the photo.  Emoticons work best.&lt;br /&gt;
# Modify the click event for &#039;&#039;btnLoad&#039;&#039; on &#039;&#039;frmMain&#039;&#039; so the TextBox, PictureBox and &#039;&#039;selEmoji&#039;&#039; are reset on click.&lt;br /&gt;
&lt;br /&gt;
== Bonus ==&lt;br /&gt;
&lt;br /&gt;
* In later labs, we&#039;ll be recording current weather data.  Modify the form you just created to make it clear it&#039;s for recording your impressions of the weather data.  Add a [[TextArea]] so users can record textual thoughts as well.  Make sure it&#039;s cleared when the weather is retrieved.&lt;br /&gt;
* A [[Select]] control is only good for a few items.  Create a new form that&#039;s specifically for choosing between 20-30 Emoji characters and replace the Select with it.&lt;br /&gt;
* Add an upload button, and allow the photo to be uploaded to a server.  Refer to the upload sample for details.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Mobile_Device_Features_1&amp;diff=4894</id>
		<title>Mobile Device Features 1</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Mobile_Device_Features_1&amp;diff=4894"/>
		<updated>2014-01-07T06:24:10Z</updated>

		<summary type="html">&lt;p&gt;Admin: 20 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In the next two segments, we will talk about some features that are unique to mobile devices and how to use them.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
= Camera =&lt;br /&gt;
[[File:Cameraimage.jpg]]&lt;br /&gt;
* Being able to access the camera directly is a recent feature&lt;br /&gt;
* It may not be supported on older devices&lt;br /&gt;
* iOS has a serious bug - there is a workaround&lt;br /&gt;
* Done using a [[TextBox]], with inputType set to &#039;file&#039;.&lt;br /&gt;
* Once the user has taken or selected a picture, TxtBox_onchange is executed:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
function txtGetPicture_onchange()&lt;br /&gt;
  reader.readAsDataURL(txtGetPicture.files[0])&lt;br /&gt;
  e=event&lt;br /&gt;
End function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Reading the picture in is asynchronous: pictures can be large and take time to load.&lt;br /&gt;
* Once the read is complete, reader_onload is called:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
function reader_onload(e)&lt;br /&gt;
  img.src=e.target.result&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* To display the picture, we need to put it into a PictureBox object. &lt;br /&gt;
* Since this also can take some time, it is done asynchronously&lt;br /&gt;
* Once the loading is complete, img_onload is called.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
function img_onload()&lt;br /&gt;
  drawImageIOSFix(pb,img,0,0,img.width,img.height, _&lt;br /&gt;
     0,0,PictureBox1.width,PictureBox1.height)&lt;br /&gt;
End function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Normally, we would use the [[PictureBox|pb.drawImage]] function&lt;br /&gt;
* But there is a bug in iOS. The drawImageIOSFix function does it properly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Emoji =&lt;br /&gt;
&lt;br /&gt;
[[File:Emoji.png]]&lt;br /&gt;
&lt;br /&gt;
* Emoji are extended characters that are built into mobile devices. &lt;br /&gt;
* There are hundreds of them: arrows, letters, roman numerals, pictures of food, building, transportation, flags, animals. And of course, happy faces, sad faces, crying faces.&lt;br /&gt;
* They are saved as standard characters: each has its own character code number.&lt;br /&gt;
* There is a complete list here: http://en.wikipedia.org/wiki/Emoji&lt;br /&gt;
* Support varies by browser&lt;br /&gt;
* Most mobile devices are OK&lt;br /&gt;
* Desktop Safari works&lt;br /&gt;
* Desktop Chrome needs an (but an [https://chrome.google.com/webstore/detail/chromoji-emoji-for-google/cahedbegdkagmcjfolhdlechbkeaieki extension] to see these)&lt;br /&gt;
* The characters are in the format &amp;amp;#xxxxxx; where xxxxxx is the decimal value&lt;br /&gt;
* Cheeseburger is &amp;amp;amp;#127828; (or &amp;amp;amp;#x1F354 in hex)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Orientation =&lt;br /&gt;
&lt;br /&gt;
Mobile devices can be rotated. It&#039;s up to you to decide how you want your app to handle this.&lt;br /&gt;
&lt;br /&gt;
* The two orientations are referred to as Portrait and Landscape.&lt;br /&gt;
&lt;br /&gt;
* The layout of your form will be completely different between the two.&lt;br /&gt;
&lt;br /&gt;
* If you don&#039;t want to support rotation, add the [[Orientation]] control to your app. Set its screenOrientation property to portrait or landscape. When the screen is rotated, this message will appear:&lt;br /&gt;
[[File:Orientation.png||400px]]&lt;br /&gt;
&lt;br /&gt;
* If you do want to support orientation, you will want to take action when the screen is rotated&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function window_onorientationchange()&lt;br /&gt;
  &#039;This function is called if the orientation of the device is changed.&lt;br /&gt;
  MsgBox &amp;quot;orientation changed to &amp;quot; &amp;amp; window.orientation&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* You can now resize and reposition your controls, using code like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function window_onorientationchange()&lt;br /&gt;
  If Abs(window.orientation)=90 Then &#039;Landscape&lt;br /&gt;
    btnSubmit.Left=&amp;quot;100px&amp;quot;&lt;br /&gt;
    btnSubmit.Top=&amp;quot;100px&amp;quot;&lt;br /&gt;
  Else                               &#039;Portrait &lt;br /&gt;
    btnSubmit.Left=&amp;quot;20px&amp;quot;&lt;br /&gt;
    btnSubmit.Top=&amp;quot;120px&amp;quot;&lt;br /&gt;
  End If&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* You will have to do this to all controls which are affected.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Lab_Session:_Weather_Data&amp;diff=4873</id>
		<title>Lab Session: Weather Data</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Lab_Session:_Weather_Data&amp;diff=4873"/>
		<updated>2014-01-07T06:24:07Z</updated>

		<summary type="html">&lt;p&gt;Admin: 7 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In this lab you will pull in some weather data from http://openweathermap.org/API.&lt;br /&gt;
&lt;br /&gt;
== Student Outline ==&lt;br /&gt;
&lt;br /&gt;
# Open LabWeather.nsx.&lt;br /&gt;
# Add a click event to &#039;&#039;btnLoad&#039;&#039; on &#039;&#039;frmMain&#039;&#039;&lt;br /&gt;
# Have the click event use the value from &#039;&#039;txtCity&#039;&#039; to query OpenWeatherMap&#039;s API: http://api.openweathermap.org/data/2.5/weather?q=Riyadh,sa&amp;amp;callback=weatherData&lt;br /&gt;
#* Keep in mind that you should URL encode any user entered parameters, like city, using [https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/encodeURIComponent encodeURIComponent]&lt;br /&gt;
#* Make sure you&#039;re using JSONP to make this request.&lt;br /&gt;
# Upon receiving the response, you should parse the response into the various Value labels on frmMain.  The format of the response is described here: http://bugs.openweathermap.org/projects/api/wiki/Weather_Data&lt;br /&gt;
&lt;br /&gt;
== Bonus ==&lt;br /&gt;
&lt;br /&gt;
* The [http://bugs.openweathermap.org/projects/api/wiki/API_2_5 weather API] has a lot of functionality that we aren&#039;t using.  Create new forms and fields to return and display either forecast data, historical data, or both.&lt;br /&gt;
* The city field requires a fairly exact name.  If you&#039;d like to allow for mistakes and abbreviations, you can integrate the [http://bugs.openweathermap.org/projects/api/wiki/Api_2_5_searhing city search api].  This returns a list of possible city matches.  One way to use this is to present a list that the user can choose from in a new form.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Asynchronous_Calls&amp;diff=4865</id>
		<title>Asynchronous Calls</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Asynchronous_Calls&amp;diff=4865"/>
		<updated>2014-01-07T06:24:05Z</updated>

		<summary type="html">&lt;p&gt;Admin: 9 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Using Ajax Asynchronously ==&lt;br /&gt;
&lt;br /&gt;
In our last Ajax discussion, we discovered that it could take half a second for an [[Ajax]] call to complete (actually, due to network latency, it could even be a lot more than that.) How do we do [[Ajax]] calls and not make our app look slow?&lt;br /&gt;
&lt;br /&gt;
Easy. We send the Ajax message off, then go do other stuff. When the response comes back, we respond to it. This is called Asynchronous operation.&lt;br /&gt;
&lt;br /&gt;
We do this by adding the name of the function to be called on completion as the 4th parameter of our [[Ajax]] call:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
req=Ajax(&amp;quot;ajax.php/?myText=&amp;quot; + txtSend.value, &amp;quot;&amp;quot;, &amp;quot;&amp;quot;, done)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Our callback function is called &#039;done&#039;. After we execute the Ajax call, the program goes on to the next statement in the program immediately. It doesn&#039;t wait for any response. We can update the screen, or wait for the user to do something else. When the reply comes back, our &#039;done&#039; function will be called:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Dim req&lt;br /&gt;
&lt;br /&gt;
Function btnAjax_onclick()&lt;br /&gt;
  req=Ajax(&amp;quot;ajax.php/?myText=&amp;quot; + txtSend.value, &amp;quot;&amp;quot;, &amp;quot;&amp;quot;, done)&lt;br /&gt;
  txtResponse.value=&amp;quot;Waiting for result.&amp;quot;&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Function done()&lt;br /&gt;
  If req.readyState&amp;lt;&amp;gt;4 Then Exit Function &#039;ignore progress reports&lt;br /&gt;
  If req.status=200 Then &#039;success&lt;br /&gt;
    txtResponse.value=req.responseText&lt;br /&gt;
  Else &#039;failure&lt;br /&gt;
    txtResponse.value=&amp;quot;Error: &amp;quot; &amp;amp; req.err.message&lt;br /&gt;
  End If&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&#039;done&#039; will actually be called several times with progress reports on the call. We only care if it completes, so we wait for req.readyState to be 4. The rest of our function works just like when we were not asynchronous.&lt;br /&gt;
&lt;br /&gt;
One of the uses of this technique that we see every day is to return partial results on a search field (as in Google). Each time a character is entered, it is sent to the server for a list of possible matches. As the results come back, the window is updated. Entering characters in the field is unaffected by the server communications that are going on at the same time.&lt;br /&gt;
&lt;br /&gt;
Check out the AjaxAsync app in the Samples to see this in action.&lt;br /&gt;
&lt;br /&gt;
== Using JSONP to get a Stock Quote ==&lt;br /&gt;
&lt;br /&gt;
Working with [[Ajax]], we have run into the [http://en.wikipedia.org/wiki/Same-origin_policy Same Origin Policy] over and over again. In this post, we&#039;ll show you another way to get around it. The Same Origin Policy restricts you from loading files from a server not your own. There is an exception: JavaScript (.js) files are allowed. There are sites on the web where you can request information and have it passed back in [http://en.wikipedia.org/wiki/JSONP JSONP] format. The &amp;quot;P&amp;quot; stands for padding: JSONP is JSON with padding. The results are returned as a function call, with the results as parameters. That function can then be called in your program.&lt;br /&gt;
&lt;br /&gt;
Let&#039;s use this to get a stock quote from Yahoo. There are 3 parts to this: first, we have to make the request. Next, we handle the return. Finally, we execute the function.&lt;br /&gt;
&lt;br /&gt;
==== Make the request ====&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
 Dim YQI, URL, callback&lt;br /&gt;
 YQI = escape(&amp;quot;select * from yahoo.finance.quotes where symbol in (&#039;AAPL&#039;,&#039;GOOG&#039;,&#039;MSFT&#039;)&amp;quot;)&lt;br /&gt;
 callback=&amp;quot;requestComplete&amp;quot;&lt;br /&gt;
 URL = &amp;quot;http://query.yahooapis.com/v1/public/yql?q=&amp;quot; &amp;amp; YQI &amp;amp; _&lt;br /&gt;
       &amp;quot;&amp;amp;format=json&amp;amp;env=http://datatables.org/alltables.env&amp;amp;callback=&amp;quot; &amp;amp; callback&lt;br /&gt;
 loadScript(URL)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Yahoo! has a very powerful API to look up all kinds of data. To make it easier, they have set up an interface using SQL like statements called YQI. In our code above, we start by creating our YQI request. The escape() function translates special characters and spaces so they can be sent in our Ajax call.&lt;br /&gt;
&lt;br /&gt;
URL is then composed of our YQI request with the rest of the boilerplate that is needed. The most interesting part is the &amp;amp;callback part. It names the function that the return values will be wrapped in.&lt;br /&gt;
&lt;br /&gt;
Having prepared everything, we can inject the script.&lt;br /&gt;
&lt;br /&gt;
==== Inject the script ====&lt;br /&gt;
&lt;br /&gt;
Yahoo! is going to return some code: it will be a call to the function we specified in callback, with the parameters all filled in. The following code will insert the code returned by Yahoo! into our program and execute it:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function loadScript(URL)&lt;br /&gt;
  Dim head, script&lt;br /&gt;
  head=document.getElementsByTagName(&amp;quot;head&amp;quot;)[0]&lt;br /&gt;
  script=document.createElement(&amp;quot;script&amp;quot;)&lt;br /&gt;
  script.src=URL&lt;br /&gt;
  script.async=True&lt;br /&gt;
  head.appendChild(script)&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
We do the usual checking to see if the call is complete. If it is, we will have gotten a text string back that looks something like this:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
requestComplete({&amp;quot;query&amp;quot;:&lt;br /&gt;
  {&amp;quot;count&amp;quot;:3,&amp;quot;created&amp;quot;:&amp;quot;2012-03-20T11:34:00Z&amp;quot;,&amp;quot;lang&amp;quot;:&amp;quot;en-US&amp;quot;,&amp;quot;results&amp;quot;:&lt;br /&gt;
     {&amp;quot;quote&amp;quot;:...);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
This is a valid function call, so when it is run, the function is executed.&lt;br /&gt;
&lt;br /&gt;
==== Execute the function ====&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function requestComplete(data)&lt;br /&gt;
  Dim quotes, i&lt;br /&gt;
  quotes=data.query.results.quote&lt;br /&gt;
  TextArea1.value=&amp;quot;&amp;quot;&lt;br /&gt;
  For i=0 To Len(quotes)-1&lt;br /&gt;
    TextArea1.value=TextArea1.value+quotes[i].symbol &amp;amp; quotes[i].Ask &amp;amp; vbCRLF&lt;br /&gt;
  Next&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The data that comes back is a fairly complex structure with a lot of data in it. You can copy it to the NotePad to see everything that is there. For now, we are just interested in the asking price of the stock. The results are returned in an array, with one element per stock.&lt;br /&gt;
&lt;br /&gt;
=== Cool things you can get on the web ===&lt;br /&gt;
&lt;br /&gt;
There are many web services that work in a similar fashion. One of the tip offs is if the calling string has an &amp;amp;callback argument. If it does, it probably can be used with this method.&lt;br /&gt;
&lt;br /&gt;
Some of these services are free or limited, while others require an API key that you must obtain from the service.&lt;br /&gt;
&lt;br /&gt;
Some places to go for services:&lt;br /&gt;
&lt;br /&gt;
* The master list is here: [http://www.programmableweb.com Programmable Web]&lt;br /&gt;
* Lots of stuff: [http://developer.yahoo.com/javascript/ Yahoo]!&lt;br /&gt;
* Weather: [http://www.wunderground.com/weather/api/d/docs Wunderground]&lt;br /&gt;
* Elevation: [http://www.geonames.org/export/JSON-webservices.html Geonames]&lt;br /&gt;
* Geographic Info: [http://www.geonames.org/export/JSON-webservices.html Geonames]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Data_Formats&amp;diff=4855</id>
		<title>Data Formats</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Data_Formats&amp;diff=4855"/>
		<updated>2014-01-07T06:24:03Z</updated>

		<summary type="html">&lt;p&gt;Admin: 8 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;There are several formats commonly used to transfer data to and from Web Services.&lt;br /&gt;
&lt;br /&gt;
= JSON =&lt;br /&gt;
&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Json JSON] (JavaScript Object Notation) is the simplest and most commonly used. &lt;br /&gt;
* It is simply a JavaScript object turned into a string.&lt;br /&gt;
* It is the same as a BASIC object turned into a string.&lt;br /&gt;
&lt;br /&gt;
Here is what it looks like in expanded form:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
{&lt;br /&gt;
    &amp;quot;firstName&amp;quot;: &amp;quot;John&amp;quot;,&lt;br /&gt;
    &amp;quot;lastName&amp;quot;: &amp;quot;Smith&amp;quot;,&lt;br /&gt;
    &amp;quot;age&amp;quot;: 25,&lt;br /&gt;
    &amp;quot;address&amp;quot;: {&lt;br /&gt;
        &amp;quot;streetAddress&amp;quot;: &amp;quot;21 2nd Street&amp;quot;,&lt;br /&gt;
        &amp;quot;city&amp;quot;: &amp;quot;New York&amp;quot;,&lt;br /&gt;
        &amp;quot;state&amp;quot;: &amp;quot;NY&amp;quot;,&lt;br /&gt;
        &amp;quot;postalCode&amp;quot;: &amp;quot;10021&amp;quot;&lt;br /&gt;
    },&lt;br /&gt;
    &amp;quot;phoneNumber&amp;quot;: [&lt;br /&gt;
        {&lt;br /&gt;
            &amp;quot;type&amp;quot;: &amp;quot;home&amp;quot;,&lt;br /&gt;
            &amp;quot;number&amp;quot;: &amp;quot;212 555-1234&amp;quot;&lt;br /&gt;
        },&lt;br /&gt;
        {&lt;br /&gt;
            &amp;quot;type&amp;quot;: &amp;quot;fax&amp;quot;,&lt;br /&gt;
            &amp;quot;number&amp;quot;: &amp;quot;646 555-4567&amp;quot;&lt;br /&gt;
        }&lt;br /&gt;
    ]&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
AppStudio has a couple of handy statements for manipulating JSON strings:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  myObject = [[JSON.Parse]](jsonString)     &#039;Convert a JSON string to an object&lt;br /&gt;
&lt;br /&gt;
  jsonString = [[JSON.Stringify]](myObject) &#039;Convert an object into a JSON string&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= JSONP =&lt;br /&gt;
&lt;br /&gt;
[http://en.wikipedia.org/wiki/JSONP JSONP] is a variation on JSON: &amp;quot;JSON with Padding&amp;quot;. It wraps the JSON string in a function call. When your app receives the JSONP string, it executes it.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
functionCall({&lt;br /&gt;
    &amp;quot;firstName&amp;quot;: &amp;quot;John&amp;quot;,&lt;br /&gt;
    &amp;quot;lastName&amp;quot;: &amp;quot;Smith&amp;quot;,&lt;br /&gt;
    &amp;quot;age&amp;quot;: 25,&lt;br /&gt;
    &amp;quot;address&amp;quot;: {&lt;br /&gt;
        &amp;quot;streetAddress&amp;quot;: &amp;quot;21 2nd Street&amp;quot;,&lt;br /&gt;
        &amp;quot;city&amp;quot;: &amp;quot;New York&amp;quot;,&lt;br /&gt;
        &amp;quot;state&amp;quot;: &amp;quot;NY&amp;quot;,&lt;br /&gt;
        &amp;quot;postalCode&amp;quot;: &amp;quot;10021&amp;quot;&lt;br /&gt;
    },&lt;br /&gt;
    &amp;quot;phoneNumber&amp;quot;: [&lt;br /&gt;
        {&lt;br /&gt;
            &amp;quot;type&amp;quot;: &amp;quot;home&amp;quot;,&lt;br /&gt;
            &amp;quot;number&amp;quot;: &amp;quot;212 555-1234&amp;quot;&lt;br /&gt;
        },&lt;br /&gt;
        {&lt;br /&gt;
            &amp;quot;type&amp;quot;: &amp;quot;fax&amp;quot;,&lt;br /&gt;
            &amp;quot;number&amp;quot;: &amp;quot;646 555-4567&amp;quot;&lt;br /&gt;
        }&lt;br /&gt;
    ]&lt;br /&gt;
  }&lt;br /&gt;
)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The above JSON string will call a function in your program called functionCall with the string as a parameter:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Sub functionCall(customer)&lt;br /&gt;
  Print customer.lastName           &#039;Will print &amp;quot;Smith&amp;quot;&lt;br /&gt;
End Sub&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
See the AjaxStockQuote for an example of this.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= XML =&lt;br /&gt;
&lt;br /&gt;
* [http://en.wikipedia.org/wiki/Xml XML] is the X in AJAX.&lt;br /&gt;
* More verbose than JSON - more data to download&lt;br /&gt;
* Works just as well&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp;lt;person&amp;gt;&lt;br /&gt;
  &amp;amp;lt;firstName&amp;gt;John&amp;amp;lt;/firstName&amp;gt;&lt;br /&gt;
  &amp;amp;lt;lastName&amp;gt;Smith&amp;amp;lt;/lastName&amp;gt;&lt;br /&gt;
  &amp;amp;lt;age&amp;gt;25&amp;amp;lt;/age&amp;gt;&lt;br /&gt;
  &amp;amp;lt;address&amp;gt;&lt;br /&gt;
    &amp;amp;lt;streetAddress&amp;gt;21 2nd Street&amp;amp;lt;/streetAddress&amp;gt;&lt;br /&gt;
    &amp;amp;lt;city&amp;gt;New York&amp;amp;lt;/city&amp;gt;&lt;br /&gt;
    &amp;amp;lt;state&amp;gt;NY&amp;amp;lt;/state&amp;gt;&lt;br /&gt;
    &amp;amp;lt;postalCode&amp;gt;10021&amp;amp;lt;/postalCode&amp;gt;&lt;br /&gt;
  &amp;amp;lt;/address&amp;gt;&lt;br /&gt;
  &amp;amp;lt;phoneNumbers&amp;gt;&lt;br /&gt;
    &amp;amp;lt;phoneNumber type=&amp;quot;home&amp;quot;&amp;gt;212 555-1234&amp;amp;lt;/phoneNumber&amp;gt;&lt;br /&gt;
    &amp;amp;lt;phoneNumber type=&amp;quot;fax&amp;quot;&amp;gt;646 555-4567&amp;amp;lt;/phoneNumber&amp;gt;&lt;br /&gt;
  &amp;amp;lt;/phoneNumbers&amp;gt;&lt;br /&gt;
&amp;amp;lt;/person&amp;gt;&lt;br /&gt;
&amp;amp;lt;person firstName=&amp;quot;John&amp;quot; lastName=&amp;quot;Smith&amp;quot; age=&amp;quot;25&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;amp;lt;address streetAddress=&amp;quot;21 2nd Street&amp;quot; city=&amp;quot;New York&amp;quot; state=&amp;quot;NY&amp;quot; postalCode=&amp;quot;10021&amp;quot; /&amp;gt;&lt;br /&gt;
  &amp;amp;lt;phoneNumbers&amp;gt;&lt;br /&gt;
     &amp;amp;lt;phoneNumber type=&amp;quot;home&amp;quot; number=&amp;quot;212 555-1234&amp;quot;/&amp;gt;&lt;br /&gt;
     &amp;amp;lt;phoneNumber type=&amp;quot;fax&amp;quot;  number=&amp;quot;646 555-4567&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;amp;lt;/phoneNumbers&amp;gt;&lt;br /&gt;
&amp;amp;lt;/person&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Need to include the xml2json library to convert XML into an object&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  data=$.xml2json(req.responseText)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Web_Services_Fundamentals&amp;diff=4846</id>
		<title>Web Services Fundamentals</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Web_Services_Fundamentals&amp;diff=4846"/>
		<updated>2014-01-07T06:24:01Z</updated>

		<summary type="html">&lt;p&gt;Admin: 26 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Introduction =&lt;br /&gt;
&lt;br /&gt;
* Web Services are resources which are accessed over the web&lt;br /&gt;
&lt;br /&gt;
* AppStudio Apps can access Web Services&lt;br /&gt;
&lt;br /&gt;
* The information that is pulled from the web can make interesting apps&lt;br /&gt;
&lt;br /&gt;
* Data can be pulled from your own server or someone else&#039;s.&lt;br /&gt;
&lt;br /&gt;
* Mashups are apps which pull information from more than one source&lt;br /&gt;
&lt;br /&gt;
= Same Origin Policy and CORS =&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;[http://en.wikipedia.org/wiki/Same-origin_policy Same Origin Policy (SOP)]&#039;&#039;&#039;: The policy permits scripts running on pages originating from the same site – a combination of scheme, hostname, and port number – to access each other&#039;s DOM with no specific restrictions, but prevents access to DOM on different sites.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;[http://en.wikipedia.org/wiki/Cross-origin_resource_sharing Cross Origin Resource Sharing (CORS)]&#039;&#039;&#039;: is a mechanism that allows scripts on a web page to make AJAX requests to another domain, not the domain the script originated from. Such &amp;quot;cross-domain&amp;quot; requests would otherwise be forbidden by web browsers, per the Same Origin Policy. &lt;br /&gt;
&lt;br /&gt;
* Suppose we create an AppStudio app.&lt;br /&gt;
&lt;br /&gt;
* It gets saved on our server (nsbapp.com), together with all the files it needs to run.&lt;br /&gt;
&lt;br /&gt;
* When someone runs it, they enter http://www.nsbapp.com/HelloWorld into their browser.&lt;br /&gt;
&lt;br /&gt;
* The app is then loaded from the website and stored on the device.&lt;br /&gt;
&lt;br /&gt;
* Since the app is loaded from nsbapp.com, SOP allows it to access resources on nsbapp.com: HTML, JavaScript, CSS files, images, etc.&lt;br /&gt;
&lt;br /&gt;
* However, it would not be allowed full use of resources on another site, such as nsbasic.com.&lt;br /&gt;
&lt;br /&gt;
* CORS is a way of allowing apps running from another server to access specific resources on the server.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= AJAX =&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;[http://en.wikipedia.org/wiki/Ajax_(programming) AJAX]&#039;&#039;&#039;: stands for Asynchronous JavaScript and XML. It is a group of interrelated web development techniques used on the client-side to create asynchronous web applications.  &lt;br /&gt;
&lt;br /&gt;
* It has evolved since it was originally named.&lt;br /&gt;
&lt;br /&gt;
* Now, it does not necessary involve asynchronous, JavaScript or XML!&lt;br /&gt;
&lt;br /&gt;
* The AppStudio [[Ajax]] function allows an app to request information from a web service.&lt;br /&gt;
&lt;br /&gt;
* It is based on the [http://www.w3schools.com/ajax/ajax_xmlhttprequest_send.asp XMLHttpPost] function in JavaScript.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
=== A Simple Exchange of Data with the server ===&lt;br /&gt;
&lt;br /&gt;
Let&#039;s look at some code. We will have our AppStudio app send the server a string, which the server will return reversed. Here is what the app looks like:&lt;br /&gt;
&lt;br /&gt;
[[File:Ajax1.png]]&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The only code in this app is the &amp;quot;Reverse&amp;quot; button. The [[Ajax]] function sends the contents of the top TextArea to a [http://en.wikipedia.org/wiki/PHP PHP] script that is running on the server. If it returns successfully, we display what came back. Otherwise, we show the error:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Dim req&lt;br /&gt;
Function btnAjax_onclick()&lt;br /&gt;
  req=Ajax(&amp;quot;ajax.php/?myText=&amp;quot; &amp;amp; txtSend.value)&lt;br /&gt;
  If req.status=200 Then &#039;success&lt;br /&gt;
    txtResponse.value=req.responseText&lt;br /&gt;
  Else &#039;failure&lt;br /&gt;
    txtResponse.value=&amp;quot;Error: &amp;quot; &amp;amp; req.err.message&lt;br /&gt;
  End If&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The PHP script is even easier. It gets the input that is named myText, reverses it, and uses the echo statement to send it back.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
 // Get the data from the client. &lt;br /&gt;
 $myText = $_GET[&#039;myText&#039;];&lt;br /&gt;
 // Send back the text, reversed&lt;br /&gt;
 echo &amp;quot;Data received from Device (reversed): &amp;quot; . strrev($myText); &lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Here is the result:&lt;br /&gt;
&lt;br /&gt;
[[File:Ajax2.png]]&lt;br /&gt;
&lt;br /&gt;
* The php script needs to be on the same folder on the server as the AppStudio app.&lt;br /&gt;
* It can be uploaded with the app.&lt;br /&gt;
* This is equivalent to entering the following URL into a browser:&lt;br /&gt;
https://www.nsbasic.com/i/Ajax/ajax.php/?myText=%22NSB/AppStudio%20makes%20Ajax%20easy!%22&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Cross Origin Attacks! ===&lt;br /&gt;
&lt;br /&gt;
What happens if we run this same example in our local browser, by just choosing Start in Desktop Browser under the Run menu?&lt;br /&gt;
&lt;br /&gt;
[[File:Ajax3.png]]&lt;br /&gt;
&lt;br /&gt;
* We get a cross origin request error.&lt;br /&gt;
* The traceback shows it is caused by our Ajax call.&lt;br /&gt;
* When we run in a local browser, the origin of the app is our local machine.&lt;br /&gt;
* So the browser protests when we try to run a PHP script on another machine.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
=== Using POST to Send more Data to the Server and save it ===&lt;br /&gt;
&lt;br /&gt;
Let&#039;s extend what we are doing a bit and talk about using the POST method.&lt;br /&gt;
&lt;br /&gt;
We discussed the simplest [[Ajax]] call, which sends data to the server by adding it to the end of the URL, a method called, rather misleadingly, GET. But what if we want to send more data? GET has a limit, some say, of around 2000 characters. For more than that, we&#039;ll use the also badly named POST method. POST has an upload limit on most servers of 8 megabytes. If you need more, server settings can be adjusted.&lt;br /&gt;
&lt;br /&gt;
Let&#039;s look at some code. You&#039;ll see it looks very much like our last post:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function btnAjax_onclick()&lt;br /&gt;
  req=Ajax(&amp;quot;ajaxPost.php&amp;quot;,&amp;quot;POST&amp;quot;,txtSend.value)&lt;br /&gt;
  If req.status=200 Then &#039;success&lt;br /&gt;
    htmResponse.innerHTML=req.responseText&lt;br /&gt;
  Else &#039;failure&lt;br /&gt;
    htmResponse.innerHTML=&amp;quot;Error: &amp;quot; &amp;amp; req.err&lt;br /&gt;
  End If&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The difference is a couple of extra parameters. We add &amp;quot;POST&amp;quot; and the data we want to send as a separate parameter. Before we talk about what is going to happen at the server end, let&#039;s see what the app looks like:&lt;br /&gt;
&lt;br /&gt;
[[File:Ajaxpost.png]]&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
* Here is the PHP code on the server which we are calling:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
 // uncomment the next line to see runtime error messages from this script&lt;br /&gt;
 // ini_set(&#039;display_errors&#039;,&#039;1&#039;);&lt;br /&gt;
 &lt;br /&gt;
 // Get the data from the client.&lt;br /&gt;
 $myText = file_get_contents(&#039;php://input&#039;);&lt;br /&gt;
 // Send back the text, reversed&lt;br /&gt;
 echo &amp;quot;Data received from Device (reversed):&amp;lt;br&amp;gt;&amp;quot; . strrev($myText); &lt;br /&gt;
 &lt;br /&gt;
 //write the data out to a file on the server&lt;br /&gt;
 //make sure permissions are all OK!&lt;br /&gt;
 $myFile = &amp;quot;AjaxPost/ajaxPost.txt&amp;quot;;&lt;br /&gt;
 echo &amp;quot;&amp;lt;p&amp;gt;Writing data to &amp;quot; . getcwd() . $myFile;&lt;br /&gt;
 $f = fopen($myFile, &#039;w&#039;) or die(&amp;quot;can&#039;t open file&amp;quot;);&lt;br /&gt;
 fwrite($f, $myText);&lt;br /&gt;
 fclose($f);&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The file_get_contents(&#039;php://input&#039;) call gets the data, exactly as it was sent. We&#039;ll do two things with it: echo it back reversed and we will write it to a file on the server. The first part is easy: anything in an echo statement is sent back to our app:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
echo &amp;quot;Data received from Device (reversed):&amp;quot; . strrev($myText); &lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The second part involves a bit more PHP, but is straightforward. It writes the data which was received to a file.&lt;br /&gt;
&amp;lt;pre&amp;gt; &lt;br /&gt;
$myFile = &amp;quot;AjaxPost/ajaxPost.txt&amp;quot;;&lt;br /&gt;
 echo &amp;quot;&amp;lt;p&amp;gt;Writing data to &amp;quot; . getcwd() . $myFile;&lt;br /&gt;
 $f = fopen($myFile, &#039;w&#039;) or die(&amp;quot;can&#039;t open file&amp;quot;);&lt;br /&gt;
 fwrite($f, $myText);&lt;br /&gt;
 fclose($f);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
What would you use this feature for?&lt;br /&gt;
&lt;br /&gt;
* Upload a [http://en.wikipedia.org/wiki/JSON JSON] copy of your database.&lt;br /&gt;
* Upload some pictures in [http://en.wikipedia.org/wiki/Base64 Base64] format.&lt;br /&gt;
* Create a .htm file which can be accessed as a web page.&lt;br /&gt;
* Lots more ideas!&lt;br /&gt;
&lt;br /&gt;
A tip on debugging PHP scripts Since PHP scripts run on the server and not on your screen, you don&#039;t get to see the error messages. This can make debugging difficult. If you put this statement at the top of your PHP script, the error messages will be echoed to your app:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ini_set(&#039;display_errors&#039;,&#039;1&#039;);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The error messages come back as HTML formatted text. The best way to look at them is to assign them to the innerText property of an HTMLview control.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Getting Data from Another Site ===&lt;br /&gt;
&lt;br /&gt;
One of the basic security features of the modern web is the [http://en.wikipedia.org/wiki/Same_origin_policy Same Origin Policy]. It states that a web app cannot pull up just any data from another site. This becomes a problem if you need data on someone else&#039;s site.&lt;br /&gt;
&lt;br /&gt;
Fortunately, they left an easy workaround. While a web app isn&#039;t allowed to access the files on another site, a PHP script is. We&#039;ll get our PHP script to do the dirty work for us and return the results to our app. The technique we will use is often called [http://en.wikipedia.org/wiki/Web_scraping scraping].&lt;br /&gt;
&lt;br /&gt;
Time to look at some code again. Here&#039;s the AppStudio part that calls the PHP script. It looks very much like the code in A Simple Exchange of Data with the server above. The main difference is that we&#039;re calling a different PHP script.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function btnGetFile_onclick()&lt;br /&gt;
  req=Ajax(&amp;quot;ajaxGetURL.php/?urlToGet=&amp;quot; &amp;amp; txtURL.value)&lt;br /&gt;
  If req.status=200 Then &#039;success&lt;br /&gt;
    htmResponse.innerHTML=req.responseText&lt;br /&gt;
  Else &#039;failure&lt;br /&gt;
    htmResponse.innerHTML=req.err&lt;br /&gt;
  End If&lt;br /&gt;
  htmResponse.refresh()&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Before we talk about what is going to happen at the server end, let&#039;s see what the app looks like:&lt;br /&gt;
&lt;br /&gt;
[[File:Ajaxgeturl.png]]&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And here is what the PHP script looks like:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
$ch = curl_init($_GET[&#039;urlToGet&#039;]);&lt;br /&gt;
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);&lt;br /&gt;
$data = curl_exec($ch);&lt;br /&gt;
curl_close($ch);&lt;br /&gt;
echo $data&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Let&#039;s take apart this one line:&lt;br /&gt;
&lt;br /&gt;
* $_GET(&#039;urlToGet&#039;) gets the parameter string that was attached to the URL in our AppStudio code.&lt;br /&gt;
* _file_get_contents get the contents of the file, in this case, the URL that was passed.&lt;br /&gt;
* echo sends the result back to our AppStudio program.&lt;br /&gt;
&lt;br /&gt;
Pretty simple, isn&#039;t it?&lt;br /&gt;
&lt;br /&gt;
(In this example, we&#039;re grabbing the robots.txt file from Microsoft&#039;s site, just to show we can get files from anywhere. Nearly all sites have a robots.txt file: it is used to guide search engines.)&lt;br /&gt;
&lt;br /&gt;
There is a simpler way to do this, but it can run into security problems.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
echo file_get_contents($_GET[&#039;urlToGet&#039;]); &lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
=== How fast is it? ===&lt;br /&gt;
&lt;br /&gt;
If your app is going to communicate with your server while it is running, you&#039;ve probably wondered how much your app will slow down when it has to wait for the server.&lt;br /&gt;
&lt;br /&gt;
In this blog post, we&#039;re going to make a program to test this. We&#039;ll construct a little program which sends data to the server as many times as it can. The server will record the information in a log file. Here is what our app will do:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  Do Until SysInfo(10) &amp;gt; limit&lt;br /&gt;
    req=Ajax(&amp;quot;ajaxLog.php/?myText=&amp;quot; + Now)&lt;br /&gt;
    counter=counter+1&lt;br /&gt;
  Loop&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[SysInfo]](10) is the current time in milliseconds. Limit is the time we want run to. You can run this test for up to about 5 seconds: after that, the system will think you are in a endless loop and shut you down.&lt;br /&gt;
&lt;br /&gt;
On the server side, we need a PHP script to get the messages and write them out to disk. Here&#039;s the code:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
  // read and append to file&lt;br /&gt;
  $myFile = &amp;quot;AjaxLog/log.txt&amp;quot;;&lt;br /&gt;
  $f = fopen($myFile, &#039;a&#039;) or die(&amp;quot;can&#039;t open file&amp;quot;);&lt;br /&gt;
  fwrite($f, $_GET[&#039;myText&#039;] . Chr(13) . Chr(10));&lt;br /&gt;
  fclose($f);&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Now, let&#039;s run it on a few different devices and see how many accesses we can do per second:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| Desktop (Ethernet) || 2745.0&lt;br /&gt;
|-&lt;br /&gt;
| iPhone 5 (WiFi) || 16.75&lt;br /&gt;
|-&lt;br /&gt;
| iPhone 5 (LTE) || 13.0&lt;br /&gt;
|-&lt;br /&gt;
| iPhone 4 (WiFi) || 10.5&lt;br /&gt;
|-&lt;br /&gt;
| iPhone (3G) || 2.5&lt;br /&gt;
|-&lt;br /&gt;
| Nexus S (WiFi) || 5.0&lt;br /&gt;
|-&lt;br /&gt;
| Kindle Fire (WiFi) || 9.0&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
It&#039;s obvious that the speed that really depends on what kind of connection you have to the web. A hard wire to your router gets the best time. WiFi is much slower, and 3G is slower again. No real surprise here.&lt;br /&gt;
&lt;br /&gt;
The speeds shown here probably are not what you will see if you run the same test. There are a number of factors that will affect the speed:&lt;br /&gt;
&lt;br /&gt;
* Type of data connection&lt;br /&gt;
* Load on the network&lt;br /&gt;
* Number of hops the data has to make to get to the server&lt;br /&gt;
* Load on the server&lt;br /&gt;
&lt;br /&gt;
(You can try this sample yourself - it is called AjaxLog in the Samples folder.)&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Lab_Session:_Fix_a_program_with_syntax_errors_and_make_some_enhancements&amp;diff=4819</id>
		<title>Lab Session: Fix a program with syntax errors and make some enhancements</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Lab_Session:_Fix_a_program_with_syntax_errors_and_make_some_enhancements&amp;diff=4819"/>
		<updated>2014-01-07T06:23:55Z</updated>

		<summary type="html">&lt;p&gt;Admin: 10 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In this lab you will fix some problems in the code for your app and add some functionality.&lt;br /&gt;
&lt;br /&gt;
== Student Outline ==&lt;br /&gt;
&lt;br /&gt;
# Open LabFix.nsx&lt;br /&gt;
# Run the program in the browser.  Several errors appear in the [[Chrome Debugger|debugger]].  Resolve these errors.&lt;br /&gt;
# Link the forms together using the ChangeForm properties:&lt;br /&gt;
#* On &#039;&#039;frmMain&#039;&#039;:&lt;br /&gt;
#** Link &#039;&#039;hdrMain&#039;s&#039;&#039; buttons to &#039;&#039;frmAbout&#039;&#039; and &#039;&#039;frmSaves&#039;&#039;.&lt;br /&gt;
#** Link &#039;&#039;btnCompass&#039;&#039; to &#039;&#039;frmCompass&#039;&#039;.&lt;br /&gt;
#** Link &#039;&#039;btnPhoto&#039;&#039; to &#039;&#039;frmPhoto&#039;&#039;.&lt;br /&gt;
#* On &#039;&#039;frmAbout&#039;&#039;, link &#039;&#039;hdrAbout&#039;s&#039;&#039; button to &#039;&#039;frmMain&#039;&#039;.&lt;br /&gt;
#* On &#039;&#039;frmSaves&#039;&#039;, link &#039;&#039;hdrSaves&#039;&#039;&#039; button to &#039;&#039;frmMain&#039;&#039;.&lt;br /&gt;
#* On &#039;&#039;frmSavedData&#039;&#039;, link &#039;&#039;hdrSavedData&#039;s&#039;&#039; button to &#039;&#039;frmSaves&#039;&#039;.&lt;br /&gt;
#* On &#039;&#039;frmCompass&#039;&#039;, link &#039;&#039;hdrCompass&#039;&#039;&#039; button to &#039;&#039;frmMain&#039;&#039;.&lt;br /&gt;
#* On &#039;&#039;frmPhoto&#039;&#039;, link &#039;&#039;hdrPhoto&#039;s&#039;&#039; button to &#039;&#039;frmMain&#039;&#039;.&lt;br /&gt;
# Add a click event for &#039;&#039;frmMain&#039;s&#039;&#039; &#039;&#039;btnSave&#039;&#039; and have it display a &#039;&#039;[[MsgBox]]&#039;&#039; when clicked.&lt;br /&gt;
# Add a few random entries to &#039;&#039;lstSaves&#039;&#039; in &#039;&#039;Sub Main&#039;&#039; and verify that &#039;&#039;lstSaves_onclick&#039;&#039; fires.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Fundamentals_of_BASIC&amp;diff=4799</id>
		<title>Fundamentals of BASIC</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Fundamentals_of_BASIC&amp;diff=4799"/>
		<updated>2014-01-07T06:23:52Z</updated>

		<summary type="html">&lt;p&gt;Admin: 21 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Variables =&lt;br /&gt;
== Naming ==&lt;br /&gt;
The following list shows some variable names that are allowed by AppStudio: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
text&lt;br /&gt;
LLAMAS&lt;br /&gt;
Jupiter&lt;br /&gt;
W1Spec&lt;br /&gt;
SouthPark&lt;br /&gt;
btnSubmit&lt;br /&gt;
txtCustomer&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And some that are not allowed: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
1table &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; &#039;starts with a number &lt;br /&gt;
X&amp;amp;Ycords &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; &#039;uses special character &amp;amp; &lt;br /&gt;
first counter &amp;amp;nbsp; &#039;has a space &lt;br /&gt;
%correct &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; &#039;does not start with a letter&lt;br /&gt;
print &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; &#039;Keyword&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Variable names are case sensitive. &lt;br /&gt;
* If you DIM a variable name, AppStudio will correct the case on entry.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
== Variables ==&lt;br /&gt;
&lt;br /&gt;
* All variables are of type Variant.&lt;br /&gt;
* No explicit types&lt;br /&gt;
* Variable get their types from the value that is assigned.&lt;br /&gt;
* Variables Dimmed outside of an Function or Sub are global.&lt;br /&gt;
* Variables Dimmed inside a Function or Sub are local.&lt;br /&gt;
* Variables which are not declared are global.&lt;br /&gt;
&lt;br /&gt;
=== Numeric ===&lt;br /&gt;
* Floating point: 5e-324 (negative) to 1.7976931348623157e+308 (positive)&lt;br /&gt;
* Integers: reliable to 15 digits.&lt;br /&gt;
* Hex: 0x500 = 1280&lt;br /&gt;
* Octal: O500 = 320&lt;br /&gt;
&lt;br /&gt;
=== Booleans ===&lt;br /&gt;
&lt;br /&gt;
* True or False.&lt;br /&gt;
&lt;br /&gt;
=== Colors ===&lt;br /&gt;
&lt;br /&gt;
* From “#000000” to “#FFFFFF”  (black to white)&lt;br /&gt;
* color = (red*65536) + (green * 256) + blue&lt;br /&gt;
&lt;br /&gt;
=== Strings ===&lt;br /&gt;
&lt;br /&gt;
* Maximum length depends on memory, up to 2 billion characters&lt;br /&gt;
&lt;br /&gt;
=== Arrays ===&lt;br /&gt;
&lt;br /&gt;
* Dim A(9) declares an array with 10 elements&lt;br /&gt;
* Dim B(8,8) creates a two dimensional array&lt;br /&gt;
* Elements can be referred to as A(3), B(2,3), etc.&lt;br /&gt;
* Dim statement has to be in each Code Module&lt;br /&gt;
* The following notation is also OK: a[3], B[2][3}&lt;br /&gt;
* Array elements do not exist until they are assigned.&lt;br /&gt;
* To create empty array, do this:  a=[]&lt;br /&gt;
* Use the Ubound() function to get the number of items in an array.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
=== Collections ===&lt;br /&gt;
&lt;br /&gt;
* Like an Array, but uses string values to index&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Dim item1, myCollection(10)&lt;br /&gt;
item1=&amp;quot;Knuth&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&#039;Create our collection&lt;br /&gt;
myCollection[item1] = &amp;quot;firstKey&amp;quot;&lt;br /&gt;
Print myCollection[item1]  &#039;displays &amp;quot;firstkey&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Objects ===&lt;br /&gt;
* An object is a collection of named values, called properties&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Customer={Name: Lovelace, Age: 195, kids:{Byron: 1, Annabella: 2, Ralph: 3}}&lt;br /&gt;
Print Customer.name  &#039;displays &amp;quot;LoveLace&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Classes ===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&#039;Define a class like this&lt;br /&gt;
Function Person(name, gender)&lt;br /&gt;
   &#039;Add object properties like this&lt;br /&gt;
   this.name = name&lt;br /&gt;
   this.gender = gender&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
&#039;Add methods like this.  All Person objects will be able to invoke this&lt;br /&gt;
Function speakName()&lt;br /&gt;
  Print &amp;quot;Howdy, my name is &amp;quot; &amp;amp; this.name&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Person.prototype.speak = Eval(&amp;quot;speakName&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
&#039;Instantiate new objects with &#039;new&#039;&lt;br /&gt;
bob = new Person(&amp;quot;Bob&amp;quot;, &amp;quot;M&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
&#039;Invoke methods like this&lt;br /&gt;
bob.speak() &#039;Prints &amp;quot;Howdy, my name is Bob&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= Control structures =&lt;br /&gt;
&#039;&#039;&#039;If...Then&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
If a=b Then c=1&lt;br /&gt;
&lt;br /&gt;
If a=b Then&lt;br /&gt;
  c=1&lt;br /&gt;
End If&lt;br /&gt;
&lt;br /&gt;
If a=b Then&lt;br /&gt;
  C=1&lt;br /&gt;
Else&lt;br /&gt;
  C=2&lt;br /&gt;
End If&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Loops&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
For i=1 to 10&lt;br /&gt;
  Print i&lt;br /&gt;
Next&lt;br /&gt;
&lt;br /&gt;
i=0&lt;br /&gt;
Do While i&amp;lt;10&lt;br /&gt;
  Print i&lt;br /&gt;
  i=i+1&lt;br /&gt;
Loop&lt;br /&gt;
&lt;br /&gt;
i=0&lt;br /&gt;
Do&lt;br /&gt;
  Print i&lt;br /&gt;
  i=i+1&lt;br /&gt;
Loop Until i=10&lt;br /&gt;
&lt;br /&gt;
Rem While...Wend Example&lt;br /&gt;
&#039;While...Wend repeats a group of statements&lt;br /&gt;
&lt;br /&gt;
Dim Counter&lt;br /&gt;
Counter = 1&lt;br /&gt;
While Counter &amp;lt; 5&lt;br /&gt;
  Print &amp;quot;Counter = &amp;quot; &amp;amp; Counter&lt;br /&gt;
  Counter = Counter + 1&lt;br /&gt;
Wend&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;With&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Rem With sample&lt;br /&gt;
&#039;With statement allows accessing properties on a specified object&lt;br /&gt;
&lt;br /&gt;
Dim theURL, theTitle&lt;br /&gt;
With document&lt;br /&gt;
  theURL = .URL&lt;br /&gt;
  .title = &amp;quot;New Title&amp;quot;&lt;br /&gt;
  theTitle = .title&lt;br /&gt;
  Print .URL&lt;br /&gt;
  Print .title&lt;br /&gt;
End With&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Select Case&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Rem Select Case Example&lt;br /&gt;
&#039;Select Case performs conditional execution&lt;br /&gt;
CheckHat(&amp;quot;Blue&amp;quot;)&lt;br /&gt;
CheckHat(&amp;quot;Orange&amp;quot;)&lt;br /&gt;
Sub CheckHat(Hat)&lt;br /&gt;
  Select Case Hat&lt;br /&gt;
  Case &amp;quot;Blue&amp;quot;&lt;br /&gt;
    Print &amp;quot;Kyle&#039;s hat&amp;quot;&lt;br /&gt;
  Case &amp;quot;Green&amp;quot;&lt;br /&gt;
    Print &amp;quot;Stan&#039;s hat&amp;quot;&lt;br /&gt;
  Case &amp;quot;Cyan&amp;quot;&lt;br /&gt;
    Print &amp;quot;Eric&#039;s hat&amp;quot;&lt;br /&gt;
  Case &amp;quot;Orange&amp;quot;, &amp;quot;Hood&amp;quot;&lt;br /&gt;
    Print &amp;quot;Kenny&#039;s hat&amp;quot;&lt;br /&gt;
  Case &amp;quot;White&amp;quot;&lt;br /&gt;
    Print &amp;quot;Chef&#039;s hat&amp;quot;&lt;br /&gt;
  Case &amp;quot;Striped&amp;quot;&lt;br /&gt;
    Print &amp;quot;Mr. Hat&amp;quot;&lt;br /&gt;
  Case &amp;quot;Christmas&amp;quot;, &amp;quot;Santa&amp;quot;&lt;br /&gt;
    Print &amp;quot;Mr. Hankey&#039;s hat&amp;quot;&lt;br /&gt;
  Case Else&lt;br /&gt;
    Print &amp;quot;Unknown Hat&amp;quot;&lt;br /&gt;
  End Select&lt;br /&gt;
End Sub&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Error trapping&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Rem Try Example&lt;br /&gt;
&#039;Try catches run time errors&lt;br /&gt;
b=1&lt;br /&gt;
c=0&lt;br /&gt;
Try&lt;br /&gt;
  If c=0 Then throw &amp;quot;Division by zero!&amp;quot;&lt;br /&gt;
  a=b/c&lt;br /&gt;
Catch err&lt;br /&gt;
  Print err&lt;br /&gt;
Finally&lt;br /&gt;
  Print &amp;quot;done&amp;quot;&lt;br /&gt;
End Try&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Functions and Subroutines&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Sub mySubroutine(a,b)&lt;br /&gt;
  Print a + b&lt;br /&gt;
End Sub&lt;br /&gt;
&lt;br /&gt;
Function myFunction(a,b)&lt;br /&gt;
  myFunction = a + b&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= Importing VB code =&lt;br /&gt;
&lt;br /&gt;
* Code using the above statements can usually be pasted in&lt;br /&gt;
* Remember to remove the AS clauses&lt;br /&gt;
* Simple controls (Buttons, TextBoxes, etc) have similar properties&lt;br /&gt;
* Advanced controls and properties may be different&lt;br /&gt;
&lt;br /&gt;
= A few interesting statements =&lt;br /&gt;
* [[Print]] &amp;quot;Some data&amp;quot;&lt;br /&gt;
* [[console.log]](&amp;quot;a = &amp;quot; &amp;amp; a)&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Lab_Session:_Create_an_app_with_some_Controls&amp;diff=4777</id>
		<title>Lab Session: Create an app with some Controls</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Lab_Session:_Create_an_app_with_some_Controls&amp;diff=4777"/>
		<updated>2014-01-07T06:23:49Z</updated>

		<summary type="html">&lt;p&gt;Admin: 17 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In this lab you will create the controls for your app.&lt;br /&gt;
&lt;br /&gt;
== Student Outline ==&lt;br /&gt;
&lt;br /&gt;
# Start a new Project.&lt;br /&gt;
# Create the following 6 forms as shown in the images:&lt;br /&gt;
&lt;br /&gt;
[[File:Screenshot_2013-12-11_04.45.16.png|300px]] &lt;br /&gt;
[[File:Screenshot_2013-12-11_04.45.37.png|300px]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
[[File:Screenshot_2013-12-11_04.45.47.png|300px]] &lt;br /&gt;
[[File:Screenshot_2013-12-11_04.46.23.png|300px]] &lt;br /&gt;
[[File:Screenshot_2013-12-11_15.24.57.png|300px]] &lt;br /&gt;
[[File:Screenshot_2013-12-13_13.04.24.png|300px]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Some_Controls_in_depth&amp;diff=4759</id>
		<title>Some Controls in depth</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Some_Controls_in_depth&amp;diff=4759"/>
		<updated>2014-01-07T06:23:47Z</updated>

		<summary type="html">&lt;p&gt;Admin: 82 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Controls make the visual elements of your app.&lt;br /&gt;
&lt;br /&gt;
* An app will have one or more forms. Each form will have a collection of controls on it, customized by you with different sizes and appearances.&lt;br /&gt;
&lt;br /&gt;
* In this section, we will see how to add controls and forms to an app.&lt;br /&gt;
&lt;br /&gt;
* Add controls to your app by dragging and dropping them into place. Then, resize and set the properties. &lt;br /&gt;
&lt;br /&gt;
* It is good practice to name your controls consistently. &lt;br /&gt;
&lt;br /&gt;
* A common way is to have three letters for the type, followed by a name for the control.&lt;br /&gt;
&lt;br /&gt;
* For example, lblName, txtCustomer, butSave, lstSaves&lt;br /&gt;
&lt;br /&gt;
Let&#039;s look at some controls.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= [[Label]] =&lt;br /&gt;
&lt;br /&gt;
Controls are defined by their properties. The [[Label]] control is a simple control. Most of the properties for a control are set to default values when the control is created, so it is usable right away. Let&#039;s look at the options for customizing it.&lt;br /&gt;
&lt;br /&gt;
[[File:Labelcontrol.png|right]]&lt;br /&gt;
&lt;br /&gt;
{| class = &amp;quot;wikitable&amp;quot; &lt;br /&gt;
|-&lt;br /&gt;
| align|| left, center, right &lt;br /&gt;
|-&lt;br /&gt;
| alignVertical|| top, center, bottom (no % or multiline)&lt;br /&gt;
|-&lt;br /&gt;
| backgroundColor|| colors can be a name, #RRGGBB, rgb(R,G,B)  or transparent&lt;br /&gt;
|-&lt;br /&gt;
| borderColor||&lt;br /&gt;
|-&lt;br /&gt;
| borderStyle|| solid, dotted, dashed, etc.&lt;br /&gt;
|-&lt;br /&gt;
| borderWidth|| pixels&lt;br /&gt;
|-&lt;br /&gt;
| bottom|| pixels, percent, auto&lt;br /&gt;
|-&lt;br /&gt;
| class|| grayTitle default. Can be custom css.&lt;br /&gt;
|-&lt;br /&gt;
| color|| Of the text&lt;br /&gt;
|-&lt;br /&gt;
| fontFamily|| helvetica is default&lt;br /&gt;
|-&lt;br /&gt;
| fontSize|| in pixels. 16 is the default.&lt;br /&gt;
|-&lt;br /&gt;
| fontStyle|| normal, italic or oblique&lt;br /&gt;
|-&lt;br /&gt;
| fontWeight|| normal, bold or a number&lt;br /&gt;
|-&lt;br /&gt;
| height||&lt;br /&gt;
|-&lt;br /&gt;
| hidden|| true or false&lt;br /&gt;
|-&lt;br /&gt;
| id|| The name of the control.&lt;br /&gt;
|-&lt;br /&gt;
| left||&lt;br /&gt;
|-&lt;br /&gt;
| onclick, etc|| names of functions to be called when &lt;br /&gt;
these events happen.&lt;br /&gt;
|-&lt;br /&gt;
| right||&lt;br /&gt;
|-&lt;br /&gt;
| style|| css style&lt;br /&gt;
|-&lt;br /&gt;
| textContent|| The content of the label. HTML is OK!&lt;br /&gt;
|-&lt;br /&gt;
| top||&lt;br /&gt;
|-&lt;br /&gt;
| width||&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= [[TextBox]] =&lt;br /&gt;
[[file:TextBox.jpg]]&lt;br /&gt;
&lt;br /&gt;
The [[TextBox]] has many of the same properties as the label - plus some additional ones:&lt;br /&gt;
&lt;br /&gt;
{| class = &amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| autocapitalize || Automatically capitalize first letter? May not be available on all platforms.&lt;br /&gt;
|-&lt;br /&gt;
| autocomplete || Automatically complete words? May not be available on all platforms.&lt;br /&gt;
|-&lt;br /&gt;
| autocorrect || Spellcheck as entering? May not be available on all platforms.&lt;br /&gt;
|-&lt;br /&gt;
| inputType || Specifies what kind of data will be input. Choices are:&lt;br /&gt;
* color&lt;br /&gt;
* date&lt;br /&gt;
* datetime&lt;br /&gt;
* email&lt;br /&gt;
* file (iOS 6+ and Android 4+ only)&lt;br /&gt;
* hidden&lt;br /&gt;
* month&lt;br /&gt;
* number&lt;br /&gt;
* password&lt;br /&gt;
* range&lt;br /&gt;
* search&lt;br /&gt;
* tel&lt;br /&gt;
* text (default)&lt;br /&gt;
* time&lt;br /&gt;
* url&lt;br /&gt;
|-&lt;br /&gt;
| placeholder || Text to be displayed in the field just as a comment – does not change the value.&lt;br /&gt;
|-&lt;br /&gt;
| readonly || If set to “True”, the control cannot be edited. At runtime, use readOnly.&lt;br /&gt;
|-&lt;br /&gt;
| size || Maximum characters allowed.&lt;br /&gt;
|- &lt;br /&gt;
| text || The contents of the TextBox. Same as value.&lt;br /&gt;
|-&lt;br /&gt;
| value || The contents of the TextBox. This is always returned as a string. Convert it to a number before doing arithmetic on it.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= [[Button]] =&lt;br /&gt;
[[file:Button.jpg]]&lt;br /&gt;
&lt;br /&gt;
:&#039;&#039;&#039;iWebKit &amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp;&amp;amp;nbsp; jQuery Mobile&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
There are many different appearances for [[Button|buttons]].&lt;br /&gt;
&lt;br /&gt;
* Buttons can have an optional icon.&lt;br /&gt;
* Buttons can have optional text.&lt;br /&gt;
* Buttons can be grouped&lt;br /&gt;
* Different frameworks will have different appearances.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| ChangeForm || The name of the form to go to if this button is clicked.&lt;br /&gt;
|-&lt;br /&gt;
| corners || round or square.&lt;br /&gt;
|-&lt;br /&gt;
| groupBegin || If you have a group of buttons, set this to Yes on the first one. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| groupEnd || If you have a group of buttons, set this to Yes on the last one. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| icon || Set to false for no icon. You have a choice of 18 standard icons otherwise. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| iconPos || Position of the icon. Can be none, left, right, top, bottom or notext. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| image || Path to image to show instead of title on the button. jQuery Mobile only.&lt;br /&gt;
|-&lt;br /&gt;
| mini || true/false. For jQuery Mobile, should the text be normal size or mini size?&lt;br /&gt;
|-&lt;br /&gt;
| onclick()|| The function to be called when this button is clicked.&lt;br /&gt;
|-&lt;br /&gt;
| value || The title of the button.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Here is some sample code for when a button is clicked:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Rem Button Example&lt;br /&gt;
&lt;br /&gt;
Function Button1_onclick()&lt;br /&gt;
  Msgbox &amp;quot;Hello World&amp;quot;&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= [[HeaderBar]] =&lt;br /&gt;
[[file:HeaderBar.jpg]]&lt;br /&gt;
&lt;br /&gt;
The [[HeaderBar]] puts a title at the top of the form.&lt;br /&gt;
&lt;br /&gt;
* The left and right buttons are optional. They can be with or without text or icons.&lt;br /&gt;
&lt;br /&gt;
* When a button on it is clicked, the name of that button is passed to the onclick function.&lt;br /&gt;
&lt;br /&gt;
* You can also use the buttons to go to a new form.&lt;br /&gt;
&lt;br /&gt;
{| class = &amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| leftChangeForm || The name of the form to go to if the left button is clicked.&lt;br /&gt;
|-&lt;br /&gt;
| leftButtonIcon || Names of icon for left button. Use false for no icon, or alert, arrow-d, arrow-l ,arrow-r, arrow-u ,back, check, delete, forward, gear, grid, home, info, minus, plus, refresh, search, star. Design time only.&lt;br /&gt;
|-&lt;br /&gt;
| leftButtonName || The name of the left icon. Design time only.&lt;br /&gt;
|-&lt;br /&gt;
| rightChangeForm || The name of the form to go to if the right button is clicked.&lt;br /&gt;
|-&lt;br /&gt;
| rightButtonIcon || Names of icon for right button. Use false for no icon, or alert, arrow-d, arrow-l ,arrow-r, arrow-u ,back, check, delete, forward, gear, grid, home, info, minus, plus, refresh, search, star. Design time only.&lt;br /&gt;
|-&lt;br /&gt;
| rightButtonName || The name of the right icon. Design time only.&lt;br /&gt;
|-&lt;br /&gt;
| title || The title which appears in the center of the bar. Design time only.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Here is some code showing what happens in its onclick function:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function HeaderBar1_onclick(button)&lt;br /&gt;
  If TypeName(button)=&amp;quot;object&amp;quot; Then Exit Function&lt;br /&gt;
  MsgBox &amp;quot;Button &#039;&amp;quot; &amp;amp; button &amp;amp; &amp;quot;&#039; clicked.&amp;quot;&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
= [[List]] =&lt;br /&gt;
&lt;br /&gt;
[[file:List.jpg]]&lt;br /&gt;
&lt;br /&gt;
The [[List]] control is used to display a menu list. &lt;br /&gt;
&lt;br /&gt;
* Each line can have a name, a number and an image. &lt;br /&gt;
&lt;br /&gt;
* Selecting one will call the onclick function for it, with the line number as a parameter.&lt;br /&gt;
&lt;br /&gt;
* Lines can be added to deleted at runtime.&lt;br /&gt;
&lt;br /&gt;
* List can also be made scrollable if there are more items than fit.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| ChangeForm || A comma separated list of form names to go to if a line is clicked.&lt;br /&gt;
|-&lt;br /&gt;
| dividers || Is the item a divider? Comma separated list of Y and N. Design time.&lt;br /&gt;
|-&lt;br /&gt;
| dividerTheme || Which theme should all the dividers have? A-z. Design time&lt;br /&gt;
|-&lt;br /&gt;
| images || Image file names for each line, comma separated. Design time&lt;br /&gt;
|-&lt;br /&gt;
| imageStyle || None, 16x16 or 80x80. Design time&lt;br /&gt;
|-&lt;br /&gt;
| items || List of item names, comma separated. Since commas act as separators, use &amp;amp;amp;#44; instead of a comma in the middle of your text. Items can be plain text or HTML. Hard returns are ignored. Design time.&lt;br /&gt;
Example: &amp;lt;code&amp;gt;Choose One, Apples, Oranges&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| showNumbers || Show numbers to the left of each item. True/false. Design time&lt;br /&gt;
|-&lt;br /&gt;
| getItem(&#039;&#039;i&#039;&#039;) || Returns the text of item &#039;&#039;i&#039;&#039;.&lt;br /&gt;
|-&lt;br /&gt;
| getItemCount() || Returns the number of of items. Runtime.&lt;br /&gt;
|-&lt;br /&gt;
| deleteItem(&amp;quot;all&amp;quot;) || Delete all items. With no argument, just the last item is deleted. Runtime.&lt;br /&gt;
|-&lt;br /&gt;
| addItem(&#039;&#039;text&#039;&#039;, &#039;&#039;img&#039;&#039;, &#039;&#039;n&#039;&#039;, &#039;&#039;header&#039;&#039;) || Add a new item at postion &#039;&#039;n&#039;&#039; with &#039;&#039;text&#039;&#039; and &#039;&#039;img&#039;&#039;. &#039;&#039;text&#039;&#039; can be html. Runtime. If &#039;&#039;header&#039;&#039; is true, the line appears as a heading. Only &#039;&#039;text&#039;&#039; is required.&lt;br /&gt;
|-&lt;br /&gt;
| replaceItem(&#039;&#039;n&#039;&#039;, &#039;&#039;text&#039;&#039;, &#039;&#039;img&#039;&#039;) || Replace item &#039;&#039;n&#039;&#039; with new &#039;&#039;text&#039;&#039; and optional &#039;&#039;img&#039;&#039;. Runtime.&lt;br /&gt;
|-&lt;br /&gt;
| refresh() || Redraw list after updating. Runtime.&lt;br /&gt;
|-&lt;br /&gt;
| scroll_options || Set display options for scrolling.&lt;br /&gt;
|-&lt;br /&gt;
| Scrolling || on or off.&lt;br /&gt;
|-&lt;br /&gt;
| showNumbers || true/false&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
* Here&#039;s how to handle the click event&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function List1_onclick(i)&lt;br /&gt;
  If TypeName(i)=&amp;quot;object&amp;quot; Then Exit Function&lt;br /&gt;
  MsgBox &amp;quot;Menu item chosen: &amp;quot; &amp;amp; i &amp;amp; &amp;quot; &amp;quot; &amp;amp; List1.getItem(i)&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Here is how to clear the list and add items at runtime&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Function Button1_onclick()&lt;br /&gt;
  List1.deleteItem(&amp;quot;all&amp;quot;)&lt;br /&gt;
  List1.addItem(&amp;quot;Days of the week&amp;quot;,&amp;quot;&amp;quot;,&amp;quot;&amp;quot;,True)&lt;br /&gt;
  For i=1 To 7&lt;br /&gt;
    List1.addItem(WeekdayName(i))&lt;br /&gt;
  Next&lt;br /&gt;
End Function&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;page-break&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= [[Form]] =&lt;br /&gt;
&lt;br /&gt;
[[Form|Forms]] act as containers for controls. &lt;br /&gt;
&lt;br /&gt;
* To add a Form to your app, choose Add Form from the Project menu at the top of the screen. &lt;br /&gt;
&lt;br /&gt;
* Forms can be deleted in the Project Explorer.&lt;br /&gt;
&lt;br /&gt;
* Forms can be exported or imported to different projects.&lt;br /&gt;
&lt;br /&gt;
[[File:form.jpg|right]]&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; &lt;br /&gt;
|-&lt;br /&gt;
| background || Specify the background you want. It can be the usual colors , or a fancy gradient:&lt;br /&gt;
&amp;lt;code&amp;gt;background: -webkit-gradient(linear, left top, left bottom, from(#55aaee), to(#003366));&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| fullscreen || True/False. Should the form fill the entire screen?&lt;br /&gt;
|-&lt;br /&gt;
| height || The height of the form in pixels. Default is 460.&lt;br /&gt;
|-&lt;br /&gt;
| left || The left position of the form. Use this for forms that are not full screen.&lt;br /&gt;
|-&lt;br /&gt;
| fullscreen || The form will automatically be the same size as the device screen. The Design Screen will still use height and width.&lt;br /&gt;
|-&lt;br /&gt;
| language || The programming language used in the code for the form. Can be BASIC or JavaScript.&lt;br /&gt;
|-&lt;br /&gt;
| method || Get or Post. The method that the http form is sent by.&lt;br /&gt;
|-&lt;br /&gt;
| openMode || Should the form be open at startup? Use this for forms which are to remain open. There is no need to set this for the first form of the project: that is set in [[Properties Window|Project Properties]].&lt;br /&gt;
|-&lt;br /&gt;
| script || Opens the Code Window for the form.&lt;br /&gt;
|-&lt;br /&gt;
| style || The CSS style for the form. &lt;br /&gt;
|-&lt;br /&gt;
| Url || The URL to be called when the form is submitted using the submit() function.&lt;br /&gt;
|-&lt;br /&gt;
| width || The width of the form in pixels. Default is 320. Percents can be set at runtime.&lt;br /&gt;
|-&lt;br /&gt;
| reset() || Clear all fields on the form. Runtime only.&lt;br /&gt;
|-&lt;br /&gt;
| submit() || Submit the data on the form to the specified URL. Runtime only. See [[Location]] as well.&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://wiki.appstudio.dev/index.php?title=Frameworks&amp;diff=4676</id>
		<title>Frameworks</title>
		<link rel="alternate" type="text/html" href="https://wiki.appstudio.dev/index.php?title=Frameworks&amp;diff=4676"/>
		<updated>2014-01-07T06:23:35Z</updated>

		<summary type="html">&lt;p&gt;Admin: 19 revisions&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;A Framework is a collection of controls. These controls appear in the ToolBox, organized by Framework.&lt;br /&gt;
&lt;br /&gt;
* Usually developed by a company or organization. &lt;br /&gt;
&lt;br /&gt;
* Designed to have a similar look and feel.&lt;br /&gt;
&lt;br /&gt;
* May be open source or commercial.&lt;br /&gt;
&lt;br /&gt;
* Each has its own set of js and css files.&lt;br /&gt;
&lt;br /&gt;
* AppStudio automatically builds the files into the app.&lt;br /&gt;
&lt;br /&gt;
* Using more than one framework bloats apps&lt;br /&gt;
&lt;br /&gt;
* Frameworks may interfere with each other.&lt;br /&gt;
&lt;br /&gt;
= Common Controls =&lt;br /&gt;
&lt;br /&gt;
* These are simple controls which can be used with any Framework.&lt;br /&gt;
&lt;br /&gt;
* Provide basic functionality&lt;br /&gt;
&lt;br /&gt;
* Include [[Grid]], [[Image]], [[Label]], [[Line]], [[Orientation]], [[PictureBox]] and [[ProgressBar]].&lt;br /&gt;
&lt;br /&gt;
* Advanced ones include [[Date]], [[Date, DateTime|DateTime]], [[Month]], [[Time]], [[Audio]], [[HTMLView|HTMLview]], [[Image]], [[Video]], [[Adsense]], [[Facebook]], [[PayPal]] and [[Twitter]].&lt;br /&gt;
&lt;br /&gt;
= [[A_Field_Guide_to_App_Studio_Controls#jQuery_Mobile_Controls|jQuery Mobile]] =&lt;br /&gt;
&lt;br /&gt;
* One of the most popular&lt;br /&gt;
&lt;br /&gt;
* Developed by same group as the popular jQuery library.&lt;br /&gt;
&lt;br /&gt;
* MIT licence (one of the best open source licenses)&lt;br /&gt;
&lt;br /&gt;
* AppStudio includes 14 jQuery Mobile controls: [[Button]], [[Checkbox]], [[FlipToggle]], [[FooterBar]], [[HeaderBar]], [[List]], [[PopUp]], [[RadioButton]], [[Select]], [[Slider]], [[TextArea]], [[TextBox]], [[ToolTip]]&lt;br /&gt;
&lt;br /&gt;
* New controls being added.&lt;br /&gt;
&lt;br /&gt;
* Actively being developed.&lt;br /&gt;
&lt;br /&gt;
= [[A_Field_Guide_to_App_Studio_Controls#jqWidgets_Controls|jqWidgets]] =&lt;br /&gt;
&lt;br /&gt;
* Contains some rich and powerful controls.&lt;br /&gt;
&lt;br /&gt;
* Commercial, so it is not free for all apps.&lt;br /&gt;
&lt;br /&gt;
* No charge for use in non-profit organizations.&lt;br /&gt;
&lt;br /&gt;
* AppStudio includes 16 jqWidgets controls: [[jqxButton]], [[JqxCalender|Calendar]], [[jqxChart|Chart]], [[jqxCheckBox|CheckBox]], [[jqxColorPicker|ColorPicker]], [[jqxDragDrop|DragDrop]], [[jqxGrid|Grid]], [[jqxInput|Input]], [[jqxListBox|ListBox]], [[jqxMenu|Menu]], [[jqxPhotoGallery|PhotoGallery]], [[jqxRadialGauge|RadialGauge]], [[jqxRating|Rating]], [[jqxSwitchButton|SwitchButton]], [[jqxTabs|Tabs]] and [[jqxTree|Tree]].&lt;br /&gt;
&lt;br /&gt;
* Actively being developed.&lt;br /&gt;
&lt;br /&gt;
= [[A_Field_Guide_to_App_Studio_Controls#iWebKit_Controls|iWebKit]] =&lt;br /&gt;
&lt;br /&gt;
* One of the first frameworks: existed well before jQuery Mobile.&lt;br /&gt;
&lt;br /&gt;
* Controls are small, efficient, not fancy.&lt;br /&gt;
&lt;br /&gt;
* No longer being developed or supported.&lt;br /&gt;
&lt;br /&gt;
* Version 5.0.3 under MIT License.&lt;br /&gt;
&lt;br /&gt;
= Other Frameworks =&lt;br /&gt;
&lt;br /&gt;
* Wikipedia lists more than 100!&lt;br /&gt;
 &lt;br /&gt;
* New frameworks are being announced regularly on the net&lt;br /&gt;
&lt;br /&gt;
* To add them to AppStudio, [[ToolBox Files]] need to be created.&lt;br /&gt;
&lt;br /&gt;
* Doing so requires skills not covered in this training.&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
</feed>