-
how to select multiple files from file upload using a button
hi
how to select multiple files from file upload browser,
i need to get file upload browser window by using button,instead of using <input type="file">
after selecting the file it has to be placed in a table and have to retriev that file by using struts action...i have to use jsp,struts.
Thanks in advance
sandesh
-
-
download file issue with firefox, please help
Public Sub DownloadFile(ByVal strFileFullName As String, Optional ByVal strContentType As String)
Dim sFilePath As String
Dim strFileName As String
Dim strDebug As String
strFileName = GetFileName(strFileFullName)
If strFileName = "" Then
m_objResponse.Write "Filename Not specified."
m_objResponse.End
End If
'Start the download process if all is good
m_objResponse.Clear
m_objResponse.ContentType = "application/octet-stream"
m_objResponse.AddHeader "content-disposition", "attachment; filename=" & strFileName
strDebug = "FileName : " & strFileName
'use stream to write file
Dim adoStream
Set adoStream = CreateObject("ADODB.Stream")
strDebug = "adoStream begin : " & strFileName
adoStream.Open
adoStream.Type = 1
strDebug = "adoStream : " & strFileFullName
adoStream.LoadFromFile (strFileFullName)
m_objResponse.BinaryWrite adoStream.Read()
adoStream.Close
Set adoStream = Nothing
m_objResponse.End
End Sub
When I call from my asp page HIRExFileDownload.DownloadFile(strDownFile) to the downloadFile function in a dll(it is in dll, wrote by VB6), some how the file name is changed to "File1.pdf," follow the file name extention, there is a comma added like "pdf," that caused the download file problem. is there anyone know what's wrong with the DownloadFile function. It is working with IE, but is not work for Firefox. Please help.
Thanks,
Amy
-
download file issue with firefox, please help
Public Sub DownloadFile(ByVal strFileFullName As String, Optional ByVal strContentType As String)
Dim sFilePath As String
Dim strFileName As String
Dim strDebug As String
strFileName = GetFileName(strFileFullName)
If strFileName = "" Then
m_objResponse.Write "Filename Not specified."
m_objResponse.End
End If
'Start the download process if all is good
m_objResponse.Clear
m_objResponse.ContentType = "application/octet-stream"
m_objResponse.AddHeader "content-disposition", "attachment; filename=" & strFileName
strDebug = "FileName : " & strFileName
'use stream to write file
Dim adoStream
Set adoStream = CreateObject("ADODB.Stream")
strDebug = "adoStream begin : " & strFileName
adoStream.Open
adoStream.Type = 1
strDebug = "adoStream : " & strFileFullName
adoStream.LoadFromFile (strFileFullName)
m_objResponse.BinaryWrite adoStream.Read()
adoStream.Close
Set adoStream = Nothing
m_objResponse.End
End Sub
When I call from my asp page HIRExFileDownload.DownloadFile(strDownFile) to the downloadFile function in a dll(it is in dll, wrote by VB6), some how the file name is changed to "File1.pdf," follow the file name extention, there is a comma added like "pdf," that caused the download file problem. is there anyone know what's wrong with the DownloadFile function. It is working with IE, but is not work for Firefox. Please help.
Thanks,
Amy
Similar Threads
-
By LordNightwinter in forum VB Classic
Replies: 1
Last Post: 09-06-2006, 03:15 PM
-
By chinmoy paul in forum Java
Replies: 0
Last Post: 08-28-2006, 01:58 AM
-
By srinivasc_it in forum .NET
Replies: 5
Last Post: 08-18-2006, 01:15 PM
-
By jase_dukerider in forum C++
Replies: 2
Last Post: 04-14-2005, 07:48 PM
-
Replies: 0
Last Post: 03-09-2005, 06:03 AM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Development Centers
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center
|