Form with in a Panel

Post

Posted
Rating:
#1 (In Topic #509)
Enthusiast
AndyGable is in the usergroup ‘Enthusiast’
 Hi

Is it possible to display a form with in a Panel?

I am trying to replicate a MDI application and so far I have not worked out how to do this so I was thinking could I use a Panel to show the form in?
Online now: No Back to the top

Post

Posted
Rating:
#2
Avatar
Regular
stevedee is in the usergroup ‘Regular’

AndyGable said

…I am trying to replicate a MDI application and so far I have not worked out how to do this…

I haven't done it either (I'm sure others on this forum have…) but I think you need to look at the gb.form.mdi component: /comp/gb.form.mdi - Gambas Documentation

Come back if you are still struggling Andy and one of us will knock up some example code.
Online now: No Back to the top

Post

Posted
Rating:
#3
Avatar
Enthusiast
PJBlack is in the usergroup ‘Enthusiast’

Code (gambas)

  1. FORM.reparent(PANELNAME)
  2.  
  3. ' or
  4.  
  5. FORM.reparent(PANELNAME, X-POS, Y-POS)
  6.  
  7.  

… but as said above … this is not MDI …
Online now: No Back to the top

Post

Posted
Rating:
#4
Enthusiast
AndyGable is in the usergroup ‘Enthusiast’

stevedee said

AndyGable said

…I am trying to replicate a MDI application and so far I have not worked out how to do this…

I haven't done it either (I'm sure others on this forum have…) but I think you need to look at the gb.form.mdi component: /comp/gb.form.mdi - Gambas Documentation

Come back if you are still struggling Andy and one of us will knock up some example code.

I have been reading that all night and I still can not get it to work (am very new to Gambas) if someone would be kind enough to show me a example code I would be most appreciated
Online now: No Back to the top

Post

Posted
Rating:
#5
Avatar
Regular
stevedee is in the usergroup ‘Regular’

AndyGable said

stevedee said

AndyGable said

…I am trying to replicate a MDI application and so far I have not worked out how to do this…

I haven't done it either (I'm sure others on this forum have…) but I think you need to look at the gb.form.mdi component: /comp/gb.form.mdi - Gambas Documentation

Come back if you are still struggling Andy and one of us will knock up some example code.

I have been reading that all night and I still can not get it to work…

Not sure if I understand what you want to do, but to use the gb.form.mdi, add this component to a new project and then add a Workspace from the Special component category to the main form.

Now add 2 more forms with some visual components (e.g. labels, buttons) and add the 2 forms to the main form using the two lines of code in the image.

Image

(Click to enlarge)



I hope this helps.
Online now: No Back to the top

Post

Posted
Rating:
#6
Avatar
Guru
cogier is in the usergroup ‘Guru’
Here is a little program that may help you. Let us know how you get on.

<IMG src="https://www.cogier.com/gambas/Workspace.png"> </IMG>

Attachment
Online now: No Back to the top

Post

Posted
Rating:
#7
Enthusiast
AndyGable is in the usergroup ‘Enthusiast’
Many thanks for the samples

this is what I am trying to do

I have my background form (frmbackground)

<IMG src="http://support.algpos.co.uk/images_help/Background_1.png"> </IMG>

and then I have my First form that i display when the app starts up

<IMG src="http://support.algpos.co.uk/images_help/SignedOff.png"> </IMG>

So when the application is running the user would see

<IMG src="http://support.algpos.co.uk/images_help/ApPRun.png"> </IMG>
When the user Presses the Sign on key (for example A the system will then display with in the Background from the sign on screen) This is because the Form FrmSignedOff (as this has the code for the keyPress) has focus and not the FrmBackground

The icons on the side of the app changes depending on what the program is doing (that is why they are placed on the background form and not each individual form as some forms are powered via multiple menu select example User Menu -> Till Menu -> No Sale etc

This works perfectly in windows (as this screen examples are from my VB.net application) so I need to work out how to replicate this in Linux.
Online now: No Back to the top
1 guest and 0 members have just viewed this.