Bhavesh Vankar

Bhavesh Vankar

  • 734
  • 1.1k
  • 78.7k

Image is gone when selecting checkbox in C# Web Application.

Jan 1 2021 8:56 AM
When Select the checkbox then captured image is gone from image control. The Checkbox AutoPostBack Property is True when i set it False then the checkbox value not generation into Textboxes. What to do in this query..?
 
My image is coming from Page 1 to page 2 which is catpured by webcam....
 
My Page 1 code to pass captured image by webcam from page 1 to page 2
  1.  <script type="text/javascript">  
  2.     function passDetails() {  
  3.         if (window.opener != null && !window.opener.closed) {  
  4.             var vImage2 = window.opener.document.getElementById("vImage");  
  5.             window.opener.SetSource(document.getElementById("imgCapture").src);  
  6.         }  
  7.         window.close();  
  8.     }  
  9. </script>  
Page 2 code to recevie captured image by webcam from page 1 to page 2
 
vImage is my image control ID.
i have used hidden control to store image its id is vimagehidden
  1. <script>
  2. function SetSource(src)  
  3.         {  
  4.             document.getElementById("vImage").src = src;  
  5.             document.getElementById("vimagehidden").value = src;  
  6.         }  
  7.     </script>  
 

Answers (1)