• DİKKAT

    DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
    Altın Üyelik Hakkında Bilgi

dde sunucu makro yardımı

  • Konbuyu başlatan Konbuyu başlatan torik52
  • Başlangıç tarihi Başlangıç tarihi
Katılım
7 Ekim 2015
Mesajlar
82
Excel Vers. ve Dili
2007
sn arkadaşlar aşşağıdaki makroyu açıklayabilirmisiniz.saygılarımla


**'if you wish to automatically begin recording information when the workbook
**'is opened; place this procedure into the "ThisWorkbook" class module.
**Private Sub Workbook_Open()
****** BeginRecordingUpdates
**End Sub
**
**'the remainder of this code goes into a standard module
**'simply run "BeginRecordingUpdates" to start recording
**Private Const MyLinksName As String = "MT4|BID!USDJPYm"
**Private Const RecordToSheetName = "Data"
**
**Sub BeginRecordingUpdates()
****** ThisWorkbook.SetLinkOnData MyLinksName, "RecordUpdates"
****** ThisWorkbook.Sheets(RecordToSheetName).Cells.ClearContents
**End Sub
**
**Sub RecordUpdates()
****** Dim r As Long
**
****** With ThisWorkbook.Sheets(RecordToSheetName)
********** r = Application.WorksheetFunction.CountA(.Columns(1)) + 1
********** If r > 65535 Then StopRecordingUpdates
********** .Cells(r, 1).Value = ThisWorkbook.Sheets("DDE_Link").Range("A1").Value
********** .Cells(r, 2).Value = Now
****** End With
**End Sub
**
**Sub StopRecordingUpdates()
****** ThisWorkbook.SetLinkOnData MyLinksName, ""
**End Sub
 
Geri
Üst