-----------------------------------------------------------
New Message on BDOTNET
-----------------------------------------------------------
From: BanupriyaVelmurugan
Message 3 in Discussion
I think the previous query is vague. So I am again posting this query.. The code
structure is as follows: Sample.aspx <script> function fn_save() {
document.test.method="post"
document.test.__VIEWSTATE.name = 'NOVIEWSTATE';
document.test.action="sample_save.aspx"
document.test.submit(); } </script> <FORM ID="smpo" RUNAT="server" > <table> <!--
Letter Scan -->
<TR>
<TD COLSPAN="3" align=right><INPUT TYPE="file" ID="column14" name="column14"
CLASS="copy" size="76" contenteditable=false runat="server"></TD>
<TD VALIGN="top" ALIGN="left" CLASS="copy"> Letter Scan</TD>
</TR>
<!--Remove Check Box-->
<tr >
<td colspan=3 align=right><asp:CheckBox ID="chkRemove" Visible="False"
Runat=server /></td>
<td align=left class=copy> <asp:Label ID="lblRemove" Visible=False
Runat=server /> </td>
</tr> <TR >
<TD COLSPAN="4" ALIGN="left"> <IMG id=Imgsave style="CURSOR: hand" border=0
alt="Click here to Save or Modify Port Master Details" onclick="fn_save()"
runat="server"> </TD>
</TR> </table> </form> Sample_save.aspx ---> Sample_save.aspx.vb
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load Dim strSQL As String
Dim reader As New readDatabase
Dim rs As SqlDataReader Dim sPhotoPath As String = "" rs =
reader.read("select * from letters where let_no='" & Request("column01") & "'")
If Not rs.HasRows Then
sPhotoPath = letter_save()
strSQL = "insert into letters....."
End If end sub '*** Function to save the scanned letter
Private Function letter_save() As String
If Request("column14") <> "" Then
Dim str1 As String
Dim UID As String
str1 = Request("column14")
str1 = str1.Substring(str1.LastIndexOf("\") + 1)
UID = "_" & Replace(Now().ToShortDateString, "/", "_") & "_" &
Replace(Replace(Now().TimeOfDay.ToString, ".", ""), ":", "_") & "."
str1 = Replace(str1, ".", UID)
column01.PostedFile.SaveAs(Server.MapPath(".\" & "let_upload" & "\" & str1))
Return str1
End If
End Function how to change the red colored statement to make the uploading reg
Banu
-----------------------------------------------------------
To stop getting this e-mail, or change how often it arrives, go to your E-mail
Settings.
http://groups.msn.com/bdotnet/_emailsettings.msnw
Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help
For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact
If you do not want to receive future e-mail from this MSN group, or if you received
this message by mistake, please click the "Remove" link below. On the pre-addressed
e-mail message that opens, simply click "Send". Your e-mail address will be deleted
from this group's mailing list.
mailto:[EMAIL PROTECTED]