imkorea

Help me, FTP FileRead and password

1 post in this topic

I want security my program using FTP 

for example

 1. my program start 

2. must send password

password was written by FTP test.txt 

sorry, i'm korean so i cant english 

 

Func main()
    $text = GUICtrlCreateInput("", 10, 15, 150, 20)
    $Button1 = GUICtrlCreateButton("OK", 165, 10, 50, 30)
    $Button2 = GUICtrlCreateButton("EXIT", 220, 10, 50, 30)
    GUISetState(@SW_SHOW)
    While 1
        _FTP_DirSetCurrent($hConnect, $s_Remote)
        $dwNumberOfBytesToRead = _FTP_FileGetSize($hConnect, $FileName)
        $h_File = _FTP_FileOpen($hConnect, $FileName)
        $msg = GUIGetMsg()
        $file = _FTP_FileRead($h_File, $dwNumberOfBytesToRead)
        Switch $msg
        Case $Button1
        If GUICtrlRead($text) <> $file then                                                        << i need your help this sentence
        MsgBox(4096, "Error", "Wrong password!") 
        Else
         GUICreate("Meine GUI", 200, 200, 1000, 350)
         GUISetState()
            While 1
            WEnd
      EndIf
      Case $button2
         Exit
      EndSwitch
   WEnd
EndFunc

 

Share this post


Link to post
Share on other sites



Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now