Welcome Guest ( Login | Register )



All times are UTC - 7 hours [ DST ]



Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Show Trend with data from MS SQL-server
PostPosted: Fri Jan 20, 2012 8:15 am 

Joined: Thu Nov 17, 2011 2:10 am
Posts: 46
Location: Norway

Offline
Hi,

is it possible to connect the Trendview to another database than the integrated Compact edition?

Per now we are logging great amounts of data to a SQL database and wish to show this in a Trend in iX.


 Profile  
 
 Post subject: Re: Show Trend with data from MS SQL-server
PostPosted: Tue Jan 24, 2012 1:55 pm 
User avatar

Joined: Fri Jul 15, 2011 3:21 pm
Posts: 214

Offline
Yes, this should be possible with C# scripting by incorporating compatible methods from the System.Data.SqlClient Namespace.
http://msdn.microsoft.com/en-us/library ... 90%29.aspx

The SqlConnection class can connect to SQL Server Databases.
http://msdn.microsoft.com/en-us/library ... 90%29.aspx

Not all methods are available in the .NET Compact Framework so look for the mobile icon next to the method to see if it's available.
http://msdn.microsoft.com/en-us/library ... 90%29.aspx

You can use "Script Modules" in iX Developer Manual to put C# script.

Once you have written script to retrieve the data, copy values into tags by referencing the "Globals.Tags" area in iX Developer (i.e. Globals.Tags.Tag1.Value = 5;). Then make sure the tags you are updating are used by the TrendChart.

_________________
Best Regards,

Beijer Electronics, Inc.
Ron Lloyd | Applications Engineer


 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 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:  
cron