I want to loop through the quotation of the stock, not just a single day "2013-07-14", as I want to update the stock quotation by a factor. how do I write it? thanks
Set Amibroker = CreateObject("Broker.Application")
'Set stocks = Amibroker.stocks
strTicker = "3336.HK"
Set Stock = Amibroker.stocks(CStr(strTicker))
If Not Stock Is Nothing Then
With Stock
.FullName = "巨騰"
Set quotation = .quotations("2013-07-04")
O = quotation.Open '3.51
H = quotation.High '3.57
L = quotation.Low '3.28
C = quotation.Close '3.3
V = quotation.volume ' 7130000
Debug.Print O & " " & H & " " & L & " " & C & " " & V
End With
End If
Amibroker.RefreshAll
End Sub
'Set stocks = Amibroker.stocks
strTicker = "3336.HK"
Set Stock = Amibroker.stocks(CStr(strTicker))
If Not Stock Is Nothing Then
With Stock
.FullName = "巨騰"
Set quotation = .quotations("2013-07-04")
O = quotation.Open '3.51
H = quotation.High '3.57
L = quotation.Low '3.28
C = quotation.Close '3.3
V = quotation.volume ' 7130000
Debug.Print O & " " & H & " " & L & " " & C & " " & V
End With
End If
Amibroker.RefreshAll
End Sub