I am trying to use the Radupload to upload files to the SQL server. The problem I am having is with the path of the file. I am using the code below. The file is trying to be located on the server instead of the client machine. How do I get the correct path so that the server can locate the file.
If RadUpload1.UploadedFiles.Count > 0 Then
For Each validFile As UploadedFile In RadUpload1.UploadedFiles
MyNcr = validFile.GetName
If Right(validFile.GetName, 3) = "jpg" Or Right(validFile.GetName, 3) = "JPG" Then
'validFile.SaveAs(Path.Combine("c:\", validFile.GetName()), True)
Dim fs As FileStream = New FileStream(validFile.FileName, FileMode.Open, FileAccess.Read)
Dim br As BinaryReader = New BinaryReader(fs)
photo = br.ReadBytes(System.Convert.ToInt32(fs.Length))
br.Close()
fs.Close()