Answers for "set cardview margin programmatically"

0

set cardview margin programmatically

ViewGroup.MarginLayoutParams layoutParams = 
                           (ViewGroup.MarginLayoutParams) myCardView.getLayoutParams();
    layoutParams.setMargins(0, 0, SystemHelper.dpToPx(2), 0);
    myCardView.requestLayout();
Posted by: Guest on August-30-2020

Browse Popular Code Answers by Language