I have studied Shortcut creating ,and have followed the example code. It has error code "Unreachable Code detected."
I have adding some code in manifest file.
You placed a code after a RETURN. It means that code will not be executed.
B4X:
Private Sub CreateIconFromBitmap() As Object
Dim ic As JavaObject
Return '<<<<<<<---------------------------THIS IS THE PROBELM
'ic.InitializeStatic("androidx.core.graphics.drawable.IconCompat").RunMethod("createWithBitmap",Array(LoadBitmap(File.DirAssets,"android-icon-72x72.png")))
ic.InitializeStatic("androidx.core.graphics.drawable.IconCompat").RunMethod("createWithBitmap",Array(LoadBitmap(File.DirAssets,"Letter-S-icon.png")))
End Sub
You placed a code after a RETURN. It means that code will not be executed.
B4X:
Private Sub CreateIconFromBitmap() As Object
Dim ic As JavaObject
Return '<<<<<<<---------------------------THIS IS THE PROBELM
'ic.InitializeStatic("androidx.core.graphics.drawable.IconCompat").RunMethod("createWithBitmap",Array(LoadBitmap(File.DirAssets,"android-icon-72x72.png")))
ic.InitializeStatic("androidx.core.graphics.drawable.IconCompat").RunMethod("createWithBitmap",Array(LoadBitmap(File.DirAssets,"Letter-S-icon.png")))
End Sub