Passing parameters to a python script using SL4A on Android?

I would suggest modifying the script to call getDialogInput import android app = android.Android() response = app. DialogGetInput(Title, Message, Default_Values). Result Then set whatever variable the script expects the parameters to be in to response Ive done this and also modified a script to get the android clipboard instead of taking input directly.

You could always make several versions of the script with hard coded parameters Hope this helps as im pretty new to python and sl4a.

I would suggest modifying the script to call getDialogInput. Import android app = android.Android() response = app. DialogGetInput(Title, Message, Default_Values).

Result Then set whatever variable the script expects the parameters to be in to response. Ive done this and also modified a script to get the android clipboard instead of taking input directly. You could always make several versions of the script with hard coded parameters.

Hope this helps as im pretty new to python and sl4a.

I formatted your code part in the question, next time, please do it (simply by marking the relevant code and pressing ctrl+k or cmd+k on a mac – MByD Aug 7 at 2:55 I will remember to do that in the future. At first when I looked at my answer I thought it happened magically. Thank you.

– Zer0_Interrupt Aug 7 at 3:05.

I am trying to get a Python script which I normally run on my PC to run on my Android phone (HTC Hero). I have SL4A running on my phone and have made a few tweaks to the Python script so that this does now run. The problem that I am having is how to pass parameters to the script.

I have tried creating a sh script in SL4A which called the python file with the parameters, but this didn't work. I have also tried using the app TaskBomb to call through to the python file, but again this doesn't work when parameters are supplied. When no params are supplied the file loads correctly, but when I add -h to the filename it says it can no longer find the python file I am calling.

Is anybody able to provide assistance with how to this?

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions