Addon toolkit required to establish an FTP Connection

Hi
I would like to know how an FTP connection can be established using Labview 8.0. I tried to check a few examples for FTP connection .. but it dint open as addon toolkit was not installed ...so i would like to know if the addon toolkit is freely available on NI site or else some links or examples that can help me to establish FTP connectionrequired for my GUI design Application
Waiting in anticipation..
Thanking you. 
Regards
Yogan

Hi ,
   Could you tell me which example you are referring to ? I can open at my end and let you know .
Meanwhile check this http://decibel.ni.com/content/docs/DOC-3664 for a simple FTP VI . This requires just LabVIEW
Regards,
Pran

Similar Messages

  • Cannot establish a ftp connection  to xmldb-filesystem

    Hey everyone,
    how can I connect via ftp to the xmldb-filesystem ?
    I tried the instructions from this website http://www.oracle.com/webfolder/technetwork/de/community/apex/tipps/xmldb-filesystem/index.htm (didn't found an english site, sorry). Now I can connect to the filesystem via "win7 shell ftp", but i cannot connect via "win7 explorer" using "ftp://host:port/foo/bar" or filezilla. Everytime i try i got an errormsg like:
    filezilla: cannot read filesystem
    and
    win7
    an error appears :
    detail:
    200 Type set to A.
    277 Entering Passive Mode.... see sreenshot -> http://imageshack.us/photo/my-images/841/ftpg.jpg/
    If anyone need more information just ask.
    Mario

    955767 wrote:
    Hey everyone,
    how can I connect via ftp to the xmldb-filesystem ?
    I tried the instructions from this website http://www.oracle.com/webfolder/technetwork/de/community/apex/tipps/xmldb-filesystem/index.htm (didn't found an english site, sorry). Now I can connect to the filesystem via "win7 shell ftp", but i cannot connect via "win7 explorer" using "ftp://host:port/foo/bar" or filezilla. Everytime i try i got an errormsg like:
    filezilla: cannot read filesystem
    and
    win7
    an error appears :
    detail:
    200 Type set to A.
    277 Entering Passive Mode.... see sreenshot -> http://imageshack.us/photo/my-images/841/ftpg.jpg/
    If anyone need more information just ask.
    Mariowhat do you see when you try ftp from a Command Window?

  • Can't establish ftp connection between a Xserve and a PB

    We want to use a Xserve (Mac OS X Server 10.4.8) to provide webhosting, but experience problems in establishing ftp connections using a PowerBook (Mac OS X 10.4.8).
    On a WinXP-based notebook using the same Internet connection, anything works fine, just not on my PowerBook.
    This is what happens when trying to establish a ftp connection (via terminal):
    I type: ftp [email protected]
    Returns:
    220 star1.local FTP server ready.
    331 Password required for user.
    I provide the password, anything looks fine, get this output:
    230 User starenterprise logged in.
    Remote system type is UNIX.
    Using binary mode to transfer files.
    ftp>
    Okay, now I want to see what files are in the directory using "dir" command ("ls" brings same result). This output is shown:
    502 'EPSV': command not understood.
    227 Entering Passive Mode (132,78,123,92,42,115)
    Now I can either press CTRL+C to escape or when waiting around one minute, then it states this:
    421 Service not available, remote server timed out. Connection closed
    On a ftp client software like CuteFTP Mac it shows "Can't open data connection" instead of, but result is the same.
    I read through some articles I found here, but nothing compared to my problem. Please help.
    I should mention one thing Apple's support told me: Since I have the same username and UID on my PowerBook as well as on the xServe, it could bring problems. However I have then added a new user to my PowerBook, result is the same. And Apple's support left helpless so far.

    You said: "Not really answered, the problem persists and I now go on and let
    Apple work on it again"
    As a native English speaker, I must say (and doubt any would disagree) that
    your statement implied: "No one here has actually helped me fix this problem,
    and now I'm waiting for Apple to fix it"
    Please take care to the word "again" I used; this implies that Apple has tried to solve the issue before but failed (in fact, they stated to call me back, but this is weeks ago) and so I posted this here at the discussions.
    Unfortunately I only have access to the "free" support (well, free is not the right word when paying 12 cents per minute for the phone call).
    And this means (at least I can speak for the German part of Apple) that operators on the phone look at their knowledgebase and sending articles by e-mail; questions going deeper are resulting in a "we call you back" answer. Sometimes they phone back, sometimes not. Sometimes they are helpful, sometimes (or should I say "in most cases") they just give hints or ask me to investing a nice amount into premium support.
    Don't misunderstand me in the direction that I demand assistance from this forum - I'm more than gradeful if I get help (and rewarded this always with giving points), it has saved me several times (many, many, many times) for doing time consuming investigations and making trial-and-error experiences by myself. If I cannot get more assistance, well I have to look elsewhere and so be a bit impertinent to Apple's support. Perhaps it helps
    You are right, FTP itself works correctly. It even works fine on the WinXP notebook residing at the same LAN as my PB. Therefore the issue is at the PB's firewall very likely (or a strange relationship between two firewalls which seems not to affect WinXP).
    But as you indicate, it makes no sense to lower down security just for doing ftp, especially since SSH works well. However since I have no problems doing ftp sessions with other servers, I would be eager to find the reason why it refuses in this case, even this just means feeding my curiosity
    So if I come to new insights, I post them here. But I feel that I'll really need your wishes for luck to solve this problem Let's see...

  • FTP connection in J2ME

    Hi All,
    can anyone tell me is FTP connection in J2ME possible or not? If it is possible, how it is possible?
    Mahabub

    AFAIK at present there is no FTP API's avalable from J2ME/MIDP front that you can use to establish an FTP connection.
    Meanwhile I have a pretty easier solution for you. You can use Jakarta Commons Net API's at the App server end to communicate to the intended FTP server by means of Servlet so that you can form an Http response as per your requirements. for e.g.:- you issue ftp command from J2ME client and pass it over http to the Servlet residing in your app server. internally the web-tier component establishes the link to the FTP server and responds appropriately based on the issued commands.
    You can also use a telnet client that uses socket communications but the approach mentioned above I rekon would be a feasible one bcause the Usability matters the most when it comes to Mobile applications.
    Hope this information helps.
    ~Mohan

  • Adobe Dreamweaver FTP connection doesn't work with german "Umlaut" like "ö" in the severadress

    Hi
    Today I tried to establish a FTP connection to the serveradress "ftp.möbelverwandlung.com", but I get the error message that the program couldn't connect to the host. As Dreamweaver works perfectly with other serveradresses and I managed to establish a connection to "ftp.möbelverwandlung.com" with other programs, I think that the problem is the german "Umlaut" "ö". Did anyone recognize the same problem and does someone know a solution?
    Thank you very much for your help

    Here is the English translation of your previous post -
    Hello Maximilian,
    I got a even looked at my provider. Usually there must pay the original domain for the agreed period and agree a new. However, they show a accommodating for so short "duration" of a few hours like you. Try to contact your ISP phone support.
    MfG
    Hans-Günter
    Anyhow, I think you have covered the options!

  • Read only on ftp connection?

    Hello!
    I tried to establish an ftp connection to a server to upload some files, but I had only read permissions. My friend told me it worked from windows(very annoying!). Yes, I had a Windows 7 Boot Camp installation and was able to transfer the files from there. However I don´t like the idea of having to downgrade system just to do some ftp. The server filesystem was EXT4 and I also downloaded a separate free FTP client from App Store: Still no write permission!
    After all, in Mac OS there is an option connect to server using login name and password then why shouldn´t it just work like OS X is expected to?
    Thanks for your replies

    I doubt it is the filesystem as the FTP server should be handling file IO.
    Try in the Terminal. There are several ways you can connect.
    It is basically ftp user@host, but you can type man ftp to see a list of ways to add username and password, port, etc. Once in man, type q to quit.
    Once you log in, you'll have an ftp> prompt. Use the ftp commands to "put" or "get" a file, and "ls" to see what is there. The rest of the commands are in the man page.
    Basic FTP has pretty much been dropped from OS X as it is completely insecure. However, I'm not sure why a third-party ftp client had trouble. Maybe it was how you logged into the server.

  • FTPS connection to GXS

    Hello!
    I am trying to establish a FTPS connection to our VAN GXS using these settings/credentials:
    The processing starts and after 20-30 minutes I am getting the following error message:
    I am using SAP PI 7.1. Does anyone know how to configure the communication channel properly?
    Thank you!
    Regards
    Christian

    Hi Christian,
    Check below blogs related to FTPS.
    How to setup a FTPS connection in PI 7.10
    How to configure FTPS in File Adapter.
    Regards,
    Praveen.

  • FTP connection on mobile device works over wifi but fails over 3G

    Hi all,
    Hoping someone can help, or has come across this issue.
    I am developing a mobile app using flash builder 4.6 with the flex 4.6 sdk. My app needs to transfer files via ftp.
    The issue I am experiencing is that the ftp connection establishes and files transfer without a problem when connected via wifi, on both android and ios platforms.
    However, when only connecting via a 3G connection on a device, a problem occurs. While I can establish a connection, when I send the USER command, I never receive a response.
    A simple view with code to reproduce this issue is listed below. Has anyone come across this problem? I have been searching far and wide but cannot find anything related.
    Could this be an issue with Adobe Air or the socket class? I have written equivalent code using the android sdk in eclipse, and a connection to the same server and user details works on both wifi and 3g connections.
    Any help would be appreciated.
    Thanks.
    <?xml version="1.0" encoding="utf-8"?>
    <s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
                        xmlns:s="library://ns.adobe.com/flex/spark" title="HomeView">
              <fx:Script>
                        <![CDATA[
                                  private var commands:Array;
                                  private var s:Socket;
                                  private var data_channel:Socket;
                                  private function connectToFtp():void
                                            var ftp_response:String;
                                            var data_response:String;
                                            var data_channel_ip:String;
                                            var data_channel_port:int;
                                            s = new Socket();
                                            s.addEventListener(Event.CLOSE, closeConnection);
                                            s.addEventListener(Event.CONNECT, connectionMade);
                                            s.addEventListener(IOErrorEvent.IO_ERROR, showError);
                                            s.addEventListener(SecurityErrorEvent.SECURITY_ERROR, showSecError);
                                            s.addEventListener(ProgressEvent.SOCKET_DATA, receiveReply);
                                            s.connect("mydomain.com", 21);
                                            function receiveReply(e:ProgressEvent):void{
                                                      ftp_response = s.readUTFBytes(s.bytesAvailable);
                                                      trace(ftp_response);
                                                      var code:String = ftp_response.substr(0, 3);
                                                      if (code == "220")
                                                                // connected.
                                                                // send user command
                                                                 s.writeUTFBytes("USER myUserName\n");
                                                                s.flush();
                                                      else if (code == "331")
                                                                // user command sent. password required
                                                                // send password
                                                                s.writeUTFBytes("PASS myPassword\n");
                                                                s.flush();
                                                      else if (code == "230")
                                                                // login successful
                                                                // change directory
                                                                s.writeUTFBytes("CWD /fibreSyncFtp/\n");
                                                                s.flush();
                                                      else if (code == "250")
                                                                // change directory successful
                                                                // send passive command
                                                                s.writeUTFBytes("PASV\n");
                                                                s.flush();
                                                      else if(code == "227")
                                                                //get the ip from the string response
                                                                var temp:String = ftp_response.substring(ftp_response.indexOf("(") + 1, ftp_response.indexOf(")"));
                                                                var data_channel_temp:Array = temp.split(",");
                                                                data_channel_ip = data_channel_temp.slice(0,4).join(".");
                                                                //calculate the port number from the last two digits - if this makes no sense, google
                                                                // FTP PROTOCOL - there are loads of guides that explain the server responses.
                                                                data_channel_port = parseInt(data_channel_temp[4]) * 256 + int(data_channel_temp[5]);
                                                                data_channel = new Socket(data_channel_ip, data_channel_port);
                                                                data_channel.addEventListener(ProgressEvent.SOCKET_DATA, receiveData);
                                                                s.writeUTFBytes("LIST\n");
                                                                s.flush();
                                                      else if (code == "125")
                                                                //use the new IP to open a second socket - this will transmit the data.
                                                                // Your first socket will transmit any commands you issue and this new socket will transmit the data
                                                      else if (code == "226")
                                                                // transfer complete
                                                                // close the connection
                                                                //s.close();
                                                      else if (code == "425")
                                                                // can't open connection
                                            function connectionMade(e:Event):void
                                                      trace("Connection Made");
                                            function receiveData(e:ProgressEvent):void{
                                                      data_response = data_channel.readUTFBytes(data_channel.bytesAvailable);
                                                      trace(data_response);
                                            function showError(e:IOErrorEvent):void{
                                                      trace(e.text);
                                            function showSecError(e:SecurityErrorEvent):void{
                                                      trace(e.text);
                                            function closeConnection(e:Event):void{
                                                      trace(e.type);
                        ]]>
              </fx:Script>
              <fx:Declarations>
                        <!-- Place non-visual elements (e.g., services, value objects) here -->
              </fx:Declarations>
              <s:Button top="10" label="FTP" click="connectToFtp()" horizontalCenter="0"/>
    </s:View>

    Probably you need to write your own AIR native extension, which uses the native Android sockets..I have the same problem and I'm just starting writing the extension...I guess there is no other way..At least you test with native android socket and you confirm is fine, so we know it should work

  • Need help to Configure FTPS connection for File Sender Adapter

    Hi,
    I want to Configure, FTPS connection (Secured Connection) for File Sender Adapter. Could anyone please guide me, what Information I require to configure. I just want to know what Information should I request the team inorder the configure FTPS so that it can be deployed properly.
    I have checked with [SAP Help Link|http://help.sap.com/saphelp_nw04/helpdata/EN/e3/94007075cae04f930cc4c034e411e1/content.htm] and while configuring the communication channel found that I need Keystore and the X.509 Certificate and Private Key.  which needs to be deployed on the J2EE server by using the Visual Administrator.
    Is there anything else, I need to configure.
    Any help would be appreciated in this regard.
    Thanks & Regards,
    Varun.K

    The basic things are Certificate/Keys which you already know. Usually it is enough for running a sceanrio.
    However, if you have additional requirements, like FTPS for "Connection Security" for encryption, then you may need additional details like commands. Rest all settings are same as FTP.
    Regards,
    Prateek

  • Can't establish a sftp connection with the finder

    Hi, I'm trying to establish a sftp connection with the finder (using the "Connect to server" feature) between my (recently purchased) Mac Mini (mid 2011: i5, 2.3 GHz, 2 GB, running 10.7.3) and a Debian Testing box and I can't, I get the following error:
    'There was a problem connecting to the server "ip.address"
    This file server will not allow any additional users to log on. Try to connect again later.'
    However if I try establishing a connection from the terminal (either ssh or sftp) it works flawlessly:
    SSH:
    victoria:~ RonIn$ ssh [email protected]
    [email protected]'s password:
    Linux clementine 3.0.0-1-486 #1 Sat Aug 27 15:56:48 UTC 2011 i686
    The programs included with the Debian GNU/Linux system are free software;
    the exact distribution terms for each program are described in the
    individual files in /usr/share/doc/*/copyright.
    Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
    permitted by applicable law.
    You have new mail.
    Last login: Sat Apr 28 21:52:18 2012 from ukamy.local
    ronin@clementine:~$
    SFTP:
    victoria:~ RonIn$ sftp [email protected]
    [email protected]'s password:
    Connected to ip.address.
    sftp>
    I've searched for a fix or alternative on the internet and I haven't found one that works; The one that keeps coming up is to try: "ftps" as the protocol instead of "sftp" with the remaining information the same (it doesn't work, it gets the same error message afterwards).
    The IP address and login information works (corroborated by the fact that I can log in from the terminal from the Mac Mini) so the only issue is with the finder capabilities for establishing the connection. I have looked for apple related documentation or How Tos but I haven't found anything useful.
    I don't want to use any third party app or tweak because of the sensitive information that is going to be transfered, I would like to be using strictly the tools from the OS.
    If you need any more information please let me know, any help is deeply appreciated.

    I have the same issue although i kind of fixed it. I have two admin accounts and one of the account's safari did the same thing as yours, except, it was the startpage and everypage i tried to visit. I reseted safari, as in the erase all data safari in the toolbar, safari-Reset Safari... But safari still didn't work. I logged out and went to my other account and opened safari. Now it works fine on both accounts. This meant safari had to logout before actually working better. I have this a few times these days.

  • ABAP to FTP connect to non SAP UNIX system

    Greetings~
    I'm looking for a way (via function modules and/or BAPI) to transfer data in flat files from an SAP UNIX system to a non-SAP UNIX system using an ABAP program. I see FM's FTP_CONNECT and FTP_COMMAND however these seem to only work with UNIX systems running SAP as they require RFC_DESTINATION information. Anybody know which (if any) FM's can be used without the necessity of the target system running SAP/RFC?
    Thanks!

    Hi Joseph,
    Please refer the below program.
    REPORT  ZHR_T777A_FEED.
    tables: t777a.                        "Building Addresses
    Internal Table for  Building table.
    data: begin of it_t777a occurs 0,
            build like t777a-build,       "Building
            stext like t777a-stext,       "Object Name
            cname like t777a-cname,       "Address Supplement (c/o)
            ort01 like t777a-ort01,       "City
            pstlz like t777a-pstlz,       "Postal Code
            regio like t777a-regio,       "Region (State, Province, County)
          end of it_t777a.
    Internal Table for taking all fields of the above table in one line
    separated by ‘|’(pipe).
    data: begin of it_text occurs 0,
          text(131),
          end of it_text.
    Constants: c_key  type i value 26101957,
               c_dest   type rfcdes-rfcdest value 'SAPFTPA'.
    data: g_dhdl type i,      "Handle
          g_dlen type i,      "pass word length
          g_dpwd(30).         "For storing password
    Selection Screen Starts
    SELECTION-SCREEN BEGIN OF BLOCK blk1 WITH FRAME TITLE TEXT-001.
    parameters: p_user(30) default 'XXXXXXX'          obligatory,
                p_pwd(30)  default 'XXXXXXX'          obligatory,
                p_host(64) default 'XXX.XXX.XX.XXX'   obligatory.
    SELECTION-SCREEN END OF BLOCK blk1.
    SELECTION-SCREEN BEGIN OF BLOCK blk2 WITH FRAME TITLE TEXT-002.
    parameters: p_file like rlgrap-filename default 't777a_feed.txt'.
    SELECTION-SCREEN END OF BLOCK blk2.
    Password not visible.
    at Selection-screen output.
      loop at screen.
        if screen-name = 'P_PWD'.
          screen-invisible = '1'.
          modify screen.
        endif.
      endloop.
    g_dpwd  = p_pwd.
    Start of selection
    start-of-selection.
    To fetch the data records from the table T777A.
      select build stext cname ort01 pstlz regio
             from t777a
             into table it_t777a.
    Sort the internal table by build.
      if not it_t777a[] is initial.
        sort it_t777a by build.
      endif.
    Concatenate all the fields of above internal table records in one line
    separated by ‘|’(pipe).
      loop at it_t777a.
        concatenate it_t777a-build it_t777a-stext it_t777a-cname
                    it_t777a-ort01 it_t777a-pstlz it_t777a-regio
                    into it_text-text separated by '|'.
        append it_text.
        clear it_text.
      endloop.
    To get the length of the password.
      g_dlen = strlen( g_dpwd ).
    Below Function module is used to Encrypt the Password.
      CALL FUNCTION 'HTTP_SCRAMBLE'
        EXPORTING
          SOURCE      = g_dpwd          "Actual password
          SOURCELEN   = g_dlen
          KEY         = c_key
        IMPORTING
          DESTINATION = g_dpwd.         "Encyrpted Password
    *Connects to the FTP Server as specified by user.
      Call function 'SAPGUI_PROGRESS_INDICATOR'
        EXPORTING
          text = 'Connecting to FTP Server'.
    Below function module is used to connect the FTP Server.
    It Accepts only Encrypted Passwords.
    This Function module will provide a handle to perform different
    operations on the FTP Server via FTP Commands.
      call function 'FTP_CONNECT'
        EXPORTING
          user            = p_user
          password        = g_dpwd
          host            = p_host
          rfc_destination = c_dest
        IMPORTING
          handle          = g_dhdl
         EXCEPTIONS
            NOT_CONNECTED.
      if sy-subrc ne 0.
        format color col_negative.
        write:/ 'Error in Connection'.
      else.
        write:/ 'FTP Connection is opened '.
      endif.
    **Transferring the data from internal table to FTP Server.
      CALL FUNCTION 'FTP_R3_TO_SERVER'
        EXPORTING
          HANDLE         = g_dhdl
          FNAME          = p_file
          CHARACTER_MODE = 'X'
        TABLES
          TEXT           = it_text
        EXCEPTIONS
          TCPIP_ERROR    = 1
          COMMAND_ERROR  = 2
          DATA_ERROR     = 3
          OTHERS         = 4.
      IF SY-SUBRC <> 0.
        MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ELSE.
        write:/ 'File has created on FTP Server'.
      ENDIF.
    Call function 'SAPGUI_PROGRESS_INDICATOR'
        EXPORTING
          text = 'File has created on FTP Server'.
    To Disconnect the FTP Server.
      CALL FUNCTION 'FTP_DISCONNECT'
        EXPORTING
          HANDLE = g_dhdl.
    To Disconnect the Destination.
      CALL FUNCTION 'RFC_CONNECTION_CLOSE'
        EXPORTING
          destination = c_dest
        EXCEPTIONS
          others      = 1.
    Regards,
    Kumar Bandanadham.

  • Time to time its giving error in the FTP connection

    Hi Gurus,
    Im doing File to File Interface. Im using FTP for File transfer and the message protocol is 'File'.  Im using the connection security as 'FTPS(FTP Using SSL/TLS) for control and data connection' and set the default command order.
        I have uploaded the required certificate in the FTP server and the XI server also. I can view the certificate in the keystore of visual Administrator. Its working fine. But the problem is time to time its giveing this error "Error occurred while connecting to the FTP server "170.135.128.149:20021": iaik.security.ssl.SSLCertificateException: Peer certificate rejected by ChainVerifier"
    Can anyone please help to resolve this issue. i need to fix it as soon as possible.
    Regards,
    Rama

    Hi All,
      I m facing one peculiar problem with FTP server. I have desinged one R3 to FTP interface. I m trying to connect to FTP with secure SSL connection. For that we uploaded the certificate in the FTP as well as in the Visual administartor in the XI box. I didnt create any SSL socket for this. Our basis team told like we dont need this SSL socket stuff because here we are using FTP as a client. So just they uploaded the certificate in the trusted CA of Visual administartor. Our certificate is obtained from verisign. So the CN name in the certificate is Verisign. I didnt find any thing in the certificate other then this. In our communication channel we gave the hostname instead of IP address.  But here my problem is, When i send the file to FTP its giving error in the first attempt. After that the message retiried itslef, the file has been sent successfull in the retry process. Why it is always fails in the first attempt.
    Can anyone please help me to resolve this. I need to be fix today itself.
    Regards,
    Rama

  • Establishing a socket connection between a .swf file and a socket-test program (TCP/IP builder - Windows), in AS3.

    I have an issue with a college project I'm working on.
    Using Actionscript 3, I made a simple .swf program, an animated, interactive smiley, that 'reacts' to number inputs in a input-box.
    For the sake of the project, I now need to make the framework for establishing a socket connection with the smiley .swf, and another program.
    This is where I encounter issues. I have very little knowledge of AS3 programming, so I'm not certain how to establish the connection - what's required code-wise for it, that is.
    To test the connection, I'm attempting to use the "TCP/IP builder" program from windows, which lets me set up a server socket. I need to program the .swf file into a client - to recognize it, connect to it, then be able to receive data (so that the data can then be used to have the smiley 'react' to it - like how it does now with the input-box, only 'automatically' as it gets the data rather than by manual input).
    My attempts at coding it are as follows, using a tutorial (linked HERE):
    //SOCKET STUFF GOES HERE
        var socket:XMLSocket;        
        stage.addEventListener(MouseEvent.CLICK, doConnect); 
    // This one connects to local, port 9001, and applies event listeners
        function doConnect(evt:MouseEvent):void 
        stage.removeEventListener(MouseEvent.CLICK, doConnect); 
        socket = new XMLSocket("127.0.0.1", 9001);   
        socket.addEventListener(Event.CONNECT, onConnect); 
        socket.addEventListener(IOErrorEvent.IO_ERROR, onError); 
    // This traces the connection (lets us see it happened, or failed)
        function onConnect(evt:Event):void 
            trace("Connected"); 
            socket.removeEventListener(Event.CONNECT, onConnect); 
            socket.removeEventListener(IOErrorEvent.IO_ERROR, onError); 
            socket.addEventListener(DataEvent.DATA, onDataReceived); 
            socket.addEventListener(Event.CLOSE, onSocketClose);             
            stage.addEventListener(KeyboardEvent.KEY_UP, keyUp); 
        function onError(evt:IOErrorEvent):void 
            trace("Connect failed"); 
            socket.removeEventListener(Event.CONNECT, onConnect); 
            socket.removeEventListener(IOErrorEvent.IO_ERROR, onError); 
            stage.addEventListener(MouseEvent.CLICK, doConnect); 
    // Here, the flash tracks what keyboard button is pressed.
    // If 'q' is pressed, the connection ends.
            function keyUp(evt:KeyboardEvent):void 
            if (evt.keyCode == 81) // the key code for q is 81 
                socket.send("exit"); 
            else 
                socket.send(evt.keyCode); 
    // This one should handle the data we get from the server.
            function onDataReceived(evt:DataEvent):void 
            try { 
                trace("From Server:",  evt.data ); 
            catch (e:Error) { 
                trace('error'); 
        function onSocketClose(evt:Event):void 
            trace("Connection Closed"); 
            stage.removeEventListener(KeyboardEvent.KEY_UP, keyUp); 
            socket.removeEventListener(Event.CLOSE, onSocketClose); 
            socket.removeEventListener(DataEvent.DATA, onDataReceived);
    Trying to connect to the socket gives me either no result (other than a 'connection failed' message when I click the .swf), or the following error:
    Error #2044: Unhandled securityError:. text=Error #2048: Security sandbox violation: file:///C|/Users/Marko/Desktop/Završni/Flash%20documents/Smiley%5FTCP%5FIP%5Fv4.swf cannot load data from 127.0.0.1:9001.
        at Smiley_TCP_IP_v4_fla::MainTimeline/doConnect()[Smiley_TCP_IP_v4_fla.MainTimeline::frame1:12] 

    Tried adding that particular integer code, ended up with either errors ("use of unspecified variable" and "implicit coercion") , or no effect whatsoever (despite tracing it).
    Noticed as well that the earlier socket code had the following for byte reading:
    "sock.bytesAvailable > 0" (reads any positive number)
    ...rather than your new:
    "sock.bytesAvailable != 0" (reads any negative/positive number)
    Any difference as far as stability/avoiding bugs goes?
    So then, I tried something different: Have the program turn the "msg" string variable, into a "sentnumber" number variable. This seemed to work nicely, tracing a NaN for text (expected), or tracing the number of an actual number.
    I also did a few alterations to the input box - it now no longer needs the 'enter' key to do the calculation, it updates the animation after any key release.
    With all this considered and the requirements of the project, I now have a few goals I want to achieve for the client, in the following order of priority:
    1) Have the "sentnumber" number variable be recognized by the inputbox layer, so that it puts it into the input box. So in effect, it goes: Connect -> Send data that is number (NaN's ignored) -> number put into input box -> key press on client makes animation react. I optionally might need a way to limit the number of digits that the animation reacts to (right now it uses 1-3 digit numbers, so if I get sent a huge number, it might cause issues).
    - If the NaN can't be ignored (breaks the math/calculus code or some other crash), I need some way of 'restricting' the data it reads to not include NaN's that might be sent.
    - Or for simplicity, should I just detect the traced "NaN" output, reacting by setting the number variable to be "0" in such cases?
    2) After achieving 1), I'll need to have the process be automatic - not requiring a keyboard presses from the client, but happening instantly once the data is sent during a working connection.
    - Can this be done by copying the huge amounts of math/calculus code from the inputbox layer, into the socket layer, right under where I create the "sentnumber" variable, and modifying it delicately?
    3) The connection still has some usability and user issues - since the connection happens only once, on frame 1, it only connects if I already have a listening server when I run the client, and client can't re-connect if the server socket doesn't restart itself.
    I believe to do this, I need to make the connection happen on demand, rather than once at the start.
    For the project's requirement, I also need to allow client users to define the IP / port it's going to connect to (since the only alternative so far is editing the client in flash pro).
    In other words, I need to make a "Connect" button and two textboxes (for IP and port, respectively), which do the following:
    - On pressing "Connect", the button sets whatever is in the text boxes as the address of the IP and port the socket will connect to, then connects to that address without issues (or with a error message if it can't due to wrong IP/port).
    - The connection needs to work for non-local addresses. Not sure if it can yet.
    - On re-pressing connect, the previous socket is closed, then creates a new socket (with new IP/port, if that was altered)
    It seems like making the button should be as simple as putting the existing socket code under the function of a button, but it also seems like it's going to cause issues similar to the 'looping frames' error.
    4) Optional addition: Have a scrolling textbox like the AIR server has, to track what the connection is doing on-the-fly.
    The end result would be a client that allows user to input IP/Port, connects on button press (optionally tracking/display what the socket is doing via scrollbox), automatically alters the smiley based on what numbers are sent whilst the connection lasts, and on subsequent button presses, makes a new connection after closing off the previous one.
    Dropbox link to new client version:
    https://www.dropbox.com/s/ybaa8zi4i6d7u6a/Smiley_TCP_IP_v7.fla?dl=0
    So, starting from 1), can I, and how can I, get the number variable recognized by "inputbox" layer's code? It keeps giving me 'unrecognized variable' errors.

  • Multiple FTP connections

    I'm using Labview 8.2 with Internet toolkit. I'd like to connect to multiple FTP sites, and download files from all sites simultaneously. I would simply use parallel cycles to do that, but it's not possible because the toolkit's FTP VIs are not reentrant, so for example i can't run two "FTP Get File.vi" at the same time. Do you think i could modify those VIs, making them reentrant, or there is some technical limit that allows only one FTP download at a time?

    Thanks Paolo, i tried to set as reentrant all the call chain to TCP Read Stream.vi; i also tried to set as reentrant all the FTP VIs, except FTP Registry.vi which looks like a functional global. It seems to work, i can download from two FTP sites simultaneously, but the gain in performance is very low. Parallel downloading (two groups of files from two sites) takes only 10% less time than serial downloading (one site at a time). Where's the bottleneck? Maybe total network speed?

  • Poor performance in establishing an SSL connection

    Hi,
    i have a Servlet (loaded on Tomcat 4.1) that establishes a SSL Connection to a remote server. The issue is, is that the connection phase takes over 4 seconds to complete!
    heres the function where the problem shows
    public SSLSocket getSocket()
    throws NoSuchAlgorithmException, KeyStoreException, FileNotFoundException,
    IOException, KeyManagementException, CertificateException,
    UnrecoverableKeyException
    * Set up a key manager for client authentication if asked by the server.
    SSLSocketFactory factory = null;
    SSLContext ctx;
    KeyManagerFactory kmf;
    KeyStore ks;
    // Set the SSL Context to TLS (required for Client certs).
    ctx = SSLContext.getInstance("TLS");
    kmf = KeyManagerFactory.getInstance("SunX509");
    ks = KeyStore.getInstance(ksType);
    // Load in the KeyStore.
    ks.load(new FileInputStream(ksLoc), ksPassphrase);
    kmf.init(ks, ksPassphrase);
    // Generate some random data.
    SecureRandom sr = new SecureRandom();
    sr.nextInt();
    // Initialise the SSL with the random data.
    ctx.init(kmf.getKeyManagers(), null, sr);
    factory = ctx.getSocketFactory();
    * Open the Socket to the SSL server. from this point we can treat
    * it like and nomal Socket
    SSLSocket socket = (SSLSocket)factory.createSocket(servHost, servPort);
    // Force the handshake
    socket.startHandshake();
    // Return the now open SSLSocket to the caller.
    return socket;
    the problematic line is:
    SSLSocket socket = (SSLSocket)factory.createSocket(servHost, servPort);
    it takes about 4.5 - 5.0 seconds to return. The remote server is based on the same LAN as this Servlet and so network lag should not be an issue (im accessing via 10.xx ip too)
    Can anyone help me in determining why this takes so long?
    Thanks !
    Darren.

    First, try by removing the line which says:
    socket.startHandshake();because the handshake will be initiated by the socket upon creation.
    If you are using JDK v1.4.1 I've seen some SSL performance issues when stablishing the connection, so I returned to my old JDK 1.3.1.
    Also be sure to create the factory in the servlet init() method because it has no sense to recreate the factory in every request as long as it uses the same KeyManager.
    HTH

Maybe you are looking for

  • How to delete archivelog with RMAN in the Primary and Standby database?

    Hello, I am working on Oracle 10gR2. My question is : How could I implement a automatized and secure way of: 1) Delete archivelogs on my PRIMARY server only when these logs are successfully TRANSFERED to all my standby databases? 2) Delete archivelog

  • HTTPS Web Service datastore : does not work in case of proxy

    Data Services 12.2 on Windows XP SP2 I've set up a datastore, type "web service", url is https://.... (an external web service, outside of our company) I'm able to import the functions of this web service into the datastore. In a DF, in a query trans

  • How do I use the AiO wifi app to print email on my droid device

    Good morning,  I need help printing on a Droid device.  My printer is the ENVY 5660.  The app is install and validated on the Motorola Maxx phone.   I can pick the HP app and do see; File, Photos etc.    was able to successfully print a document from

  • Loyalty Program in Web Channel

    Dear Experts, Currently as what i'm aware of, we basically need to add the Loyalty Program in the Web Channel B2C shop as the administrator to allow this particular Loyalty Program to be available for enrollment by the customer in the webshop. With t

  • Quality info record mass creation

    Hello Guys, Can we able to do mass creation of quality info records thru QI06 ? I want to load bunch of QIR as a manual load. I tried using qi06 in add option but I am getting a warning message that QIR is not changed. Is that only we can change it ?