The IDE has several powerful features which can help you concentrate on writing your code and building your application.
I'm listing here some of the less obvious features:
-
Ctrl + Space = auto complete
Pressing Ctrl + Space activates the auto complete feature which will then show you a list with the available keywords, variables, modules, methods, subs, properties and fields.
The list includes a description for most items.
Pressing Ctrl + Space after typing the first few letters will usually select the required item automatically.
-
Tool tip information - while writing methods parameters, a tool tip will be opened with the method signature and description.
The tool tip might hide some important code that you now need.
You can hide it by pressing escape. You can also turn it almost invisible by pressing the ctrl key. Another press will return it to be fully opaque.
Logs - The Logs tab displays the device built-in logs. These logs are very useful for debugging. You can log messages with the Log keyword.
In order to start displaying the logs you press on the Connect button.
The logs can be filtered and then you only see messages generated by Basic4android or your application.
Note that if you have more than one device connected you can switch to a different device by pressing on the Connect button.
Designer generated members tool - This tool allows you to add the declaration code for the designer views and to add event subs.
Note that you only need to declare views that you intend to access by code.
Nothing will happen if you select an existing item (there will be no duplicated code).
To open this tool choose - Tools - Generate Members (from the designer form).
Background compilation - Pressing Alt + 3 will compile and install your application while keeping the IDE responsive. The status bar at the bottom of the screen displays the progress of the process and when the installation is completed.
A short sound will notify you if the process failed. In that case you may need to compile regularly (F5) in order to see the error message (it depends on the type of error).
Working with multiple connected devices - In many cases you have more than one device connected. For any operation that
starts a connection you will be shown the list of connected device and you will choose the target device.
If you compile in the background the last device will be used again. This is usually more convenient than compiling in the foreground and selecting the target device each time.
Designer -
Duplicate - You can duplicate any view by selecting the view and then choosing Tools - Duplicate View. If the view has child views then all its child views will be duplicated as well.
Export as zip - Export as zip option creates a zip file with all the required project files. This is useful when you want to share your project with others or create a backup. It is located under Files menu.
Clean Project / Clean Unused Files - Clean project deletes all generated files. These are files that are generated during compilation.
Clean unused files deletes files that are located in the Files folder but are not used by the project. A list of unused files with the option to cancel the deletion will appear.
Run AVD Manager - The AVD manager allows you to create and start emulators. This menu opens the manager. Note that there is no need to keep the AVD manager open after starting an emulator.