Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8417371
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T02:01:27+00:00 2026-06-10T02:01:27+00:00

I have a styled file Upload laying on top the vanilla asp.net fileupload control,

  • 0

I have a styled file Upload laying on top the vanilla asp.net fileupload control, which is hidden.
If the user comes back to edit his chosen files, there are buttons to view the file or delete it from the dataset; In addition the control is hidden.
However the fake fileupload remains visible.
I have written a custom method to call Jquery from Code behind, but I’m lacking the Jquery skills to hide this fake control and show it on demand.

The task is: Hide the fileupload which is contained in a and show it again if the user clicks on “remove file” & set the control to visible again, so he can choose another file.

Kind regards.

edit: the c# Method containing the Jquery code looks like this right now:

runjQueryCode(@"$(document).ready(function() {
                 $('#" + Btn_removeFile.ClientID + @"').click(function(){
                    $('.fakefile').show();
                    $('"+ fu.ClientID +@"').show();
                  });
                    $('.fakefile').hide();
                    $('"+ fu.ClientID +@"').hide();
                  });");
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T02:01:29+00:00Added an answer on June 10, 2026 at 2:01 am

    What you can do is as follow…It will show the FileUpload if it is already hidden and will hide if it is already visible…

    CodeBehind:-

    Btn_removeFile.Attributes["onClick"] = "ShowHideFileUpload('"+fu.ClientID+"');" 
    

    Javascript:-

    function ShowHideFileUpload(fuID)
    {
       if($(fuID).is(":visible"))
       {
            $('.fakefile').hide(); 
            $(fuID).hide(); 
       }
       else
       {
           $('.fakefile').show(); 
           $(fuID).show();     
       }    
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I know how to upload with ASP.net's FileUpload control. What I want to do
I am encountering difficulties when attempting to use the ASP.NET File upload control. What
In a ASP.NET C# website I have an input that uploads a file to
I have got an input file upload , need to check which file is
I have a HTML form ( upload.htm ) with a HTML file upload control
I am trying to implement Gmail style drag-and-drop file upload in ASP.NET MVC. I
I have a a form which contains a file input, upload button and cancel
I have a CSS file, which contain the style information of my web. Some
I have an ordered list which I have styled in two ways: Coloured the
I'm writing my first GWT project. I have a form with label, file upload

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.