[FREE] 🌍 Country Picker Extension – Offline

🧩 CountryPicker

An extension for MIT App Inventor 2.
Professional offline country picker with Material 3 UI and 250+ built‑in countries.

:memo: Specifications


:package: Package: com.jamarcountrypicker.io.countrypicker
:floppy_disk: Size: 44.49 KB
:mobile_phone: Minimum API Level: 14
:date: Updated On: 2026-07-23T22:00:00Z
:laptop: Built & documented using: FAST v6.0.0

Events:

CountryPicker has total 5 events.

1. CountrySelected

Fired when a country is selected.
CountrySelected

Parameter Type
name text
code text
phoneCode text
flag text

2. SearchChanged

Fired as the user types in the search box.
SearchChanged

Parameter Type
query text

3. PickerOpened

Fired when the picker is opened, with the display style.
PickerOpened

Parameter Type
style text

4. PickerClosed

Fired when the picker is closed or dismissed.
PickerClosed

5. ErrorOccurred

Fired when an internal error occurs.
ErrorOccurred

Parameter Type
message text

Methods:

CountryPicker has total 8 methods.

1. Show

Show the country picker with the given style.
Show

Parameter Type
styleString PickerStyle (helper blocks)
  • Enums for PickerStyle: Default, BottomSheet, Dialog, FullScreen

2. GetAllCountries

Returns all countries as a list of lists.
GetAllCountries

  • Return type: list

3. SearchCountries

Search countries by name, code or dial code.
SearchCountries

  • Return type: list
Parameter Type
query text

4. GetCountryByCode

Get country by exact ISO alpha‑2 code.
GetCountryByCode

  • Return type: list
Parameter Type
code text

5. GetCountryByPhone

Get first country matching the given dial code.
GetCountryByPhone

  • Return type: list
Parameter Type
phone text

6. SetDefaultCountry

Set the default country code.
SetDefaultCountry

Parameter Type
code text

7. SetTheme

Change the theme at runtime.
SetTheme

Parameter Type
mode ThemeMode (helper blocks)
  • Enums for ThemeMode: System, Light, Dark

8. ClosePicker

Dismiss the country picker if it is showing.
ClosePicker

Designer:

CountryPicker has total 5 designer properties.

1. DefaultCountry

DefaultCountry

  • Input type: string
  • Default value: US

2. ThemeMode

ThemeMode

  • Input type: string
  • Default value: System

3. ShowFlags

ShowFlags

  • Input type: boolean
  • Default value: True

4. ShowSearch

ShowSearch

  • Input type: boolean
  • Default value: True

5. SortMode

SortMode

  • Input type: string
  • Default value: Alphabetical

Setters:

CountryPicker has total 5 setter properties.

1. DefaultCountry

ISO alpha‑2 code of the default selected country.
DefaultCountry

  • Input type: text

2. ThemeMode

App theme mode: System, Light, or Dark.
ThemeMode

  • Input type: text
  • Helper type: ThemeMode

3. ShowFlags

Whether to show country flags.
ShowFlags

  • Input type: boolean

4. ShowSearch

Whether to show the search bar.
ShowSearch

  • Input type: boolean

5. SortMode

Country list sort order.
SortMode

  • Input type: text
  • Helper type: SortMode
  • Helper enums: Alphabetical, DialCode

Getters:

CountryPicker has total 5 getter properties.

1. DefaultCountry

ISO alpha‑2 code of the default selected country.
DefaultCountry

  • Return type: text

2. ThemeMode

App theme mode: System, Light, or Dark.
ThemeMode

  • Return type: text

3. ShowFlags

Whether to show country flags.
ShowFlags

  • Return type: boolean

4. ShowSearch

Whether to show the search bar.
ShowSearch

  • Return type: boolean

5. SortMode

Country list sort order.
SortMode

  • Return type: text

:megaphone: Shoutout

A special shoutout to @JEWEL and @Taifun for their guide on adding Helpers (Dropdown Blocks). They shared it back in July 2025, and after a lot of experimenting, everything finally clicked for me a few weeks ago!:grinning_face_with_smiling_eyes:Doubts?

Thank you for taking the time to share your knowledge with the community—it has been incredibly helpful.

Downloads
com.jamarcountrypicker.io.countrypicker.aix (44.6 KB)

Happy building! :rocket:

6 Likes