Hello to everybody,
I need to get a real path to the file as ParamStr (1).
Now I get the file path as follows: /external/file/11608
I need to get the file path: /external/documents/mytext.txt
My code:
Delphi-Quellcode:
procedure TfrmMain.FormCreate(Sender: TObject);
var
intent: JIntent;
param_intent: Jnet_Uri;
param_str: String;
begin
intent := SharedActivity.getIntent;
if intent <> nil then
begin
if TJIntent.JavaClass.ACTION_VIEW.equals(intent.getAction) then
begin
param_intent:= intent.getData;
param_str:= JStringToString(param_intent.getEncodedPath.toString);
Label4.Text := param_str;
end;
end;
end;
Thank you