I would like to know how you can upload images to a web site using ASP.Net. I'd like to add the file name of the image to the SQL Server DB. I'd like to learn about different options in ASP.Net using VB.Net. I've seen some tutorials on uploading images, but I am not interested in using a binary datatype. AdvertiserImage is just a varchar datatype. I'd like for it to stay that way. I also don't want to use Codebehind. Can someone please help me with the code for ASP.Net?
I'd like for the ASP.Net page to only allow .jpg or .gif files to be uploaded. I also would like to limit the size of the file to 50 KB.
I used ASP SmartUpload for an ASP Classic web application. Is it possible to use SmartUpload in ASP.Net or not?
Here's some parts of my code for the Classic ASP page:
I used ASP SmartUpload for an ASP Classic web application.
Here's some parts of my code for the Classic ASP page:
Here's some parts of my code for the Classic ASP page:
Code:
' Variables
' *********
Dim mySmartUpload
Dim file
dim rs, connectionString, databaseName, path
dim strSQL, IDNumber
dim NextPage, intCount
dim fic, FileName
' Object creation
' ***************
Set mySmartUpload = Server.CreateObject("aspSmartUpload.SmartUpload")
intCount=0 'initialize the counter
'component creation
Set mySmartUpload= Server.CreateObject("aspSmartUpload.SmartUpload")