Normsinv funciton

  • Thread starter Thread starter Sunil Pradhan
  • Start date Start date
S

Sunil Pradhan

I want to use ms excel function normsinv to calculate some value in vba?

how can i use?
 
mike, it did not work. I am giving down the complete code to calcuate some
value.

Private Sub CommandButton1_Click()
Dim val As Single
Dim res As Single
Dim myvalue As Single

val = CSng(TextBox1.Value)

Sheet1.Cells(a1).Value = val

myvalue = WorksheetFunction.NormSInv(Range("A1").Value)

TextBox2.Value = myvalue + 1.5


End Sub

pls help. this runs on form.
 
1. Sheet1.Range("a1").Value = val
2. what value are you inserting into A1? should be >=0 and =<1 according to
Help since this is probability

HIH
 
Hi Jarek,

It worked, but I want some more. I do not want to transfer the value to
cell, instead I want to use withing the code. Pls make me mroe comfortable
doing this.

Sunil


Private Sub CommandButton1_Click()
Dim val As Single
Dim res As Single
Dim myvalue As Single

val = CSng(TextBox1.Value)

Sheet1.Range("a1").Value = val

myvalue = WorksheetFunction.NormSInv(Range("A1").Value)

TextBox2.Value = myvalue + 1.5

End Sub
 
Back
Top