Announcement

Collapse
No announcement yet.

ESignal / Turbofeed Automation

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    dot net .dll location

    YEAH!!!

    I got it to work!

    The problem I was having was this:

    The bridge uses a #using directive to locate the .net dll file
    #using "dotNetAssembly\bin\dotNetAssembly.dll"

    problem is though, any path you use is ignored as C++ uses the
    /libpath compiler option to search for other assemblies.... even adding the right dir with libpath has no effect, I get a class not registered error after calling the dll in EFS

    If i put the .Net dll in the default eSignal directory it get located and calls everything just fine.

    So, is there anyway I can specify where this dll is located? or am I just going to have to put it in the eSignal dir with everything else???

    Thanks for the help on this guys

    Comment


    • #17
      Awesome. Glad you got it working.

      As for the DLL location, I have only started poking around with .Net stuff in general so take anything I say here with a grain of salt. In general Windows uses a common search path when searching for DLLs to load. It starts with the apps home directory, if not there it checks in the \Windows\System32 directory (which is why almost all 3rd party DLLs end up in there).

      On the other hand, COM DLLs are often registered in the Windows registry. Registered DLLs tell the system where they are located so Windows can find them anywhere in the system. You can register a COM DLL yourself using regsvr32.exe (part of Windows). If you want to try and register the DLL in its "normal" location, whatever that is, you can type something like the following into a console window:

      regsvr C:\whatever\dotNetAssembly\bin\dotNetAssembly.dll

      Again, if this breaks something, don't come after me. I have had to use that before for some other projects I was working on, BTW, just not with a dotNetAssembly.dll.

      Comment


      • #18
        Array Passing

        Ok, now I seen to be having trouble passing arrays of data... The call works fine but I dont get the data I expect on the other side.... I took each element of the array and wrote it to a text file, here is what I get:

        EFS:
        var d = new DLL("I:/eSignalDll/Bridge.dll");
        d.addFunction("test", DLL.INT, DLL.CDECL, "bridge_function_array", DLL.FLOATARRAY, DLL.INT);

        called as follows:
        MyArray = new Array( 1,5,2,20,99 );
        var v = d.call("test", MyArray, 5);

        C++ function sig:
        __declspec(dllexport) int __cdecl bridge_function_array(int *values, int len)

        and I end up with:
        1065353216
        1084227584
        1073741824
        1101004800
        1120272384

        Interesting... Anyone have any ideas on this???

        Comment


        • #19
          One of these things is not like the other.

          d.addFunction("test", DLL.INT, DLL.CDECL, "bridge_function_array", DLL.FLOATARRAY, DLL.INT);

          __declspec(dllexport) int __cdecl bridge_function_array(int *values, int len)

          Comment


          • #20
            So whats the answer...

            So if the C++ is as described...

            What would the proper EFS be?

            Or do I have to change the C++ statement to something else...

            Thanks

            Comment


            • #21
              Match a DLL.FLOATARRAY in the EFS with a float* in C/C++.

              Comment


              • #22
                ActiveX vs EFS

                DionLoy,

                I would rather use the ActiveX Control to pull realtime quotes from the Data Manager than use EFS to push it to a dll. However, the reason I am using EFS is I have access to the library of studies eSignal provides. If I just pulled tick and other trade related data from the ActiveX, I would have to program my platform with the ability to apply study formulas, etc. to the data to do analysis. This wouldn't be a problem, except I don't know where to find a library of formulas for each type of study, it would be nice if there was a dll somewhere you could pass in an array of values to and return the graphable study values. Is there anything like that out there?

                Thanks,
                Gavin


                Originally posted by DionLoy
                Zapbbx,

                I would suggest the ActiveX API reather than the EFS API.

                You can write your program to interface with the ActiveX API data control in eSignal with your .NET code

                ActiveX gives you a much richer set of data than would EFS, and much more control over it too.

                I don't believe you can control playback through the ActiveX though, but you can retrieve level1, level2 and historical quotes as well as all ticks and bid/ask quotes in realtime. It should technically also happen faster than in EFS as EFS is interpreted, but the ActiveX API is all native code.

                Comment


                • #23
                  Actually, it seems like what you and GenSpoo are doing in the thread below matches your needs?

                  Comment

                  Working...
                  X