title: How to convert an integer value into floating point in java?
body: <p>I am getting an integer value in my android application.I want to convert it into floating point number which is in this format</p>
  
  <blockquote>
    <p>"0.xyF"</p>
  </blockquote>
  
  <p>.I tried lot of methods.I know its simple but i am confused.Please help.</p>
  
  <p>I am passing a value from one activity to another using putExtra.So in the second activity i have to convert it to float for setting the value as verticalMargin for my dialog window.I used this line for getting the value in second activity.</p>
  
  <pre><code>int data = getIntent().getIntExtra("value", 7);
  </code></pre>
  
  <p>This is used for setting the vertical margin.</p>
  
  <pre><code>wlp.verticalMargin = "the converted floating point number";
  </code></pre>