Welcome Guest ( Login | Register )



All times are UTC - 7 hours [ DST ]



Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: Sync SQLite data
PostPosted: Wed May 17, 2017 10:13 pm 

Joined: Wed May 17, 2017 1:02 am
Posts: 1

Offline
HI,
Is there any way to synchronize SQLite and SQLserver data?

we use X2 Pro or X2 Base.


 Profile  
 
 Post subject: Re: Sync SQLite data
PostPosted: Tue Apr 10, 2018 9:24 am 
User avatar

Joined: Thu Nov 16, 2017 3:32 pm
Posts: 41

Offline
Hi Jeff-Lin,

Attached is an example project (SQL_Connection.zip) for connecting the panel connect to an external database:

IX, External SQL Connection
IX 2.0 SP1
This example program makes it possible to connect to remote SQL Server.
This script using System.Data.SqlClient Class.
In this example, the answer from the query is put into a text variable.
The example requires general knowledge of SQL Databases.
It is important that the image is version 1.5 (Build 803) or later, when using TXA.

SQL Table:
Image

IX Application:
Image


Attachments:
sql_table.png
sql_table.png [ 2.37 KiB | Viewed 1327 times ]
iX_Application.png
iX_Application.png [ 16.15 KiB | Viewed 1327 times ]
SQL_Connection.zip [104.1 KiB]
Downloaded 118 times

_________________
iX Quick Links:
iX Reference Manual: http://beijerinc.com/download/index.php?id=ix/referencemanual
iX Video Tutorials: https://www.beijerelectronics.com/en/Products/software/ix-hmi-software/Vimeo___video___page
 Profile  
 
 Post subject: Re: Sync SQLite data
PostPosted: Wed Apr 11, 2018 7:36 am 

Joined: Wed Apr 11, 2018 7:17 am
Posts: 1

Offline
Hi Russ,

Bizarre that you typed this response yesterday and I started looking at this problem today!

I have database code in place for SQLite but I'm struggling to get an MS SQL connection working. I have code that works fine on a T21C and compiles fine on the X2 Pro 10 but when I run it I get the following error:

Can't find PInvoke DLL 'dbnetlib.dll'.

I believe I need the above DLL, presumably in my referenced assemblies list. My problem is I'm not sure where to find the correct version.

Did you have this problem? If not, what hardware are you running this code on?

Thanks,

Greg M.


 Profile  
 
 Post subject: Re: Sync SQLite data
PostPosted: Thu Apr 12, 2018 12:52 am 

Joined: Tue Sep 08, 2015 1:32 pm
Posts: 16

Offline
Hi Russ,

I was trying similar code to this yesterday on an X2 Pro 10 but although the code compiles and runs fine on my PC, when downloaded to the terminal I get the following error:

Can't find PInvoke DLL 'dbnetlib.dll'

Did you get this problem on the T7A?

I have tried adding a reference to all the versions of this file I can find on my PC to no avail. I'm worried that even if I can find a compatible file, adding a reference may not solve the problem. I've updated the image to v8.0 Build 569 but still no luck.

Any Ideas?


 Profile  
 
 Post subject: Re: Sync SQLite data
PostPosted: Thu May 31, 2018 2:26 am 

Joined: Wed May 30, 2018 10:54 pm
Posts: 1

Offline
Thanks for the information ความงาม


 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC - 7 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: