Need help using ((ImageView) findViewById.getView (). ( SetImageBitmap (bmp); in a fragment


I'm having trouble using the following code in a fragment activity:

((ImageView) findViewById.getView().(;

I've tried using:

((ImageView) this.getView().findViewById(;

but this doesn't work. App crashes

if its imageView1 is in main Activity layout than try this

 ImageView myImg=(ImageView)findViewById(;

if not then

ImageView myImg=(ImageView)view.findViewById(;

view may be same as place main layout content or after inflate so as per inflate view may change into linearlayout or relativelayout or View.