rtd

OnTime TimeStamp Value Doubling Up

懵懂的女人 提交于 2019-12-24 19:33:16
问题 When you launch RecordData() sub (from OpenMe() sub) just once it works perfectly. Each time stamp log is consecutive with no doubles. Its when the workbook, re-opens again (due to OpenMe()/Close() subs) is when it creates a duplicate time stamp log. Can I re-arrange the OnTime so it doesn't schedule a double for its next session? Or separate the two OnTime's somehow so their independent? Dim NextTime As Double Sub RecordData() Dim Interval As Double Dim cel As Range, Capture As Range

RTD server in C# - where to start

穿精又带淫゛_ 提交于 2019-12-23 06:28:11
问题 I have RTD server in Excel, which pull data from thinkorswim application. I would like to pull data into C# instead. I have limited programming experience and therefore read multiple tutorials on RTD server implementation in C#, but most of the them are two advanced for me. So I wonder if anybody could suggest some introductory reading materials. Here is sample code that I am trying to implement: http://awkwardcoder.com/2014/01/24/excel-rtd-client-in-c/ I copied and pasted it into Visual

RTD server in C# - where to start

元气小坏坏 提交于 2019-12-23 06:27:13
问题 I have RTD server in Excel, which pull data from thinkorswim application. I would like to pull data into C# instead. I have limited programming experience and therefore read multiple tutorials on RTD server implementation in C#, but most of the them are two advanced for me. So I wonder if anybody could suggest some introductory reading materials. Here is sample code that I am trying to implement: http://awkwardcoder.com/2014/01/24/excel-rtd-client-in-c/ I copied and pasted it into Visual

.NET RTD/COM Excel Interop errors on one user's machine?

懵懂的女人 提交于 2019-12-23 02:19:38
问题 We built a .NET COM/Excel RTD Server (.NET Assembly) which has been in use for many years, on a variety of machines (i.e. we know it works, and our standard method for installing it works). We have a user who installed this RTD component on a different machine, and is having problems getting it to function smoothly. I believe the problem relates to the Interop.Microsoft.Office.Interop.Excel.dll somehow being either incompatible with this machine, or else improperly registered. Here are

How do I create an Excel automation add-in in C# that wraps an RTD function?

余生颓废 提交于 2019-12-21 06:05:27
问题 I have a working RtdServer-based automation add-in: How do I create a real-time Excel automation add-in in C# using RtdServer?. Creating a VBA wrapper is trivial: Function RtdWrapper(start) RtdWrapper = Excel.Application.WorksheetFunction.RTD("StackOverflow.RtdServer.ProgId", "", start) End Function This works. I have attempted to create a C# wrapper as follows: [ClassInterface(ClassInterfaceType.AutoDual)] public class RtdWrappers { private readonly Microsoft.Office.Interop.Excel.Application

Pause RTD server in Excel and save worksheet

本秂侑毒 提交于 2019-12-13 08:22:40
问题 I have worksheet which gets data from RTD server through the following formula: =RTD("tos.rtd", , "ASK", ".SPX150220C750") I would like to save the worksheet with above formula every 1 minute or so. The challenge is to pause VBA code and also make sure that before we save, the value in the cell is updated. I have tried the following code. Sub Archiving() For i = 0 To 4 Worksheets("Test").Activate Application.Sheets("Test").Copy Application.DisplayAlerts = False ActiveWorkbook.SaveAs Filename:

RTD in Excel VBA ( need to call data from rtd )

北慕城南 提交于 2019-12-13 08:18:39
问题 I was looking for the same answer where I need to call data from a RTD server Sub Test() Range("d1") = RTD("tickerplantrtdserver", , 4#2#1#6768#FUTSTK#N1#0#XX#Bid) End Sub When I extract data from Excel RTD("tickerplantrtdserver", , 4#2#1#6768#FUTSTK#N1#0#XX#Bid) it works fine and gives a number. 回答1: Try this: Range("d1") = [RTD("tickerplantrtdserver", , 4#2#1#6768#FUTSTK#N1#0#XX#Bid)] [] brackets are shortcut for Evaluate Function. So it can be written like this as well: Range("d1") =

Max31865 on Raspberry Pi setup

流过昼夜 提交于 2019-12-11 14:22:01
问题 I'm pretty new to coding. I'm trying to read a PT100 rtd via my Raspberry Pi 3. I read that I needed the Max31865 RTD amplifier to properly read the data because the resistances are so small. I am fairly certain I have it plugged in correctly. I'm using this code, only slightly editted. https://github.com/steve71/MAX31865 I'm getting two different outputs so far but it doesn't seem to correlate with anything I'm changing (The byte associated with the readTemp mostly) since I've run the same

Workbook, Save, Close, Re-Open (w/ TimeValue),Repeat

五迷三道 提交于 2019-12-11 08:57:18
问题 The macro runs with a button assigned to "CloseMe". It used to run for my needs but doesn't anymore (as I tried using this code in another workbook without success). Now it saves, closes, waits 10sec to reopen, but then closes right away. Sub CloseMe() Application.OnTime Now + TimeValue("00:00:10"), "OpenMe" ThisWorkbook.Close True End Sub Sub OpenMe() Application.OnTime Now + TimeValue("00:10:00"), "OpenMe" ThisWorkbook.Close True End Sub I need the code to save, close, wait 10sec to reopen,

.NET/COM Exception with IRTDUpdateEvent

梦想的初衷 提交于 2019-12-11 05:40:04
问题 We built an RTD Server assembly which has been in wide use for several years. (It was built with VS 2008, .NET 3.5 Target Runtime.) Today a user reported getting the following Exception: System.InvalidCastException: Unable to cast COM object of type 'System.__ComObject' to interface type 'Microsoft.Office.Interop.Excel.IRTDUpdateEvent'. This operation failed because the QueryInterface call on the COM component for the interface with IID '{A43788C1-D91B-11D3-8F39-00C04F3651B8}' failed due to