Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

How to Add Reference to System.Data

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

    How to Add Reference to System.Data

    Hi

    How do you add a reference to a System namespaces?

    I need to access to objects in System.Data.dll

    As System.Data is in the GAC I dont want to reference the dll file directly, C:\Windows\Microsoft.NET\assembly\GAC_32\System.Da ta\v4.0_4.0.0.0__b77a5c561934e089\System.Data.dll but rather use the instance in the GAC.

    The Add references dialog box does not give me an option to to access the GAC, I have tried browsing to C:\Windows\assembly where you can see contents of GAC but dialog does not allow me to add.

    Is there a file that I need to edit manually, as I see in the reference dialog there are 5 System Assemblies referenced.

    Thanks

    Mike

    #2
    Hello,

    This file path will always need to be added manually there is no way to hard code it like the System.dll is added. You must add the full file path with the references window.

    Let me know if I can be of further assistance.

    Comment


      #3
      I have figured it out.

      I have edited the Config.xml file in My Documents\NinjaTrader 7

      Add an element to the <References> tag as below.

      <References>
      <ArrayOfString xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
      <string>System.dll</string>
      <string>System.Core.dll</string>
      <string>System.Data.dll</string>
      <string>System.Drawing.dll</string>
      <string>System.Windows.Forms.dll</string>
      <string>System.XML.dll</string>
      <string>C:\Program Files (x86)\NinjaTrader 7\bin\NinjaTrader.Core.dll</string>
      <string>C:\Program Files (x86)\NinjaTrader 7\bin\WilsonORMapper.dll</string>
      <string>D:\\My Documents\NinjaTrader 7\bin\Custom\NinjaTrader.Vendor.dll</string>
      </ArrayOfString>
      </References>

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Taddypole, 04-26-2024, 02:47 PM
      4 responses
      25 views
      0 likes
      Last Post Taddypole  
      Started by ageeholdings, Yesterday, 07:43 AM
      1 response
      17 views
      0 likes
      Last Post whiterhino  
      Started by pickles1774, Today, 02:13 PM
      0 responses
      5 views
      0 likes
      Last Post pickles1774  
      Started by Creamers, 04-27-2024, 05:32 AM
      3 responses
      21 views
      0 likes
      Last Post Creamers  
      Started by Sebastian - TwinPeaks, 04-08-2024, 09:23 AM
      6 responses
      54 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Working...
      X