Normal Topic Copying an Existing Form into another Database (Read 744 times)
Louis Galvao
Full Member
***
Offline


"Sufferin' Succatash"

Posts: 265
Location: Canada
Joined: Feb 14th, 2005
Copying an Existing Form into another Database
Jan 24th, 2006 at 1:49pm
Print Post Print Post  
I would like to create a new database within my application - easily done with Add New Database.

However, instead of re-inventing the wheel, the form layout will be exactly the same as the other form in the existing database.

Is there any way to copy this layout or it's elements to this new database form ?

Thanks,

Louis
  

Louis Galvao
Back to top
 
IP Logged
 
Louis Galvao
Full Member
***
Offline


"Sufferin' Succatash"

Posts: 265
Location: Canada
Joined: Feb 14th, 2005
Re: Copying an Existing Form into another Database
Reply #1 - Jan 24th, 2006 at 3:33pm
Print Post Print Post  
Further to this, I have created this database manually by applying names and settings, etc from the other database.

Now I have a GLCOA Application with two databases called RBA GLCOA and RBAH GLCOA.  Form names follow database names.

However, I am having a problem with my Print Form command button.  Part of the code is as follows:

vRun = @SelectTreeItem("RBA GLCOA!Search Update Menu!Record Commands!Printing Commands!Print Form")

Should I place the actual name of the application in the statement or do I have the database name in the wrong spot ?

Thanks,

Louis
  

Louis Galvao
Back to top
 
IP Logged
 
Ray the Reaper
Global Moderator
Members
Lantica Support
*****
Offline


The One & The Only

Posts: 2482
Joined: Aug 20th, 2003
Re: Copying an Existing Form into another Database
Reply #2 - Jan 24th, 2006 at 3:46pm
Print Post Print Post  
Hello Louis,

The correct code would simply be
Code
Select All
vRun = @SelectTreeItem("Search Update Menu!Record Commands!Printing Commands!Print Form") 



You do not need to speciffy the database name. That code will work on the current menu tree on the form that is open.

To answer your other question. Forms are bound to databases. You cannot copy a form from one database to another.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged
 
Louis Galvao
Full Member
***
Offline


"Sufferin' Succatash"

Posts: 265
Location: Canada
Joined: Feb 14th, 2005
Re: Copying an Existing Form into another Database
Reply #3 - Jan 24th, 2006 at 4:14pm
Print Post Print Post  
Ray:

Here I was thinking that I had to specify the database name for it to work. 

Thanks for clarifying that for me.

Do you see a feature coming in the next release to allow the ability to copy one database to another within the same application, or potentially importing from another application ?

Thanks,

Louis
  

Louis Galvao
Back to top
 
IP Logged