Want more features on Pastebin? Sign Up, it's FREE!
Guest

Code

By: a guest on Jun 29th, 2010  |  syntax: None  |  size: 0.64 KB  |  views: 108  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. ' Gambas class file
  2. PUBLIC conexion AS Process
  3. PUBLIC Content AS String
  4. PUBLIC area AS String
  5. PUBLIC Content2 AS String
  6.  
  7. PUBLIC SUB conectar_Click()
  8.  
  9. conexion = SHELL "ssh -l root 10.144.32.51" FOR READ WRITE
  10.  
  11. END
  12.  
  13. PUBLIC SUB Process_Read()
  14.  
  15.   DIM sLine AS String
  16.   LINE INPUT #conexion, sLine
  17.  
  18.  
  19.   Content = Conv((Content & sLine & "\n"), "ISO-8859-1", "UTF-8")
  20. ' Content = Content & sLine & "\n"
  21.   area = Content
  22.   TextArea1.Text = area
  23.   PRINT sLine;
  24.  
  25. END
  26.  
  27.  
  28. PUBLIC SUB desconectar_Click()
  29.  
  30.   conexion.Kill
  31.  
  32. END
  33.  
  34.  
  35.  
  36. PUBLIC SUB enviar_Click()
  37.  
  38. Content = " "
  39. TextArea1.Text = " "
  40. PRINT #conexion, TextBox1.Text
  41.  
  42. END
clone this paste RAW Paste Data