NSB/App Studio FAQ: Difference between revisions

From NSB App Studio
Jump to navigation Jump to search
 
(83 intermediate revisions by 2 users not shown)
Line 4: Line 4:
=== What kind of dev tool is this? ===
=== What kind of dev tool is this? ===


AppStudio is a complete development environment for mobile devices. It can be programmed in JavaScript or BASIC. The BASIC language implements a large subset of Microsoft's Visual Basic, with extensions to create a complete development environment. AppStudio BASIC is a full, modern implementation of BASIC, with proper subroutines, variant data types and no line numbers.
AppStudio provides you with a curated stack which gives you everything you need to develop mobile and web apps, in one download. The components in the stack are selected to work well with each other: the AppStudio IDE glues them all together to make them easy to use. We also take care of updating and replacing them as needed.
It can be programmed in JavaScript or BASIC. The BASIC language implements a large subset of Microsoft's Visual Basic, with extensions to create a complete development environment. AppStudio BASIC is a full, modern implementation of BASIC, with proper subroutines, variant data types and no line numbers.


Applications you create are freely distributable and are write-once, run anywhere. Lots of sample code is included.  
Applications you create are freely distributable and are write-once, run anywhere. Lots of sample code is included.  


The environment features a Visual Designer, which allows you to graphically lay out your control and set their properties. You can then hook code into the controls and add other code as needed. When your code is complete, use one key run run it locally, deploy it to a website or convert it to a native app using PhoneGap.
The environment features a Visual Designer, which allows you to graphically lay out your control and set their properties. You can then hook code into the controls and add other code as needed. When your code is complete, use one key to run it locally, deploy it to a website or convert it to a native app using Apache Cordova or VoltBuilder.


