Code example for AbsoluteLayout.LayoutParams

0
    	//linearLayout = (LinearLayout) findViewById(R.id.lista_gauge); 
    	LinearLayout inner = new LinearLayout(this);
    	 
    	final WebView webViewDynamic = new WebView(this);
        webViewDynamic.setId(chart.getId());
        webViewDynamic.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT, 0, 0));
         
        inner.addView(webViewDynamic);
        android.view.ViewGroup.LayoutParams params = linearLayout.getLayoutParams();
        params.height = 100;
 
        params.width=params.WRAP_CONTENT;
        linearLayout.setLayoutParams(params);
        //linearLayout.setLayoutParams(new LinearLayout.LayoutParams(LayoutParams.FILL_PARENT, 100)); 
        linearLayout.addView(inner);
         
       // linearLayout.addView(webViewDynamic);  
        webViewDynamic.setOnTouchListener(this);
        webViewDynamic.getSettings().setPluginsEnabled(true);
        webViewDynamic.getSettings().setJavaScriptEnabled(true);
Contextual code suggestions in your IDE  Get Codota for Java