web development India freelance website designer
When you use the Inet control to access an FTP site, you'll often need
to issue commands in pairs. For instance, to change from one directory
to another and then display the new directory's structure, you'll need to
first issue the CD (change directory) command, followed by the DIR
(directory) command.
However, in Visual Basic, if you try to execute these commands one
right after another, the Inet control will most likely return an error. That's
because, depending on the connection speed used to access the FTP
site, Visual Basic issues the second command before the FTP site has
had a chance to complete the first command.
To avoid this error, you'll need to wait until the FTP site has finished
processing one command before continuing on to another. To do so,
you can test the Inet control's StillExecuting property. As you can guess,
this property indicates whether or not the last command is still executing.
It returns True if so, and False if not. To take full advantage of this
property, set it up in a loop in conjunction with the DoEvents keyword,
like so:

Private Sub myButton_Click()
With Inet1
.Execute , "CDUP"
Do While .StillExecuting
DoEvents
Loop
.Execute , "DIR"
End With
End
Give the Inet control the time it needs to execute

1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700

Freelance ASP PHP web development | Web developer India Web development India| Prayagasoft - web designer India, Ecommerce developer india, Ecommerce design