我正在尝试测试我为iPhone创建的应用程序,但我在设备上测试时遇到问题.我创建了配置文件以及完成这么简单的任务所需的其他数百万个步骤,但是我收到以下错误:
-debugtrack -monodevelop-port 10000 -connection-mode usberror MT1107: Application failed to launch
Run Code Online (Sandbox Code Playgroud)
我尝试在我的Xcode上创建一个测试应用程序,但也无法这样做,并收到以下错误消息:
Could not launch “test” NotFound
Run Code Online (Sandbox Code Playgroud) 所以我的布局包含我的布局中定义的TableLayout
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:background="@drawable/defaultBackground_vert"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:id="@+id/mainLayout">
<TableLayout
android:minWidth="25px"
android:minHeight="25px"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/table">
</TableLayout>
</LinearLayout>
Run Code Online (Sandbox Code Playgroud)
我在我的代码隐藏中访问它并尝试向表行添加一个按钮并将该tablerow添加到表中:
private TableLayout _table
private Button _button
.
.
.
_table = FindViewById<TableLayout>(Resource.Id.table);
_button = new Button(this){Text = "<"};
_button = new ViewGroup.LayoutParams(ViewGroup.LayoutParams.MatchParent, ViewGroup.LayoutParams.MatchParent);
var tableRow = new TableRow(this);
tableRow.AddView(_button, 0);
_table.AddView(tableRow, 0);
Run Code Online (Sandbox Code Playgroud)
问题是当我运行我的应用程序时tableRow不会显示.