Question: 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();
                  });");

```

Answer: 
You need to use onSaveInstanceState to save your data because data get lost when orientation changes. Google onSaveInstanceState and if you still have problems ask.
Activity's are destroyed and recreated when the screen orientation is changed.

You can either lock it to one orientation.

or

Save the state of your application using [onSaveInstanceState](http://developer.android.com/reference/android/app/Activity.html#onSaveInstanceState%28android.os.Bundle%29) then restore it in onCreate or [onRestoreInstanceState](http://developer.android.com/reference/android/app/Activity.html#onRestoreInstanceState%28android.os.Bundle%29)