Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

SQLite inside strategy?

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

    SQLite inside strategy?

    Hi - I'm trying to use the current .Net Sqlite (System.Data.SQLite), available for either .net 3.5 or 4.0 from http://system.data.sqlite.org/index....downloads.wiki. (so if anyone can point me to a how-to for ninja with this, we can ignore my later investigations below).

    My PC is an i7, running Win7 Pro, 64bit.

    From other threads, I've gathered that current NT uses .net 3.5 to run itself. However, having installed the .net 3.5 SQLite above, and in NT editing a strategy, I see that System.Data is not available. Since System.Data was available in .net 2.0, you likely have a simple setup explanation (for my incorrect setup) here, thanks.

    That led me to try the snippets below
    Print("Running .net version: " + System.Environment.Version );
    Print("Running .net version: " + System.Runtime.InteropServices.RuntimeEnvironment. GetSystemVersion() );
    These give the output:
    Running .net version: 2.0.50727.5456
    Running .net version: v2.0.50727
    (whether I'm running 32 or 64b NT)

    Also, as a test, I tried to add (edit into my strategy) System.HashSet, which entered .net in 3.5, and could not, making me think the environment is 2.0, not 3.5.

    I've verified that my system has both .net 3.5 and 4.0 installed (and NT itself runs fine), so I believe those versions are present.

    So, is it that NT itself is running .Net 3.5, but our strategies can only access 2.0 .net constructs, assemblies, etc?

    Thanks for clearing this up for me.

    #2
    It looks like you have to manually add the reference if you want to use System.Data:


    Comment


      #3
      Getting better, not there yet.

      Radical - thanks for the pointers...

      I tried both:
      • adding the Reference via right click in editing the strategy,
      • manually editing the Config.xml, as you suggested

      Both ways, the script compiles, but I still get failure to run properly...
      **NT** Error on calling 'OnTermination' method for strategy 'ScanBack/e018f12680d7404892371c184049f9ca': Could not load file or assembly 'System.Data.SQLite, Version=1.0.81.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139' or one of its dependencies. The system cannot find the file specified


      I believe it could find the actual dll file(s) involved.

      Maybe it's failing because of the versioning? (ie Sqlite wants .net 3.5 or 4.0, but the .net environment only appears to be 2.0xxxx).


      Will keep plugging away, thanks for any further pointers.

      Comment


        #4
        bnehlsen, can you please recheck your installed version of the custom dll you attempt to use - it would need to be created with a target framework of 3.5 set to be able to run it via NT7.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        572 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        331 views
        1 like
        Last Post Geovanny Suaza  
        Started by Mindset, 02-09-2026, 11:44 AM
        0 responses
        101 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
        0 responses
        549 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        550 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X