X - Can't backfocus application after hide form?

after hide the form, the main application [Office] is not activated but it returns to visualstudio screen (I had to move the mouse down to the taskbar and click app to active. is it a mistake?) . If I change the inherit sfform to form. Everything works normally.

18 Replies

SS Susmitha Sundar Syncfusion Team June 25, 2020 02:18 AM UTC

Hi khanh dang, 
 
Thank you for using Syncfusion controls. 
 
We are not clear with your reported case “Can't backfocus application after hide form. Can you please provide any video reference for this? 
 
It will be helpful for us to check on it and provide you the solution at the earliest.   
 
Regards, 
Susmitha S 



TG The GridLock June 25, 2020 04:23 AM UTC

Hi susmitha,
my video  :
1. sfform
2. form
assign button click event:
 Private Sub button_Click(sender As Object, e As EventArgs)  
        Me.Hide()
        Dim rngExport As Excel.Range =TryCast(Exapp.InputBox("Select area:", " My dialog ", , , ,,, Type:=8), Excel.Range)
        Me.Show()
 End Sub


MA Mohanram Anbukkarasu Syncfusion Team June 26, 2020 01:32 PM UTC

Hi khanh dang, 

Thanks for the update. 

We have prepared a sample to replicate your scenario. Unfortunately we are unable to reproduce the issue in our end. The sample we have used to check this issue is available in the following link. 


Please have a look at this sample and let us know if we have missed any customization you have done in your application or try to reproduce  the issue in the above given sample. It will be helpful for us to find the exact cause for the issue and to provide an exact solution at earlier. 

Regards, 
Mohanram A. 



TG The GridLock June 26, 2020 06:51 PM UTC

Hi Mohanram ,
I have checked this, it(ssform) works with form.show() / form.showdialog() but not with form.show(IWin32Window)
please check: samplefile (In my case it didn't work the first time, but somehow this sample had to come a second time to not work)


SS Susmitha Sundar Syncfusion Team June 29, 2020 02:51 PM UTC

Hi khanh dang, 
 
Thank you for the update. 
 
We were able to replicate your reported scenario” form.show(IWin32Window) not works for second time. Currently, we are analyzing this with our source. We will validate and update you details on or before July 1, 2020. 
 
We appreciate your patience until then.   
   
Regards,   
Susmitha S   



TG The GridLock June 30, 2020 07:35 AM UTC

Hi susmitha, I want you to check a bit:
that's with show () and showdialog () doesn't always work, and not just when form.hide but form.close doesn't return.
because I created quite a lot of ssform and custom titlebar, so if I switch back to the form I will have to redesign the interface for all.
I hope there is a solution soon for this.
I can now use SetForegroundWindow to bring the screen back but it causes the screen flicker.


SS Susmitha Sundar Syncfusion Team July 1, 2020 04:39 PM UTC

Hi khanh dang,  
  
Thank you for the update.  
 
Did you get the same issue with form.Show() and form.showdialog() occasionally? If so, we get the issue only with form.showdialog. form.show() works fine all the time. Can you please share in which case you are facing this issue? 
 
It will be helpful for us to check on it and provide you the solution at the earliest.   
 
Query : form.show(IWin32Window)  and form.showDialog() not works for second time 
 
Currently, we are analyzing this with our source. We will validate and update you details on or before July 3, 2020.  
  
We appreciate your patience until then.    
 
Regards, 
Susmitha S 



SS Susmitha Sundar Syncfusion Team July 3, 2020 03:10 PM UTC

Hi khanh dang,  
 
Thank you for your patience. 
 
       We have created bug report for the reported issue “Can't backfocus application after hide form. Can you please confirm your Syncfusion version? We will provide patch or include the fix in our NuGet release based on that version.  
  
You can track the status of this report through the following feedback link,   
 
 
Note: The provided feedback link is private, and you need to login to view this feedback.   
 
Regards, 
Susmitha S 



TG The GridLock July 3, 2020 10:12 PM UTC

hi susmitha,
It was strange that I created a second version of the form, but when using form.showdialog. it still not comeback, seems to be having problems with the inputbox method
My current version is 18.1.042. thanks.


MA Mohanram Anbukkarasu Syncfusion Team July 7, 2020 09:54 AM UTC

Hi Khanh dang, 
 
Thanks for the update. 
 
We will consider both form.show(IWin32Window)  and form.showDialog() cases while fixing the issue. We will provide the patch for the fix in your version 18.1.0.42 on July 17, 2020. We appreciate your patience until then. 
 
Regards, 
Mohanram A.



TG The GridLock July 7, 2020 12:20 PM UTC

Hi Mohanram .
Here is a bit of a clue, I have partially overcome. 


MA Mohanram Anbukkarasu Syncfusion Team July 8, 2020 08:04 AM UTC

Hi Khanh dang,  
  
Thanks for the update. 

We have forwarded this to our development team. They will consider this while fixing the issue.  As promised we will provide the patch on 17th July 2020. 

Regards, 
Mohanram A. 



MA Mohanram Anbukkarasu Syncfusion Team July 17, 2020 02:20 PM UTC

Hi Khanh dang,   

We regret for the inconvenience.  

We have completely analyzed in our source for the cause for the issue “Can't backfocus application after hide form”. On analysis we found that the reported issue occurs due the customization we have included in the SfForm for providing Shadow support. We are able to reproduce the same issue in the framework form and we have raised the below query regarding this in developer community. 


We have not yet received any solution for this query. We will check with developer community and update you with proper details once they provide any update on the query. 

We appreciate your patience until then. 

Regards, 
Mohanram A. 



TG The GridLock July 18, 2020 07:47 AM UTC

Ok, Mohanram!


MA Mohanram Anbukkarasu Syncfusion Team July 20, 2020 01:00 PM UTC

Hi Khanh dang, 

Thanks for the update.  

As promised we will update you with proper details once they provide any update on the query.  

Regards,  
Mohanram A. 



MA Mohanram Anbukkarasu Syncfusion Team August 12, 2020 12:30 PM UTC

Hi Khanh dang, 

Thanks for your patience.  

We have received response for the MSDN query. They have accepted that this as a bug also suggest a work around to resolve this. It is not possible to use this work around in source level However it is possible to use the suggested work around to resolve the issue with sample level changes. The sample we have prepared using the workaround is available in the following link for your reference.  


Please have a look at this sample and let us know if you require further assistance from us.  

Regards, 
Mohanram A. 




TG The GridLock August 14, 2020 12:01 PM UTC

Hi, Mohanram
Thanks for the work, I know these code worked however this solution caused the screen to vibrate with every click. I need to interact with excel regularly so the process of hiding forms is a lot so I switched back to using Inherit Forms.
The problem has been resolved for me now.


MA Mohanram Anbukkarasu Syncfusion Team August 17, 2020 12:21 PM UTC

Hi Khanh dang, 

Thanks for the upate.  

We are glad to know that the reported problem has been resolved at your end. Please let us know if you have any further queries on this. 

Regards, 
Mohanram A. 


Loader.
Up arrow icon