im using this code:
aspx page
function post_value() {
var lblUpload = document.getElementById("upFile").value;
window.opener.form1.upFile.value = lblUpload;
window.close();
}
aspx.cs page
protected void Button4_Click(object sender, EventArgs e)
{
if (upFile.HasFile)
{
upFile.SaveAs(Server.MapPath("upload_file") + @"\" + upFile.FileName);
Label1.Text = "File Uploaded: " + upFile.FileName;
}
else
{
Label1.Text = "No File Uploaded.";
}
this.Button4.Attributes.Add("onclick", "javascript:post_value()");
how can get the value of the the file upload control and send it to a label in a grid
plsss help me
2 Replies
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Amit ChoudharyPosted Mar 9, 2010, 1:34 AM
here is the code how to access the master page control in child page.
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
((Label)Master.FindControl("Label1")).Text = "Hello World";
}
}
send me your project i will write the code for what you want.
imbet luguePosted Mar 9, 2010, 10:14 PM