TypeError:Ti.App.getArguments不是函数

时间:2019-05-09 09:51:54

标签: titanium appcelerator

我在钛合金鉴赏室的Android应用中使用Ti.App.getArguments(),但每次都遇到以下错误。Getting error given in image

1 个答案:

答案 0 :(得分:0)

如您在API文档https://docs.appcelerator.com/platform/latest/#!/api/Titanium.App-method-getArguments中所见,getArguments()函数仅在iOS上可用,并从您正在为Android编译的命令行参数中判断。 Android的解决方案是: On Android, fetch the Ti.Android.rootActivity object and read its intent property to retrieve the parameters used to launch the application activity.