Minali Posted January 4, 2013 Author Share Posted January 4, 2013 Hello guru, We have successfully completed the code we don't have above queries now, the code we made is below: private string data private string setpoint2 while(1) try device.CUB5V.purge() device.CUB5V.Write("N0TA*") data = device.CUB5V.readUntil(10) device.CUB5V.Write("N0TE*") setpoint2 = device.CUB5V.read(12) private nData = strToDouble(mid(data,6,200)) private nSP2 = strToDouble(mid(setpoint2,6,200)) if(nData >= nSP2) Counter.AddValue(ndata) endif catch() ? strLastError endcatch delay(1) endwhile. But we have one new query that the code gives us output in Channel Table continuously may be because there is a while loop and we are wishing to see only the maximum value in the Table for logging purpose means after satisfying the ">=" condition the all values comes in Table and we only want maximum one so Can you help me suggesting any Logic to do so ? Can creating Variable will help me? Help me regarding Link to comment Share on other sites More sharing options...
AzeoTech Posted January 8, 2013 Share Posted January 8, 2013 You can do this a couple ways: 1) put the data in the channel, then do: max(counter) to retrieve the maximum value 2) add the following if() around the counter.addvalue(): if (max(counter) < ndata) counter.addValue(ndata) endif If you clear out counter at the beginning, you can change the if to just: if (counter[0] < ndata) counter.addValue(ndata) endif Link to comment Share on other sites More sharing options...
Minali Posted January 10, 2013 Author Share Posted January 10, 2013 Thank you so much GURU Link to comment Share on other sites More sharing options...
jyoti Posted February 2, 2013 Share Posted February 2, 2013 Hello sir Can this software will communicate with CCTV.? Link to comment Share on other sites More sharing options...
AzeoTech Posted February 4, 2013 Share Posted February 4, 2013 Depends. What do you want to do with the image? Link to comment Share on other sites More sharing options...
Minali Posted February 14, 2013 Author Share Posted February 14, 2013 Can we add or copy-pest any video in DAQ. We try it by assigning quick Seq to button like below : strFName = File.FileOpenDialog("000397283-gears-in-motion-2.mp4","D:\My Documents\Downloads","*.mp4","Data Doc") but file doesn't open in DAQ Link to comment Share on other sites More sharing options...
AzeoTech Posted February 14, 2013 Share Posted February 14, 2013 DAQFactory won't import videos. It will only import jpeg's. There are ways to get some types of video into DF, but it will be low frame rate and only works on certain hardware. Link to comment Share on other sites More sharing options...
jyoti Posted February 22, 2013 Share Posted February 22, 2013 Dear sir, Can we add extra 4th column besides row, time, value in channel table? and Can we eliminate the "0" from row column because we wanted to start from "1". Link to comment Share on other sites More sharing options...
AzeoTech Posted February 22, 2013 Share Posted February 22, 2013 The channel table is really only designed for quickly viewing your data to ensure you are receiving data. If you want a table that looks different, simply add a table component to one of your pages. Link to comment Share on other sites More sharing options...
jyoti Posted March 11, 2013 Share Posted March 11, 2013 Dear sir, Can i open the pdf file through button ? if yes then please tell me which path or command can use . Link to comment Share on other sites More sharing options...
AzeoTech Posted March 11, 2013 Share Posted March 11, 2013 Sure: system.shellExecute("c:\mydir\mydoc.pdf") This assumes you have Acrobat Reader installed of course. Link to comment Share on other sites More sharing options...
jyoti Posted March 12, 2013 Share Posted March 12, 2013 Thank u sir ,its really work. Link to comment Share on other sites More sharing options...
jyoti Posted May 30, 2013 Share Posted May 30, 2013 Hello Guru, In our DAQ project besides the errors like C1136 one window comes named 'Microsoft Visual C++ Runtime Library' and Shows Runtime Error and This Application has requested the Runtime to terminate it in an unusual way. Help me regarding. Link to comment Share on other sites More sharing options...
AzeoTech Posted May 30, 2013 Share Posted May 30, 2013 That is usually caused by issues with external DLL's outside DAQFactory. Can you post or email us your .ctl document? Link to comment Share on other sites More sharing options...
jyoti Posted June 6, 2013 Share Posted June 6, 2013 I attached .ctl file here accordingly give me the solution. small project.ctl Link to comment Share on other sites More sharing options...
AzeoTech Posted June 6, 2013 Share Posted June 6, 2013 Is this the file that actually fails? It calls a number of sequences that aren't there. At what point does it fail? Link to comment Share on other sites More sharing options...
jyoti Posted June 7, 2013 Share Posted June 7, 2013 Hello sir, I again attached here my project. In this project when nData is become greater than setpoint1 in water ,vanspatee,PFM,Sugar sequences at a same time then run time error comes. and when this condition is satisfy in single sequence that time error doesn't come.so please help me. project.ctl Link to comment Share on other sites More sharing options...
AzeoTech Posted June 7, 2013 Share Posted June 7, 2013 Consider using an Export set instead of a Logging set to log one line of data. Doing this: beginlogging(...) delay(2.5) endlogging(...) doesn't really work reliably. It should cause a crash, but its definitely something I would change. I would also uncheck AutoSplit files, and really, the align threshold shouldn't be much above 1. As I said, an export set, where each expression has [0] after it, is a better choice for what you are trying to do. Link to comment Share on other sites More sharing options...
NISHA Posted July 26, 2013 Share Posted July 26, 2013 Hello sir, This is nisha writing you from jhajjar power limited.As i go through the conversations,we are also facing the same issue like jyoti who was discussing about the C++ error & unusual termination.Kindly find the attached .ctl file.Requesting you to suggest areliable solution for the same JPL.zip Link to comment Share on other sites More sharing options...
AzeoTech Posted July 26, 2013 Share Posted July 26, 2013 We are working with your integrator to resolve the issue. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.