Forums

This topic is locked

Setting "none selected" value using PureASPupload

Posted 26 Aug 2001 01:15:08
1
has voted
26 Aug 2001 01:15:08 Radion Auto posted:
i have a form that adds a record to a database, as well as uploading 11 images using pureASPupload, ive set it up so that it is not required for the user to select a file for all of the fields, as they are all optional. The problem i have is that it just adds a zero length string to the database if the user doesent select a field, and i want it to submit a value of say "imageNA.jpg" if the user chooses not to select an image, can anyone tell me how to do this, im using pureASPupload version 2 beta

Thanks
Radion

Replies

Replied 26 Aug 2001 12:50:49
26 Aug 2001 12:50:49 Viktor Farcic replied:
You can use IF... Then... statement.

<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
i have a form that adds a record to a database, as well as uploading 11 images using pureASPupload, ive set it up so that it is not required for the user to select a file for all of the fields, as they are all optional. The problem i have is that it just adds a zero length string to the database if the user doesent select a field, and i want it to submit a value of say "imageNA.jpg" if the user chooses not to select an image, can anyone tell me how to do this, im using pureASPupload version 2 beta

Thanks
Radion


<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>

Replied 26 Aug 2001 20:30:08
26 Aug 2001 20:30:08 Radion Auto replied:
erm, use the IF and THEN statements how exactly - i do very little hand coding, infact only edit things that i need to, so i have no idea how to use the IF and THEN statements, how about an example??

Replied 27 Aug 2001 00:23:25
27 Aug 2001 00:23:25 Owen Eastwick replied:
Something Like:

ImagePath = Request("TheImagePathTextFieldName"

If ImagePath = "" Then
ImagePath = "D:/WebSiteDirectory/UploadDirectory/imageNA.jpg"
End If


Regards

Owen


Reply to this topic