ravula2000
IS-IT--Management
Here is my code
Dim mcSourceDir As String
drpListFiles.Items.clear()
Select Case pnImpType
Case 2
mcSourceDir = "c:\temp"
Dim dirinfo As New Directoryinfo(mcSourceDir)
drpListFiles.DataSource = dirinfo.GetFiles("*.*"
drpListFiles.DataBind()
End Select
Once pnImpType =2 I am getting list of files in c:\temp directory in the listbox. Next time when pnImptype=0 I need to clear all the items in the listbox.
But the list box still retain its values from c:\temp directory. How can I clear the items.
Thanks
Srini
Dim mcSourceDir As String
drpListFiles.Items.clear()
Select Case pnImpType
Case 2
mcSourceDir = "c:\temp"
Dim dirinfo As New Directoryinfo(mcSourceDir)
drpListFiles.DataSource = dirinfo.GetFiles("*.*"
drpListFiles.DataBind()
End Select
Once pnImpType =2 I am getting list of files in c:\temp directory in the listbox. Next time when pnImptype=0 I need to clear all the items in the listbox.
But the list box still retain its values from c:\temp directory. How can I clear the items.
Thanks
Srini