
ShareService.EXTRA_FILE_PATHS: holds location references to local files on device. Sender name can't be relayed to receiver for Oreo & above Intent.putExtra(ShareService.EXTRA_SENDER_NAME, "Sri") //optional. PORT value is hardcoded for Oreo and above since it's not possible to set SSID with which port info can be extracted on Receiver side. Intent.putExtra(ShareService.EXTRA_PORT, 52287) //optional but preferred. Intent.putExtra(ShareService.EXTRA_FILE_PATHS, new String) // mandatory Intent intent = new Intent(getApplicationContext(), SHAREthemActivity.class)

To start SHARE mode, you need to pass an array of strings holding references of files you want to share along with port(optional) and sender name using an Intent to start SHAREthemActivity (library handles them based on targetSdkVersion)Īdded Android-8, OREO support with default Android Hotspot functionality which comes with password protected Hotspot and so Receiver has to explicitly key-in password, inline with SHAREit functionality.

Library also supports App (Android) to Web/Mobile Browser transfers if Receiver has no App installed.ĭownload the Working version from Play Store SHAREthem library facilitates P2P file sharing and transfers between devices using WiFi Hotspot.Īlso an attempt to simulate popular SHAREit App functionality and improvise it by supporting multiple receivers at one go
