Print Page | Close Window

Skin unloads on UnloadAllForms Event

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Skin Framework
Forum Description: Topics Related to Codejock Skin Framework
URL: http://forum.codejock.com/forum_posts.asp?TID=5587
Printed Date: 04 November 2024 at 4:37pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Skin unloads on UnloadAllForms Event
Posted By: joeliner
Subject: Skin unloads on UnloadAllForms Event
Date Posted: 23 November 2006 at 10:31am
Hi,
 
I am using an event to unload all the forms in an mdimain:
 
Public Sub UnloadAllForms()
   Dim Frm as Forms
      For Each Frm in Forms
       Unload Frm
      Set Frm = Nothing
   Next Frm
End Sub
 
When this code is triggered on an MDI Form that has skin control applied with one of the skin styles, it unloads the skin leaving the default  windows theme. Is there a possible fix for this?
 
Thanks.



Replies:
Posted By: Oleg
Date Posted: 24 November 2006 at 4:13am
Hello,
 
To Fix what? You destroy form that has Skin Control and want Skin still be applied?


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: joeliner
Date Posted: 24 November 2006 at 6:41am
Sorry, gave the wrong code. This is how i have it. MDIMain is the form that has the skinframwork control.

Dim Form As Form
   For Each Form In Forms
    If Form.Name <> "MDIMain" Then Unload Form
      Set Form = Nothing
   Next Form



Posted By: Oleg
Date Posted: 24 November 2006 at 8:30am
Hello, I inserted such code in our sample, added SKinFramework and all work right. Check that only MDIMain has SkinFramework object and it doesn't  destroyed in this call.

-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: joeliner
Date Posted: 01 December 2006 at 8:46am
Hi oleg,

I figured out where my scenario differs: I have a seperate independent form that has a skin control which in turn calls the MDI form and unloads completely from memory using code(set frm = nothing)

When i run the unloadAllForms event, it unloads the skin, so is it that i shouldt use two skinframeworks in a project?

I tried the same with The MDISample:

-I added a form and a button with the skin control.
-The button calls the mdi form and unloads
-I call UnloadAllForms. 
-The skin unloads and leaves the default windows theme

Thanks.


Posted By: Oleg
Date Posted: 01 December 2006 at 8:57am
Hi,
only one SkinFramework control must exists.


-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: joeliner
Date Posted: 01 December 2006 at 9:13am
ok.

thanks



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net