Private Declare PtrSafe Function CashValue Lib "D:\NinjaTrader 8\bin\NinjaTrader.Client.DLL" (ByVal lpAccountName As String) As Double
Private Sub CommandButton1_Click()
dbCashValue = CashValue("")
Range("A1").Value = dbCashValue
When I click on CommandButton1, it stops on the line "dbCashValue = CashValue(""), and I get an error msg (see attached).
Any ideas what I'm doing wrong?
Comment