setting margin of a TableRow issue
<p>I have the following code, which tries to set the margin:</p>

<pre><code>TableRow tr = new TableRow(this);
                    TableLayout.LayoutParams tableRowParams=
                          new TableLayout.LayoutParams
                          (TableLayout.LayoutParams.FILL_PARENT,TableLayout.LayoutParams.WRAP_CONTENT);

                          int leftMargin=20;
                          int topMargin=50;
                          int rightMargin=0;
                          int bottomMargin=50;

                         tableRowParams.setMargins(leftMargin, topMargin, rightMargin, bottomMargin);
                         tr.setLayoutParams(tableRowParams);

 TextView name = new TextView(this);
                          name.setText(Html.fromHtml(venues.get(j).name + "&lt;br&gt;&lt;br&gt;" + venues.get(j).getFullAddress()));
</code></pre>

<p>However this doesn't set the margin. What am I doing wrong here?</p>
