从命令行启动 Blackberry 应用程序

发布于 2024-11-07 07:51:46 字数 331 浏览 0 评论 0原文

我正在尝试使用 fledgecontroller 从命令行启动我的应用程序,但是当我执行以下行时,没有任何反应,没有错误。9800 模拟器不会从主屏幕更改为我的应用程序。这是为什么?

fledgecontroller /session=9800 /execute=LoadCod("C:\\Documents and Settings\\Abs\\workspace2\\bb\\deliverables\\Standard\\6.0.0\\bb.cod")

另外,我是否可以将参数传递给我的应用程序?这对测试确实有帮助。

感谢大家的帮助

I am trying to make use of the fledgecontroller to launch my app from the command line but when I execute the following line, nothing happens, no errors.The 9800 simulator doesn't change from the homescreen to my app. Why is that?

fledgecontroller /session=9800 /execute=LoadCod("C:\\Documents and Settings\\Abs\\workspace2\\bb\\deliverables\\Standard\\6.0.0\\bb.cod")

In addition, is there anyway I can pass a parameter to my app? It will really help with testing.

Thanks all for any help

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

呢古 2024-11-14 07:51:46

LoadCod 会将应用程序加载到模拟器上,但不会实际启动应用程序。为此,您仍然需要通过传递键盘和轨迹球或触摸事件来单击应用程序图标(再次使用 fledgecontroller)来手动启动它。或者,您可以尝试将应用程序设置为在启动时加载(它是应用程序描述符文件中的一个复选框);但这是否有效将取决于您的应用程序正在做什么。

我这样做的方法是通过隐藏主文件夹上的所有其他应用程序/图标来预先设置模拟器会话。然后,当加载 cod 时,它将成为唯一的应用程序,因此您只需发送一个单击事件即可启动它。但如果您想更彻底,您还必须发送轨迹球或键盘事件来选择应用程序。

将参数传递给应用程序的唯一方法是在应用程序描述符文件(在编译时包含)中设置参数值。如果您需要一些参数来指定它应该是一个测试实例,您可以编译两个版本 - 一个用于没有参数集的生产,另一个用于具有参数集的测试。然后您只需通过 fledgecontroller 加载测试版本。

如果您根本没有看到应用程序加载到模拟器上,您还可以尝试将 \\ 符号替换为 / 符号(我认为 fledgecontroller 处理正斜杠通常和内部;我不知道为什么,因为它是一个明确的 Windows 程序,但你有它......)

LoadCod will load the application onto the simulator, but will not actually start the app. In order to do that, you'll still have to manually start it by passing the keyboard and trackball or touch events to click the app icon (using fledgecontroller again). Alternatively, you could try setting the app to load on startup (it's a checkbox in the app descriptor file); but whether that will work will depend on what your application is doing.

The way I do it is to set up the simulator session beforehand by hiding all of the other applications/icons on the home folder. Then when the cod is loaded it will be the only app, so you can just send a click event to start it. But if you want to be more thorough you'll also have to send trackball or keyboard events to select the app.

The only way to pass a parameter to the app is to set the parameter value in the app descriptor file (which gets included at compile time). If you need some parameter to specify that it should be a testing instance, you could compile two versions - one for production that does not have the param set, and one for testing that does. Then you would just load the testing version via fledgecontroller.

If you aren't seeing the application getting loaded onto the simulator at all, you can also try replacing your \\ symbols with / symbols (I think fledgecontroller deals with forward slashes usually and internally; I'm not sure why since its an explicitly windows program, but there you have it...)

醉生梦死 2024-11-14 07:51:46

我几乎每天都在 8300 模拟器上使用这种方法。重要的参数(可以通过分析 Eclipse 中的调试设置获得)是 /app-param=launch=MyBBAppName

我认为您询问的后来的模拟器不允许您指定在启动时加载的应用程序。

如果您需要能够执行此操作,一种解决方法是将应用程序创建为“启动时加载”应用程序,然后当模拟器启动时,您的应用程序将启动。我目前在后来的模拟器上使用这个解决方法。

I use this method almost daily on the 8300 simulator. The important parameter (which you can get by analysing the debug setup in Eclipse) is /app-param=launch=MyBBAppName.

I think the later simulators, which you ask about, do not allow you to specify an app to load on startup.

If you need to be able to do this, one workaround would be to create the app as a "load at startup" app, then when the simulator boots up, your app will start. I use this workaround on the later simulators at the moment.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文