kan det vara så att Mozilla och IE skickar file.Filename i olika format och det är där problemet ligger, IE kanske får med några ogiltiga tecken?
Hello
får detta felmeddelande i IE:
The given path's format is not supported.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.NotSupportedException: The given path's format is not supported.
I mozilla funkar det alldeles utmärkt.
Här är lite kod för att ladda upp filen:
Public Shared FUnction SaveDataFile(file As HttpPostedFile, filename As String) As String
Dim saveToFolder As String = "\temp"
Dim tmpFilename As String
If (filename Is Nothing OR filename = String.Empty) Then
tmpFilename = filename
Else
tmpFilename = file.FileName
End If
Try
file.SaveAs("\temp\" & file.Filename)
Return file.Filename
Catch Ex As Exception
Throw Ex
End Try
End Function
Formatet på text-filen är System.Text.Encoding.GetEncoding(850))
Annars kan man inte läsa svenska tecken. Text-filen kommer från en AS400-export
cya,
/PatrikB
