Intouch and Excel

MLR5000

Member
Join Date
Mar 2013
Location
Fyn
Posts
16
Hi there.

I'm in the middle of a project where I need to register some data inputs in Intouch into a Excel doc. Each user has to be able to input there information via some touch buttons in Intouch. These inputs is registered in different columns in excel either as a 0 or 1. Each user is assigned a row in excel, and therefore I need to make a "save" button in intouch that saves the data inputs in excel and then jumps to a new row.

Can anyone come up with a solution?
Im using Intouch 10, Excel 2010 and windows 7

Best regards Martin
 
It's easy enough to write a script that increments the item number(s) for a DDE poke command. You could also have your spreadsheet read tags from InTouch, rather than having InTouch write to the spreadsheet cells. You should be aware, however, that the Excel spreadsheet needs to reside on the same computer as the InTouch HMI, since NetDDE is not supported in Windows 7.
 
Last edited:
How would a script for this poke command look like? I'm still new to Intouch and scripting.

I can't get Excel to read tags from Intouch. A #reference error pops up and say it can't open "view.exe".
 
The Help files are your friend:

WWPoke() Function

Writes data to an item of an application. You can use it, for example, to write the value into a spreadsheet cell in Excel.
Syntax

result = WWPoke (appname, topic, item, string)
Parameters

appname
The name of the application. A literal string value, message tagname, or string expression.
topic
The name of the topic within the application. A literal string value, message tagname, or string expression.
item
The item name belonging to the topic and application. A literal string value, message tagname, or string expression.
string
The value to be written. A literal string value, message tagname, or string expression. You can use the StringFromIntg(), StringFromReal() or Text() functions to convert the value of an integer or real tagname to a message tagname.
Return Value

A value of-1, 0, or 1 indicating the following:
-1 - data not written successfully. Possible causes are the application not running or the topic or item do not exist.
0 - data not written successfully because the application is busy.
1 - data written successfully.
Remarks

Do not use the WWPoke() or WWRequest() function to read and write data between InTouch applications on different nodes or sessions. To read and write data between InTouch applications, use Access Names instead. See Setting Up Access Names.
Example(s)

This script puts the value of the real tagname CellValue in the message tagname Mtag and writes the value to the spreadsheet cell Row 1, Column 1 of sheet Sheet1 in Microsoft Excel book Book1.xls.
MTag = Text(CellValue,"0");
Result = WWPoke("excel","[Book1.xls]sheet1", "r1c1",Mtag);
Related Topics
Interacting with Other Applications
Executing Commands and Exchanging Data using DDE


© 2007, 2011 Invensys Systems, Inc. All Rights Reserved.



I lifted this directly from the InTouch Help files. While this text contains hyperlinks, don't expect them to work, since I'm fairly certain that they are directed toward other help files on my own local hard drive.
 
Thanks I will try that. :)

I still get the error message when trying to read a tag value even though WindowViewer is running...
 
Then I'd check for an error in the data request statement within your spreadsheet cell. Are you sure that you are requesting a valid InTouch tagname?

The formula in your cell should have the following structure: =VIEW|TAGNAME!'ActualTagname' with the ActualTagname being the name of an actual tag that you have created in InTouch.
 
Last edited:
It workes fine with the Poke command, but how should the script look like if I wants it to jump to a new row in excel every time a data is input and poked?
 

Similar Topics

Hey Guys, I am new to this forum and hoping for your help. For my master thesis I am developing a custom recipe organization software...
Replies
3
Views
2,719
Please help me out from a problem which is " 📚:nerves::nerves::nerves:How to Generate Excel report in SCADA Intouch Wonderware[/B][/COLOR]"...
Replies
3
Views
5,229
Software Tool box has released a great new product for users of Intouch history log files (*.lgh). Finally the abillity to export directly from...
Replies
3
Views
11,594
I'm still relatively new to InTouch so please excuse my ignorance. What I'm trying to do is print an excel sheet. When I looked up the manual it...
Replies
4
Views
5,493
Hi... I m working with delta PLC. I can interfacing between Delta Software and Intouch Sw. Now I have to export the data(sensors values) of delta...
Replies
1
Views
3,338
Back
Top Bottom