Sub Get_1_Planet(JD As Double, p_num As Int) As Double
Dim xx(7) As Double
Dim serr As StringBuilder
Dim iflag As Int
Dim ret_flag As Int
Dim dss(7) As Double
Dim dss1 As StringBuilder = Null
serr.Initialize
For i = 1 To 255
serr.Append("0")
Next
iflag = 2 + 256
'this was suggested before I replaced StringBuffer with StringBuilder
'Select the Reflection Library
'Dim r As Reflector
'ret_flag = swe1.swe_calc_ut(JD, p_num, iflag, xx, r.CreateObject2("java.lang.StringBuffer",Array As Object(serr),Array As String("java.lang.String")))
ret_flag = swe1.swe_calc_ut(JD, p_num, iflag, xx, serr)
Dim rsGeoPos(2) As Double
rsGeoPos(0) = 78.9833333333333
rsGeoPos(1) = 10.2166666666667
rsGeoPos(2) = 0
ret_flag = swe1.swe_rise_trans(JD,0,dss1,0,1,rsGeoPos(0),0.0000,0.000,dss ,serr)
Return xx(0)
End Sub
Can some one please let me know what am i doing wrong?
Dim xx(7) As Double
Dim serr As StringBuilder
Dim iflag As Int
Dim ret_flag As Int
Dim dss(7) As Double
Dim dss1 As StringBuilder = Null
serr.Initialize
For i = 1 To 255
serr.Append("0")
Next
iflag = 2 + 256
'this was suggested before I replaced StringBuffer with StringBuilder
'Select the Reflection Library
'Dim r As Reflector
'ret_flag = swe1.swe_calc_ut(JD, p_num, iflag, xx, r.CreateObject2("java.lang.StringBuffer",Array As Object(serr),Array As String("java.lang.String")))
ret_flag = swe1.swe_calc_ut(JD, p_num, iflag, xx, serr)
Dim rsGeoPos(2) As Double
rsGeoPos(0) = 78.9833333333333
rsGeoPos(1) = 10.2166666666667
rsGeoPos(2) = 0
ret_flag = swe1.swe_rise_trans(JD,0,dss1,0,1,rsGeoPos(0),0.0000,0.000,dss ,serr)
Return xx(0)
End Sub
Can some one please let me know what am i doing wrong?