luarken Posted September 28, 2010 Share Posted September 28, 2010 why at the end of my sequence it truncates the Daqfactory windows says does not respond. thanks // setup FTP FTP.strServer = "ftp.x.com" FTP.strUserName = "x" FTP.strPassword = "x" while(1) delay(300) // wait 600 seconds page.Capture("Home_Page","C:\instrument\images\home.jpg") delay(5) FTP.strLocalFile = "C:\instrument\images\home.jpg" FTP.strRemoteFile = "images\home.jpg" FTP.Upload() delay(40) page.Capture("Instrumento1","C:\instrument\images\1.jpg") delay(5) FTP.strLocalFile = "C:\instrument\images\1.jpg" FTP.strRemoteFile = "images\1.jpg" FTP.Upload() delay(40) page.Capture("Instrumento11","C:\instrument\images\11.jpg") delay(5) FTP.strLocalFile = "C:\instrument\images\11.jpg" FTP.strRemoteFile = "images\11.jpg" FTP.Upload() delay(40) page.Capture("Instrumento2","C:\instrument\images\2.jpg") delay(5) FTP.strLocalFile = "C:\instrument\images\2.jpg" FTP.strRemoteFile = "images\2.jpg" FTP.Upload() delay(40) page.Capture("Instrumento22","C:\instrument\images\22.jpg") delay(5) FTP.strLocalFile = "C:\instrument\images\22.jpg" FTP.strRemoteFile = "images\22.jpg" FTP.Upload() delay(40) page.Capture("Instrumento3","C:\instrument\images\3.jpg") delay(5) FTP.strLocalFile = "C:\instrument\images\3.jpg" FTP.strRemoteFile = "images\3.jpg" FTP.Upload() delay(40) page.Capture("Instrumento33","C:\instrument\images\33.jpg") delay(5) FTP.strLocalFile = "C:\instrument\images\33.jpg" FTP.strRemoteFile = "images\33.jpg" FTP.Upload() delay(40) endwhile Link to comment Share on other sites More sharing options...
AzeoTech Posted September 29, 2010 Share Posted September 29, 2010 Did you view all the pages first as described in the help under web server? If you have any graphs on these pages, you need to view the page, for at least 100ms or so on startup to init the graphs. Link to comment Share on other sites More sharing options...
luarken Posted September 30, 2010 Author Share Posted September 30, 2010 the peculiar thing is that the application, yes loads the images that it captures to the web page and I can to see graphs and pages of my application while sequence realises for the first time, but, if I want to see the graphs and pages of the application when the sequence initiates the second or third ,4,5,6 .....time , I cannot, because the screen of Daqfactory goes totally white and it says that it does not respond. the application works of wonder without this sequence, but I need that this works well. thanks!!!! Link to comment Share on other sites More sharing options...
AzeoTech Posted September 30, 2010 Share Posted September 30, 2010 You might try adding some debugging code of some sort so you can figure out if the sequence is hanging on the FTP.upload() call or on on the capture() function. Its also best to make sure the previous FTP is complete before moving on to the next one, or aborting it if its timing out. Link to comment Share on other sites More sharing options...
luarken Posted October 1, 2010 Author Share Posted October 1, 2010 Can you help me. with that ? I dont know what to do!!! Link to comment Share on other sites More sharing options...
luarken Posted October 1, 2010 Author Share Posted October 1, 2010 Daqfactory (my application) disconnects the connection with the FTP server after realizing the sequence???? Link to comment Share on other sites More sharing options...
AzeoTech Posted October 4, 2010 Share Posted October 4, 2010 There are variables that tell you what's happening: FTP.bytesTransfered FTP.bytesToTransfer The first will go to -1 when the transfer is done. You can use the combination to display a progress bar. But to do a timeout, do something like this: ... ftp.upload() private timeout = 10 // 10 second timeout private st = systime() while (1) if (systime() - st > timeout) ftp.abort() break endif if (ftp.bytesTransfered == -1) break endif delay(0.1) endwhile Since you would need this in a number of places, I'd make a function out of it. Link to comment Share on other sites More sharing options...
ekanderson Posted October 7, 2010 Share Posted October 7, 2010 last line 'endif' in suggested code starting with 'ftp.upload' should it be an endwhile????? Link to comment Share on other sites More sharing options...
AzeoTech Posted October 7, 2010 Share Posted October 7, 2010 yes it should. Link to comment Share on other sites More sharing options...
luarken Posted October 15, 2010 Author Share Posted October 15, 2010 not yet I have been able with this problem , continues causing to problems the part of FTP, since I leave the part of FTP outside and the application works well. the application is not freeze // setup FTP while(1) delay(50) // wait 50 seconds //FTP.strServer = "ftp.xxx.com" //FTP.strUserName = "user" //FTP.strPassword = "123456" delay(100) //ignore("all") page.Capture("Home_Page","C:\instrument\images\home.jpg") delay(10) // FTP.strLocalFile = "C:\instrument\images\home.jpg" // FTP.strRemoteFile = "images\home.jpg" // FTP.Upload() delay(40) page.Capture("Instrumento1","C:\instrument\images\1.jpg") delay(15) // FTP.strLocalFile = "C:\instrument\images\1.jpg" //FTP.strRemoteFile = "images\1.jpg" //FTP.Upload() delay(40) page.Capture("Instrumento11","C:\instrument\images\11.jpg") delay(10) // FTP.strLocalFile = "C:\instrument\images\11.jpg" // FTP.strRemoteFile = "images\11.jpg" // FTP.Upload() delay(80) page.Capture("Instrumento2","C:\instrument\images\2.jpg") delay(10) // FTP.strLocalFile = "C:\instrument\images\2.jpg" // FTP.strRemoteFile = "images\2.jpg" // FTP.Upload() delay(40) page.Capture("Instrumento22","C:\instrument\images\22.jpg") delay(10) // FTP.strLocalFile = "C:\instrument\images\22.jpg" //FTP.strRemoteFile = "images\22.jpg" //FTP.Upload() delay(60) page.Capture("Instrumento3","C:\instrument\images\3.jpg") delay(10) // FTP.strLocalFile = "C:\instrument\images\3.jpg" // FTP.strRemoteFile = "images\3.jpg" // FTP.Upload() delay(40) page.Capture("Instrumento33","C:\instrument\images\33.jpg") delay(10) // FTP.strLocalFile = "C:\instrument\images\33.jpg" // FTP.strRemoteFile = "images\33.jpg" // FTP.Upload() delay(10) // Ftp.Abort() endwhile Link to comment Share on other sites More sharing options...
AzeoTech Posted October 15, 2010 Share Posted October 15, 2010 So it works with just the capture? Try adding just one FTP upload. Link to comment Share on other sites More sharing options...
luarken Posted October 20, 2010 Author Share Posted October 20, 2010 nop if I minimize my application,after some time, also collapse the application. Link to comment Share on other sites More sharing options...
AzeoTech Posted October 20, 2010 Share Posted October 20, 2010 Try making it so all the pages you capture() are only viewed once. Basically duplicate the pages and use one set for viewing in DAQFactory and the other for capturing. BTW: this is really the reason there is now DAQConnect. With DAQConnect viewing over the web is pretty seamless and also gives you true live data as well as the ability to manipulate it without loading down your DAQFactory installation. See www.daqconnect.com Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.