If you have worked with Microsoft's Visual Studio, you'll find it easy to come up to speed.
If you have worked with Microsoft's Visual Studio, you'll find it easy to come up to speed.
=== What's in the stack? ===
==== Controls ====
AppStudio supports three frameworks, each of which adds a set of HTML elements to the AppStudio Toolbox:
<ul>
<li>Bootstrap - developed by Twitter, one of most widely used frameworks (and it's nice looking!)
<li>jQuery Mobile - from the jQuery Foundation
<li>jqWidgets - an excellent commercial framework with powerful controls.
</ul>
We also provide a set of generic, lightweight controls.
We also provide tools to create your own controls (or customize the ones which come with AppStudio.)
==== Editors ====
<ul>
<li>Design Screen - drag and drop controls from the Toolbox. Move them around and resize them graphically. Each control has its own list of properties you can customize.
<li>Code Window - Edit and format your code in JavaScript or BASIC.
</ul>
The Design Screen and Code Window are fully integrated - click on a control in the Design Screen to see its event code.
==== Deploy ====
Once you've created your UI and the code to go with it, AppStudio gives you a variety of ways to distribute it:
<ul>
<li>Run locally in the browser: great for testing and debugging
<li>Deploy to VoltServer: So others can download your app
<li>Deploy to your own server: So others can download your app from your server
<li>Deploy to VoltBuilder to make apps for the Google and Amazon stores
<li>Deploy to VoltBuilder to make apps for the Apple Store
<li>Deploy to Cordova locally
<li>Create a Windows desktop exe.
</ul>
The options are all integrated into AppStudio - no need to type obscure commands from the command line.
=== When was it released? ===
In December, 2010. It is currently at Version 6.x
=== How many paid users are there? ===
As of August, 2016, there are over 1 million users in over 70 countries.


=== What devices do the apps it creates run on? ===
=== What devices do the apps it creates run on? ===


AppStudio apps run on:
AppStudio apps run on:
* iPhone (any model) with iOS 3.0 or later
* iPhone (any model) with iOS 4.3 or later
* iPod Touch (any model) with iOS 3.0 or later
* iPod Touch (any model) with iOS 4.3 or later
* iPad (any model)
* iPad (any model)
* Android 2.1 (or later) devices.
* Android 2.3 (or later) devices. Limited functionality on older devices.
* BlackBerry OS 6 (or later) devices
 
* HP Web OS devices
They will also run on the desktop with Chrome, Safari and Internet Explorer.
* Windows Phone devices (limited)
 
=== What about the Apple Watch? ===
 
At this point, it does not look like it will be. AppStudio uses a WebView for its interface: apparently, the Apple Watch does not have this feature.
 
=== What desktop computer do I need to run AppStudio? ===
 
Development can be done on the following computers:
Development can be done on the following computers:
* Mac OS 10.8 and 10.7. Mac OS 10.6 if running on a 64 bit processor
* Mac OS 10.13 or later.
* Windows 8, 7, Vista or XP.
* Windows 10 (Intel) or later
* Virtualbox WIN/XP and Ubuntu Wine also work.
* Virtualbox with Windows 10 on Linux


=== What technologies is it built on? ===
=== What technologies is it built on? ===


AppStudio makes use of JavaScript, HTML5, CSS and WebKit. These are all under the covers, however: there is no need to learn these technologies to use the product. Your BASIC code is translated to JavaScript, which is then executed by the same browser engine used by Safari, Chrome or whatever web browser the device uses. Similarly, screen objects are internally implemented in HTML, taking advantage of HTML5 and WebKit technologies.
AppStudio makes use of JavaScript, HTML5, CSS and WebKit. These are all under the covers: there is no need to learn these technologies to use the product. Your BASIC code is translated to JavaScript, which is then executed by the same browser engine used by Safari, Chrome or whatever web browser the device uses. Similarly, screen objects are internally implemented in HTML, taking advantage of HTML5 and WebKit technologies.


Recent work by Google and Apple have given dramatic speed improvements to JavaScript: it is now faster than many purely compiled languages. It's substantially faster than .NET, for example.
Recent work by Google and Apple have given dramatic speed improvements to JavaScript: it is now faster than many purely compiled languages. It's substantially faster than .NET, for example.
=== Is Apache Cordova/VoltBuilder supported? ===
Yes, both are. Apache Cordova makes it much easier to build native apps on your desktop using the iOS and Android toolchains, at no cost. VoltBuilder is a service with makes this much easier.
In either case, AppStudio packages all the files, HTML, CSS and JavaScript so that Cordova and VoltBuilder can build native apps immediately.
=== Should I program in JavaScript or BASIC? ===
Either. You can even mix JavaScript and BASIC in the same project. AppStudio converts the BASIC to JavaScript, so it is all JavaScript at runtime.
If you have some BASIC code, you can right click it in the Code Window to see the JavaScript translation.
BASIC is a good language for those who are comfortable with it. JavaScript is the language of the future (and the present!). JavaScript is also more powerful. Since there is no translation step, it will also compile faster. There will be no real difference in performance at runtime.


=== How big is the runtime? ===
=== How big is the runtime? ===
Line 37: Line 100:
Tiny - less than 125k. Of course, this number will increase if you use various libraries and frameworks.
Tiny - less than 125k. Of course, this number will increase if you use various libraries and frameworks.


=== Why isn't AppStudio just like Visual Basic or NS Basic/CE? ===
=== Is AppStudio just like Visual Basic or NS Basic/CE? ===


It's actually a lot like Visual Basic and NS Basic/CE. Both use the same core language definition: all the statements and functions are identical. The differences lie in the operating system and environment. For example, the screen controls on an iPhone have a very different look and feel to their counterparts on the desktop. Controls which are designed to be touch operated will work differently from keyboard and mouse style controls.
It's actually a lot like Visual Basic and NS Basic/CE. Both use the same core language definition: all the statements and functions are identical. The differences lie in the operating system and environment. For example, the screen controls on an iPhone have a very different look and feel to their counterparts on the desktop. Controls which are designed to be touch operated will work differently from keyboard and mouse style controls.
We used the VBScript Reference manual as a guide for our design. Read more here about [[Compatibility with other versions of BASIC]] .
=== How do I convert my VB project to AppStudio? ===
The general procedure is as follows:
# Create the form(s) using the same names using AppStudio.
# On each form, add the controls, again using the same names. Most of the VB controls have direct replacements. You will need to change the size and layout to suit the screen size of a device.
# Copy and paste the code from each VB form into your AppStudio project.
# Debug and smooth over differences.


=== How fast is it? ===
=== How fast is it? ===


AppStudio executes over 1,000,000 loops/second on the current generation of devices. That's pretty quick for devices in this class, fast enough for most anything but perhaps the very heaviest number crunching.
AppStudio executes over 10,000,000 loops/second on the current generation of devices. That's pretty quick for devices in this class, fast enough for most anything but perhaps the very heaviest number crunching.


=== How can I test my programs? ===
=== How can I test my programs? ===


During development, AppStudio runs your program in your default browser: Chrome and Safari work best. They both have good debugging facilities. The program looks and feels much like it will on a real device. Of course, you should also test on actual devices.
During development, AppStudio runs your program in your default browser: Chrome and Safari work best. They both have good debugging facilities. The program looks and feels much like it will on a real device. Of course, you should also test on actual devices.
You can also deploy to the AppStudio Server or to your own server. You can then download your app to your device.
=== What is your Test Server? ===
Our Test Server is available to all AppStudio users to upload apps to. It's built into AppStudio so no setup is needed. Once there, any mobile device can download your app.
There are certain restrictions on the server so it does not get hacked or overloaded. Very, very large projects cannot be uploaded; projects which have not been updated in a while are purged, and PHP scripts are not allowed.


=== Can I do file I/O? ===
=== Can I do file I/O? ===
Line 59: Line 141:
One thing you cannot do is access the actual file system of the device. Modern mobile operating systems "sandbox" the apps so they cannot interfere with each other.
One thing you cannot do is access the actual file system of the device. Modern mobile operating systems "sandbox" the apps so they cannot interfere with each other.


If localStorage and SQLite are not sufficient (they almost always are), access to the device's filesystem is available using a PhoneGap Plugin.
If localStorage and SQLite are not sufficient (they almost always are), access to the device's filesystem is available using a [https://www.npmjs.com/package/cordova-plugin-file Cordova Plugin]. This includes SD cards on devices which have them.
 
=== Can I use ftp? Can I write to my sdcard? ===
 
You might want to look at this a bit differently. To begin with, most devices do not have an sdcard, so your software probably should not assume there is one.
 
Second, the information is in a string on the server, and you will want to use it as a string in your app. Why convert it to a csv and back again? It will be much quicker and easier if you skip those steps. [[Ajax made Simple|Ajax]] is the way to go here - ftp is pretty much an obsolete technology now.
 
Actually, using FTP is relatively simple, if you have an FTP client.  But JS was built to "talk" HTTP and you have to have an external JS library to make FTP work  There is one in the Cordova world (https://github.com/macdonst/FtpClient).  We have not tried it and cannot vouch for it, so caveat emptor.
 
If you are connecting to your own server, implementing a PHP (or .Net, whatever) script will be much easier a task. If you use your own server, pay attention to security; there are lots of rogue actors on the net that will trash an unprotected site in seconds.
If, however you have client demands or are working with  a commercial FTP site and have no choice but to use FTP, grab that library.  The good thing is that there are lots of FTP server apps out on the web (I have used Filezilla and it's great) so your code only involves the JS client,
 
I've done both, so here's a perspective:
If you're asking for FTP because you think it's the way to go for file transfer, think again.  But if the project has a hard requirement for FTP, dive in and keep in touch. (Comments from Lee Church).


=== Can I access a database on my server, such as MySQL, Access, Oracle, etc.? ===
=== Can I access a database on my server, such as MySQL, Access, Oracle, etc.? ===
Line 65: Line 161:
The only database that runs locally on mobile devices is SQLite. If you want to get information from a server database to your device, you have a couple of choices:
The only database that runs locally on mobile devices is SQLite. If you want to get information from a server database to your device, you have a couple of choices:
* Import the data into an SQLite database and include it with your project.
* Import the data into an SQLite database and include it with your project.
* Have a listener program on a port on your server. Use AJAX calls from your app to the listener program. The listener program can then access the database on the server and return the requested information.
* Have a listener program on a port on your server. Use [[Ajax made Simple|AJAX]] calls from your app to the listener program. The listener program can then access the database on the server and return the requested information.
 
=== Can I read and update an Excel spreadsheet? ===
 
Since Excel does not run on mobile devices, it (and the spreadsheet itself) need to be running on a server.
 
You'll need a program on the server to read and update the Excel spreadsheet, that can also communicate with your mobile app, much like with databases.


=== What can't I do? ===
=== What can't I do? ===


For things like Bluetooth, microphone, serial comms, you'll need to use PhoneGap. PhoneGap lets you run your AppStudio app as a native application. It has plug ins which let you use native API functions.
For things like Bluetooth, microphone, serial comms, you'll need to use VoltBuilder. VoltBuilder lets you run your AppStudio app as a native application. It has plugins which let you use native API functions.


=== Tell me more about Bluetooth! ===
=== Tell me more about Bluetooth! ===


Bluetooth is workable, but a bit of a pain at present. Here's a summary of what it takes:
Using VoltBuilder, it's practical to use Bluetooth.
#  JavaScript/HTML5 will never be able to talk to the BT stack directly. That takes native code.
#  JavaScript/HTML5 will never be able to talk to the BT stack directly. That takes native code.
# To use native code, you need to build a native app. PhoneGap has a nice way of doing this, using plugins. AppStudio works well with PhoneGap, and there is a Bluetooth plugin for PhoneGap.
# To use native code, you need to build a native app. VoltBuilder has a nice way of doing this, using plugins. AppStudio works well with VoltBuilder, and there is a Bluetooth plugin for VoltBuilder.
# PhoneGap Build makes it easy to compile AppStudio + Plugin apps. However, only official PhoneGap plugins are supported by PhoneGap  Build.
# VoltBuilder makes it easy to compile AppStudio + Plugin apps.
# The Bluetooth plugin is not an official plugin, so PhoneGap SDK has to be used.
# PhoneGap SDK involves installing and using the complete toolchain for Apple, Android and any other platforms. While not as tough as developing with the native SDK, you still do need to install it.
# We have to hope that the BT plugin becomes official, or that PhoneGap Build opens up to third party plugins.


You can develop and test the rest of your app normally - just the BlueTooth dependent parts will need testing with PhoneGap.
You can develop and test the rest of your app normally - just the Bluetooth dependent parts will need testing with VoltBuilder.
 
=== Can I print to a Bluetooth printer? ===
 
Yes. There is no native support in JavaScript, and different printers need different control codes. It can be done by using a third-party app that isolates your app from the complexities of supporting multiple printers. Create an HTML document as a file on the device. The the user invokes the printer app and prints the file.  An example app for this is PrinterShare. This is not perfect (it's a bit complicated) but it produces great-looking output and once the app has produced the HTML file we're done. If you have lots of time and $$ you can write your own printer routine.
 
There are also Bluetooth printer libraries available as Cordova Plugins, but only a few printers are supported.


=== What about hardware specific features? ===
=== What about hardware specific features? ===
Some, but not all, hardware features are available. The GPS and Accelerometer data certainly is, but it is not possible to vibrate the phone. Once again, PhoneGap comes to the rescue.
Most hardware features are available. The Camera, Compass, GPS and Accelerometer are, but it is not possible to vibrate the phone. Once again, VoltBuilder comes to the rescue.


=== How do I handle different screen sizes? ===
=== How do I handle different screen sizes? ===
Line 92: Line 197:
In most cases, simply scaling the controls on the form will give poor results. The best way to do this is to detect the screen size on startup and adjust the sizes and positions of your controls. There's a handy [[Properties_and_Methods|.resize(left, top, width, height]]) function to help you do this. Scaling does not work, since buttons will look oddly sized, images will have incorrect aspect ratios, and poor use will be made of the screen real estate.
In most cases, simply scaling the controls on the form will give poor results. The best way to do this is to detect the screen size on startup and adjust the sizes and positions of your controls. There's a handy [[Properties_and_Methods|.resize(left, top, width, height]]) function to help you do this. Scaling does not work, since buttons will look oddly sized, images will have incorrect aspect ratios, and poor use will be made of the screen real estate.


If you do want to use simple scaling, there sample on the web board. Have a look at [http://f1.grp.yahoofs.com/v1/kNR2UaJT-1Kj21UT6HvtQ4-NyJx1OG-wvADA9sduQt_WN9fdnxB8SDcibXqP2zJdt_ZsAS4jrehStvRaLraFew/Zoom.zip Zoom] by winvetpro or [http://tech.groups.yahoo.com/group/nsbasic-app/files/Easy%20Orientation%20/ Easy Orientation] by Leslie Peaker.
Controls can have their bounds set as percentages. For example, you could set a TextArea to be 80% of the width and 50% of the height of the screen, positioned 10% from the left and 30% from the top.
 
Another thing to keep in mind is that tablet apps often need a different approach than phone sized apps. The extra space on the screen can be used to display a list of items (such as email messages) while the main part of the screen can be used to display the selected message. This wouldn't fit on a phone sized screen, but results in a more usable app on tablets.
 
(If you do want to use simple scaling, there is a sample on the web board. Have a look at [http://f1.grp.yahoofs.com/v1/6PZGUo3zxT1TuKvshBsDhpJ2-egGddnYPNB9mWyousyDMP5LYJ2pUZ0CSq5Zt14tM7YDGMtH48A9F4HdFNHydw/Zoom.nsx Zoom] by winvetpro.)
 
=== What about retina displays? ===
 
Retina displays work just like regular displays: your program will run the same on either, filling the entire screen. If you are using a retina display, fonts will be drawn using the higher resolution, producing crisper text. If you supply hi res versions of images, they will be displayed instead of the low res version.
 
=== My phone is 1920x1080. Why can't I address all the pixels? ===
 
While your phone may physically have that many pixels, the operating system treats them as doubled or even tripled pixels. You'll only be able to address 640x360 or 960x540, depending on the device. The operating system will take care of mapping the pixels to their actual location. This is actually very good news: it means that you won't have to drastically change your app each time it runs on a new device.


=== How can I detect when the app is closing? ===
=== How can I detect when the app is closing? ===


You can't, really. Apps close when you start another app. A app with a Close or Quit button will actually get rejected from app stores for violating user interface guidelines. Starting the app again will bring back the already running version (for PhoneGap apps) and restart it from the beginning (for web apps) or if the device was shut down in the meantime.
You can't. Apps close when you start another app. A app with a Close or Quit button will actually get rejected from app stores for violating user interface guidelines. Starting the app again will bring back the already running version (for VoltBuilder apps) and restart it from the beginning (for web apps) or if the device was shut down in the meantime.


The best technique is to constantly save the current state of the app in [[localStorage]] and [[Using SQLite|SQLite]]. When the app restarts, check the last saved status in localStorage, go to the most recent form and fill in all the fields. Done right, it will look as though the app was never exited.
The best technique is to constantly save the current state of the app in [[localStorage]] and [[Using SQLite|SQLite]]. When the app restarts, check the last saved status in localStorage, go to the most recent form and fill in all the fields. Done right, it will look as though the app was never exited.


=== What's on the roadmap? ===
=== Can I use WinSock? UDP? sockets? ===
 
AppStudio has support for [http://en.wikipedia.org/wiki/Websockets WebSockets] built in. It's the easiest way to do this and works well with current web security practices.
 
WinSock, UDP and older style sockets can be done using Cordova Plugins. If there is one that fits your needs in the [https://volt.build/docs/approved_plugins/ list of Cordova Plugins], It will be easy to use with AppStudio. If the plugin is not yet compatible with https://volt.build/docs/approved_plugins/, you will need to use the full Cordova API.
 
=== What about proxys and firewalls? ===
 
AppStudio needs to contact the appstudio.dev server on startup to verify your serial number. You will need to make sure your system allows for this. The address is <pre>https://www.nsbasic.com</pre>.


AppStudio has a lot of potential for new features. Here are some of the ones we are working on - please note that this list can change at any time as we reasses how practical and important each item is.
If you are routing through a proxy, make sure to add localhost, 127.0.0.0 to the ignore list. AppStudio uses this for local testing.
* Design Screen: Move objects with arrow keys
 
* IDE: Localization in other languages
=== Can I read barcodes? ===
 
Yes. There are several ways to do so. Check out this blog post: [http://blog.appstudio.dev/2016/04/how-to-read-barcodes/ How to read barcodes].


== Support and Documentation ==
== Support and Documentation ==
Line 110: Line 237:
=== How is it supported? ===
=== How is it supported? ===


NS BASIC provides support by email and on a very active [[http://tech.groups.yahoo.com/group/nsbasic-app/ web board]]. We post bug fix updates to our ftp site on a regular basis. Check the web board and our [http://blog.nsbasic.com blog] for the latest announcements.
AppStudio is supported by email and on a very active [[https://discuss.appstudio.dev web board]]. We post bug fix updates to our ftp site on a regular basis. Check the web board and our [http://blog.appstudio.dev blog] for the latest announcements.


=== Is there an option for Premium Support? ===
=== Is there an option for Premium Support? ===


Yes. For a monthly fee, you cam get Premium Support which includes direct access to the developers, fast turnaround time and much. See our [http://nsbasic.com/app/support.php/ Support Policies].
Yes. For a monthly fee, you can get Premium Support which includes direct access to the developers, fast turnaround time and much. See our [http://www.appstudio.dev/app/support.php/ Support Policies].


=== What documentation is included? ===
=== What documentation is included? ===


There is a wiki that contains the complete documentation on the IDE and the language. It is included with the product for offline use. Short summaries of most functions are in on line help. There are also [[Tech Notes|tech notes]] and [[tutorials]].
There is a wiki that contains the complete documentation on the IDE and the language. It is included with the product for offline use. Short summaries of most functions are in on line help. There are also [[Tech Notes|tech notes]] and [[tutorials]].
=== Is the a hardcopy Handbook? ===
We got rid of hard copy handbooks several years ago. We were reluctant to do so, but the seachability and linking that a Wiki provides is essential once you get used to it.
Not having to worry about page count let us expand the amount of documentation we have by quite a bit.
There are utilities which can print out a Wiki, but they tend to be cumbersome.


== Distributing your app ==
== Distributing your app ==
Line 125: Line 260:


Yes. You may distribute your apps, with no further royalties or costs.
Yes. You may distribute your apps, with no further royalties or costs.
AppStudio apps can be distributed without going through Apple's iTunes store or Google's Marketplace. This is great news: setting up an app in the iTunes store can be more challenging than writing an app in AppStudio. Instead, apps are distributed over the web. Apps can be sold by controlling who is allowed to access the app.
AppStudio apps can be distributed without going through Apple's iTunes store or Google's Marketplace. This is great news: setting up an app in the iTunes store can be more challenging than writing an app in AppStudio. Instead, apps can be distributed over the web. Apps can be sold by controlling who is allowed to access the app.


=== But I want to distribute my app through the App Store! ===
=== But I want to distribute my app through the App Store! ===


If you want to distribute through the App Store, you can wrap the project in PhoneGap.
If you want to distribute through the App Store, you can compile the project using VoltBuilder.
Create iOS App Store apps using PhoneGap
[[Submitting to the iOS App Store]]
Getting started with PhoneGap videos
[[Submitting to the Google Play and Amazon Stores]]
PhoneGap itself is free - you will need to pay Apple $99/year to belong.


=== Do I need a Mac to distribute through the App Store? ===
=== Do I need a Mac to distribute through the App Store? ===


To do the final submission of an app compile as native to Apple's App Store, you need a Mac. The program used to upload apps, "Application Loader.app" is a Mac only application. You can buy a used Mac Mini for this - they are not expensive.
No. VoltBuilder takes care of this for you. As part of the build process, VoltBuilder will upload your app to Apple's iTunes Store.
You do not need a Mac to distribute your app as a web app, outside the App Store.


=== How can I protect my code? ===
=== How can I protect my code? ===


We incorporate obfuscation into the Deploy step: this makes it difficult for people to look at your code. Of course, any executable can be reverse engineered with a bit of effort.
There is an option to obfuscate in the Deploy step: this makes it more difficult for people to look at your code. Third party utilities exist with improved obfuscation, which will require more sophisticated tools to look at.
 
For improved security, compile your app using VoltBuilder. This will result in an executable. It is still possible, however, to unpack the executable and examine the source files.
 
Any executable, on any platform, can be reverse engineered with sufficient effort.


== Licensing and Upgrades ==
== Licensing and Upgrades ==
Line 147: Line 284:
=== Where can I buy it? What does it cost? ===
=== Where can I buy it? What does it cost? ===


AppStudio is available at an introductory price of $99.95 USD directly from NS BASIC Corporation's website (regularly $149.95). You may download the software and start using it immediately after your order.
AppStudio for a single developer is available for a one time fee of $199 USD or by subscription directly from NSB Corporation's [https://www.appstudio.dev/i/Subscription/ order page].


=== What is your upgrade policy? ===
=== What is your upgrade policy? ===
Line 155: Line 292:
=== I want to run it at the office, on my laptop and at home. How many licenses do I need? ===
=== I want to run it at the office, on my laptop and at home. How many licenses do I need? ===


One, so long as you are the only one using it. The license is to a single developer.  
One, so long as you are the only one using it. The license is to a single developer. You can even run a mix of Windows and Mac computers, up to a maximum of three computers.


=== I have a number of developers. Do I have to buy licenses for all of them? ===
=== I have a number of developers. Do I have to buy licenses for all of them? ===
Line 163: Line 300:
=== I would like to use AppStudio in my classroom. What license do I need? ===
=== I would like to use AppStudio in my classroom. What license do I need? ===


The Educational License is a perpetual classroom license. Students will be able to use personal copies for the duration of the semester they are attending the course: the reacher can reuse the license in the next term with a new class of students.
The Educational License is a perpetual classroom license. Students will be able to use personal copies for the duration of the semester they are attending the course: the reacher can reuse the license in the next term with a new class of students. If you are a teacher and would like a free version, [https://www.appstudio.dev/i/OrderTeacher/ send us your credentials].
 
=== The demo period has expired, but I'm not done testing. ===
 
You have 3 options:
 
1. Change the system date when you start the demo. It only checks it on start, so you can put it back right away.
 
2. Take advantage of our 30 day no hassle money back. Buy it and if it doesn't work for you, let us know and we refund right away.
 
3. Run on another machine.
 
=== How can I change/cancel my subscription? ===
 
You can do so here: https://wiki.appstudio.dev/Subscriptions


== Other ==
== Other ==


=== Who is NS BASIC Corporation? ===
=== Are you available for contract work? ===
 
Yes, we are available for contract work. AppStudio comes first, of course, but working on real projects keeps the guys here in touch with the real world.  Send a message to us if you are interested.
 
=== Who is NSB Corporation? ===


NS BASIC was formed in 1993 to create applications for developers using hand held computers. The initial product, NS BASIC for the Newton, started shipping in 1994 and has consistently been one of the top selling packages on the Newton platform. The product has been continuously updated since its first release.
NSB Corporation was formed in 1993 to create applications for developers using hand held computers. The initial product, NS BASIC for the Newton, started shipping in 1994 and was one of the top selling packages on the Newton platform. The product has been continuously updated since its first release.
In late 1997, NS BASIC released its next product, NewtCard, a product inspired by Apple's HyperCard application. NewtCard has probably garnered more "Best of" awards than any application produced for hand held computers.
In late 1997, NSB released its next product, NewtCard, a product inspired by Apple's HyperCard application. NewtCard has probably garnered more "Best of" awards than any application produced for hand held computers to that point.


NS Basic/Newton and NewtCard are two of the three software products to garner a "First Class Award" from Mobile Computing.
NS Basic/Newton and NewtCard are two of the three software products to garner a "First Class Award" from Mobile Computing.
Line 177: Line 332:
NS Basic/Palm was released in 2000. It became the most popular development tool for those devices.
NS Basic/Palm was released in 2000. It became the most popular development tool for those devices.


Over the years, NS BASIC Corporation has developed a large body of special expertise in creating development environments for hand sized computers. Combining effective user interfaces for small, pen based screens with efficient use of resources built into the ROM, NS BASIC's applications are surprisingly powerful, small, and easy to use.  
Over the years, NSB Corporation has developed a large body of special expertise in creating development environments for hand sized computers. Combining effective user interfaces for small, pen based screens with efficient use of resources built into the ROM, NSB's applications are surprisingly powerful, small, and easy to use.  


You can contact NS BASIC Corporation by email at info@nsbasic.com, phone at 1 888 NSBASIC (416 264-5999) or fax at 416 264-5888.
You can contact NSB Corporation by email at support@appstudio.dev, phone at 1 888 672-2742 (416 264-5999) or fax at 416 264-5888.


=== So what does the "NS" stand for, anyhow? ===
=== So what does the "NS" stand for, anyhow? ===


Nice & Smart.
Nice & Smart.

Latest revision as of 10:07, 9 July 2024

Frequently Asked Questions (FAQ)(faq)

The product itself

What kind of dev tool is this?

AppStudio provides you with a curated stack which gives you everything you need to develop mobile and web apps, in one download. The components in the stack are selected to work well with each other: the AppStudio IDE glues them all together to make them easy to use. We also take care of updating and replacing them as needed.

It can be programmed in JavaScript or BASIC. The BASIC language implements a large subset of Microsoft's Visual Basic, with extensions to create a complete development environment. AppStudio BASIC is a full, modern implementation of BASIC, with proper subroutines, variant data types and no line numbers.

Applications you create are freely distributable and are write-once, run anywhere. Lots of sample code is included.

The environment features a Visual Designer, which allows you to graphically lay out your control and set their properties. You can then hook code into the controls and add other code as needed. When your code is complete, use one key to run it locally, deploy it to a website or convert it to a native app using Apache Cordova or VoltBuilder.

If you have worked with Microsoft's Visual Studio, you'll find it easy to come up to speed.

What's in the stack?

Controls

AppStudio supports three frameworks, each of which adds a set of HTML elements to the AppStudio Toolbox:

  • Bootstrap - developed by Twitter, one of most widely used frameworks (and it's nice looking!)
  • jQuery Mobile - from the jQuery Foundation
  • jqWidgets - an excellent commercial framework with powerful controls.

We also provide a set of generic, lightweight controls.

We also provide tools to create your own controls (or customize the ones which come with AppStudio.)

Editors

  • Design Screen - drag and drop controls from the Toolbox. Move them around and resize them graphically. Each control has its own list of properties you can customize.
  • Code Window - Edit and format your code in JavaScript or BASIC.

The Design Screen and Code Window are fully integrated - click on a control in the Design Screen to see its event code.

Deploy

Once you've created your UI and the code to go with it, AppStudio gives you a variety of ways to distribute it:

  • Run locally in the browser: great for testing and debugging
  • Deploy to VoltServer: So others can download your app
  • Deploy to your own server: So others can download your app from your server
  • Deploy to VoltBuilder to make apps for the Google and Amazon stores
  • Deploy to VoltBuilder to make apps for the Apple Store
  • Deploy to Cordova locally
  • Create a Windows desktop exe.

The options are all integrated into AppStudio - no need to type obscure commands from the command line.

When was it released?

In December, 2010. It is currently at Version 6.x

How many paid users are there?

As of August, 2016, there are over 1 million users in over 70 countries.

What devices do the apps it creates run on?

AppStudio apps run on:

  • iPhone (any model) with iOS 4.3 or later
  • iPod Touch (any model) with iOS 4.3 or later
  • iPad (any model)
  • Android 2.3 (or later) devices. Limited functionality on older devices.

They will also run on the desktop with Chrome, Safari and Internet Explorer.

What about the Apple Watch?

At this point, it does not look like it will be. AppStudio uses a WebView for its interface: apparently, the Apple Watch does not have this feature.

What desktop computer do I need to run AppStudio?

Development can be done on the following computers:

  • Mac OS 10.13 or later.
  • Windows 10 (Intel) or later
  • Virtualbox with Windows 10 on Linux

What technologies is it built on?

AppStudio makes use of JavaScript, HTML5, CSS and WebKit. These are all under the covers: there is no need to learn these technologies to use the product. Your BASIC code is translated to JavaScript, which is then executed by the same browser engine used by Safari, Chrome or whatever web browser the device uses. Similarly, screen objects are internally implemented in HTML, taking advantage of HTML5 and WebKit technologies.

Recent work by Google and Apple have given dramatic speed improvements to JavaScript: it is now faster than many purely compiled languages. It's substantially faster than .NET, for example.

Is Apache Cordova/VoltBuilder supported?

Yes, both are. Apache Cordova makes it much easier to build native apps on your desktop using the iOS and Android toolchains, at no cost. VoltBuilder is a service with makes this much easier.

In either case, AppStudio packages all the files, HTML, CSS and JavaScript so that Cordova and VoltBuilder can build native apps immediately.

Should I program in JavaScript or BASIC?

Either. You can even mix JavaScript and BASIC in the same project. AppStudio converts the BASIC to JavaScript, so it is all JavaScript at runtime.

If you have some BASIC code, you can right click it in the Code Window to see the JavaScript translation.

BASIC is a good language for those who are comfortable with it. JavaScript is the language of the future (and the present!). JavaScript is also more powerful. Since there is no translation step, it will also compile faster. There will be no real difference in performance at runtime.

How big is the runtime?

Tiny - less than 125k. Of course, this number will increase if you use various libraries and frameworks.

Is AppStudio just like Visual Basic or NS Basic/CE?

It's actually a lot like Visual Basic and NS Basic/CE. Both use the same core language definition: all the statements and functions are identical. The differences lie in the operating system and environment. For example, the screen controls on an iPhone have a very different look and feel to their counterparts on the desktop. Controls which are designed to be touch operated will work differently from keyboard and mouse style controls.

We used the VBScript Reference manual as a guide for our design. Read more here about Compatibility with other versions of BASIC .

How do I convert my VB project to AppStudio?

The general procedure is as follows:

  1. Create the form(s) using the same names using AppStudio.
  2. On each form, add the controls, again using the same names. Most of the VB controls have direct replacements. You will need to change the size and layout to suit the screen size of a device.
  3. Copy and paste the code from each VB form into your AppStudio project.
  4. Debug and smooth over differences.

How fast is it?

AppStudio executes over 10,000,000 loops/second on the current generation of devices. That's pretty quick for devices in this class, fast enough for most anything but perhaps the very heaviest number crunching.

How can I test my programs?

During development, AppStudio runs your program in your default browser: Chrome and Safari work best. They both have good debugging facilities. The program looks and feels much like it will on a real device. Of course, you should also test on actual devices.

You can also deploy to the AppStudio Server or to your own server. You can then download your app to your device.

What is your Test Server?

Our Test Server is available to all AppStudio users to upload apps to. It's built into AppStudio so no setup is needed. Once there, any mobile device can download your app.

There are certain restrictions on the server so it does not get hacked or overloaded. Very, very large projects cannot be uploaded; projects which have not been updated in a while are purged, and PHP scripts are not allowed.

Can I do file I/O?

Yes. For simple files, there is a localStorage which lets you save and retrieve string data. It is persistant, meaning the data will still be there next time you start the program. Most devices allow up to 5 megs (sometime much more) per app.

SQLite is supported for more sophisticated applications. It's an easy to use database that gives good performance.

Files can be read using the ReadFile function if they are loaded from the same server as the app. See the ReadFile sample.

One thing you cannot do is access the actual file system of the device. Modern mobile operating systems "sandbox" the apps so they cannot interfere with each other.

If localStorage and SQLite are not sufficient (they almost always are), access to the device's filesystem is available using a Cordova Plugin. This includes SD cards on devices which have them.

Can I use ftp? Can I write to my sdcard?

You might want to look at this a bit differently. To begin with, most devices do not have an sdcard, so your software probably should not assume there is one.

Second, the information is in a string on the server, and you will want to use it as a string in your app. Why convert it to a csv and back again? It will be much quicker and easier if you skip those steps. Ajax is the way to go here - ftp is pretty much an obsolete technology now.

Actually, using FTP is relatively simple, if you have an FTP client. But JS was built to "talk" HTTP and you have to have an external JS library to make FTP work There is one in the Cordova world (https://github.com/macdonst/FtpClient). We have not tried it and cannot vouch for it, so caveat emptor.

If you are connecting to your own server, implementing a PHP (or .Net, whatever) script will be much easier a task. If you use your own server, pay attention to security; there are lots of rogue actors on the net that will trash an unprotected site in seconds. If, however you have client demands or are working with a commercial FTP site and have no choice but to use FTP, grab that library. The good thing is that there are lots of FTP server apps out on the web (I have used Filezilla and it's great) so your code only involves the JS client,

I've done both, so here's a perspective: If you're asking for FTP because you think it's the way to go for file transfer, think again. But if the project has a hard requirement for FTP, dive in and keep in touch. (Comments from Lee Church).

Can I access a database on my server, such as MySQL, Access, Oracle, etc.?

The only database that runs locally on mobile devices is SQLite. If you want to get information from a server database to your device, you have a couple of choices:

  • Import the data into an SQLite database and include it with your project.
  • Have a listener program on a port on your server. Use AJAX calls from your app to the listener program. The listener program can then access the database on the server and return the requested information.

Can I read and update an Excel spreadsheet?

Since Excel does not run on mobile devices, it (and the spreadsheet itself) need to be running on a server.

You'll need a program on the server to read and update the Excel spreadsheet, that can also communicate with your mobile app, much like with databases.

What can't I do?

For things like Bluetooth, microphone, serial comms, you'll need to use VoltBuilder. VoltBuilder lets you run your AppStudio app as a native application. It has plugins which let you use native API functions.

Tell me more about Bluetooth!

Using VoltBuilder, it's practical to use Bluetooth.

  1. JavaScript/HTML5 will never be able to talk to the BT stack directly. That takes native code.
  2. To use native code, you need to build a native app. VoltBuilder has a nice way of doing this, using plugins. AppStudio works well with VoltBuilder, and there is a Bluetooth plugin for VoltBuilder.
  3. VoltBuilder makes it easy to compile AppStudio + Plugin apps.

You can develop and test the rest of your app normally - just the Bluetooth dependent parts will need testing with VoltBuilder.

Can I print to a Bluetooth printer?

Yes. There is no native support in JavaScript, and different printers need different control codes. It can be done by using a third-party app that isolates your app from the complexities of supporting multiple printers. Create an HTML document as a file on the device. The the user invokes the printer app and prints the file. An example app for this is PrinterShare. This is not perfect (it's a bit complicated) but it produces great-looking output and once the app has produced the HTML file we're done. If you have lots of time and $$ you can write your own printer routine.

There are also Bluetooth printer libraries available as Cordova Plugins, but only a few printers are supported.

What about hardware specific features?

Most hardware features are available. The Camera, Compass, GPS and Accelerometer are, but it is not possible to vibrate the phone. Once again, VoltBuilder comes to the rescue.

How do I handle different screen sizes?

Devices come in many different screen sizes, from small phone to large tablet. The devices can be positioned in portrait or landscape rotation: you can decide to support one or both. Use the Orientation control to help here.

In most cases, simply scaling the controls on the form will give poor results. The best way to do this is to detect the screen size on startup and adjust the sizes and positions of your controls. There's a handy .resize(left, top, width, height) function to help you do this. Scaling does not work, since buttons will look oddly sized, images will have incorrect aspect ratios, and poor use will be made of the screen real estate.

Controls can have their bounds set as percentages. For example, you could set a TextArea to be 80% of the width and 50% of the height of the screen, positioned 10% from the left and 30% from the top.

Another thing to keep in mind is that tablet apps often need a different approach than phone sized apps. The extra space on the screen can be used to display a list of items (such as email messages) while the main part of the screen can be used to display the selected message. This wouldn't fit on a phone sized screen, but results in a more usable app on tablets.

(If you do want to use simple scaling, there is a sample on the web board. Have a look at Zoom by winvetpro.)

What about retina displays?

Retina displays work just like regular displays: your program will run the same on either, filling the entire screen. If you are using a retina display, fonts will be drawn using the higher resolution, producing crisper text. If you supply hi res versions of images, they will be displayed instead of the low res version.

My phone is 1920x1080. Why can't I address all the pixels?

While your phone may physically have that many pixels, the operating system treats them as doubled or even tripled pixels. You'll only be able to address 640x360 or 960x540, depending on the device. The operating system will take care of mapping the pixels to their actual location. This is actually very good news: it means that you won't have to drastically change your app each time it runs on a new device.

How can I detect when the app is closing?

You can't. Apps close when you start another app. A app with a Close or Quit button will actually get rejected from app stores for violating user interface guidelines. Starting the app again will bring back the already running version (for VoltBuilder apps) and restart it from the beginning (for web apps) or if the device was shut down in the meantime.

The best technique is to constantly save the current state of the app in localStorage and SQLite. When the app restarts, check the last saved status in localStorage, go to the most recent form and fill in all the fields. Done right, it will look as though the app was never exited.

Can I use WinSock? UDP? sockets?

AppStudio has support for WebSockets built in. It's the easiest way to do this and works well with current web security practices.

WinSock, UDP and older style sockets can be done using Cordova Plugins. If there is one that fits your needs in the list of Cordova Plugins, It will be easy to use with AppStudio. If the plugin is not yet compatible with https://volt.build/docs/approved_plugins/, you will need to use the full Cordova API.

What about proxys and firewalls?

AppStudio needs to contact the appstudio.dev server on startup to verify your serial number. You will need to make sure your system allows for this. The address is

https://www.nsbasic.com

.

If you are routing through a proxy, make sure to add localhost, 127.0.0.0 to the ignore list. AppStudio uses this for local testing.

Can I read barcodes?

Yes. There are several ways to do so. Check out this blog post: How to read barcodes.

Support and Documentation

How is it supported?

AppStudio is supported by email and on a very active [web board]. We post bug fix updates to our ftp site on a regular basis. Check the web board and our blog for the latest announcements.

Is there an option for Premium Support?

Yes. For a monthly fee, you can get Premium Support which includes direct access to the developers, fast turnaround time and much. See our Support Policies.

What documentation is included?

There is a wiki that contains the complete documentation on the IDE and the language. It is included with the product for offline use. Short summaries of most functions are in on line help. There are also tech notes and tutorials.

Is the a hardcopy Handbook?

We got rid of hard copy handbooks several years ago. We were reluctant to do so, but the seachability and linking that a Wiki provides is essential once you get used to it.

Not having to worry about page count let us expand the amount of documentation we have by quite a bit.

There are utilities which can print out a Wiki, but they tend to be cumbersome.

Distributing your app

Can I distribute my applications?

Yes. You may distribute your apps, with no further royalties or costs. AppStudio apps can be distributed without going through Apple's iTunes store or Google's Marketplace. This is great news: setting up an app in the iTunes store can be more challenging than writing an app in AppStudio. Instead, apps can be distributed over the web. Apps can be sold by controlling who is allowed to access the app.

But I want to distribute my app through the App Store!

If you want to distribute through the App Store, you can compile the project using VoltBuilder. Submitting to the iOS App Store Submitting to the Google Play and Amazon Stores

Do I need a Mac to distribute through the App Store?

No. VoltBuilder takes care of this for you. As part of the build process, VoltBuilder will upload your app to Apple's iTunes Store.

How can I protect my code?

There is an option to obfuscate in the Deploy step: this makes it more difficult for people to look at your code. Third party utilities exist with improved obfuscation, which will require more sophisticated tools to look at.

For improved security, compile your app using VoltBuilder. This will result in an executable. It is still possible, however, to unpack the executable and examine the source files.

Any executable, on any platform, can be reverse engineered with sufficient effort.

Licensing and Upgrades

Where can I buy it? What does it cost?

AppStudio for a single developer is available for a one time fee of $199 USD or by subscription directly from NSB Corporation's order page.

What is your upgrade policy?

Point upgrades are free. We reserve the right to charge for major new versions - that gives us an incentive to make something really special.

I want to run it at the office, on my laptop and at home. How many licenses do I need?

One, so long as you are the only one using it. The license is to a single developer. You can even run a mix of Windows and Mac computers, up to a maximum of three computers.

I have a number of developers. Do I have to buy licenses for all of them?

If you have a single location with many programmers, consider an Enterprise License: unlimited programmers at one location for a flat price.

I would like to use AppStudio in my classroom. What license do I need?

The Educational License is a perpetual classroom license. Students will be able to use personal copies for the duration of the semester they are attending the course: the reacher can reuse the license in the next term with a new class of students. If you are a teacher and would like a free version, send us your credentials.

The demo period has expired, but I'm not done testing.

You have 3 options:

1. Change the system date when you start the demo. It only checks it on start, so you can put it back right away.

2. Take advantage of our 30 day no hassle money back. Buy it and if it doesn't work for you, let us know and we refund right away.

3. Run on another machine.

How can I change/cancel my subscription?

You can do so here: https://wiki.appstudio.dev/Subscriptions

Other

Are you available for contract work?

Yes, we are available for contract work. AppStudio comes first, of course, but working on real projects keeps the guys here in touch with the real world. Send a message to us if you are interested.

Who is NSB Corporation?

NSB Corporation was formed in 1993 to create applications for developers using hand held computers. The initial product, NS BASIC for the Newton, started shipping in 1994 and was one of the top selling packages on the Newton platform. The product has been continuously updated since its first release. In late 1997, NSB released its next product, NewtCard, a product inspired by Apple's HyperCard application. NewtCard has probably garnered more "Best of" awards than any application produced for hand held computers to that point.

NS Basic/Newton and NewtCard are two of the three software products to garner a "First Class Award" from Mobile Computing. NS Basic/CE was first released in 1998. It has been continuously been enhanced and improved since that date. Apart from the free eMbedded tools from Microsoft, it is the most widely used dev tool for Windows CE.

NS Basic/Palm was released in 2000. It became the most popular development tool for those devices.

Over the years, NSB Corporation has developed a large body of special expertise in creating development environments for hand sized computers. Combining effective user interfaces for small, pen based screens with efficient use of resources built into the ROM, NSB's applications are surprisingly powerful, small, and easy to use.

You can contact NSB Corporation by email at support@appstudio.dev, phone at 1 888 672-2742 (416 264-5999) or fax at 416 264-5888.

So what does the "NS" stand for, anyhow?

Nice & Smart.