Normal Topic Form Program Export/Import problem (Read 441 times)
Bob_Hansen
Senior Member
Members
*****
Offline


WOW, They have the Internet
on computers now!

Posts: 1861
Location: Salem, NH
Joined: Nov 24th, 2002
Form Program Export/Import problem
Oct 26th, 2007 at 6:41am
Print Post Print Post  
I needed a close duplicate of an existing form, in a different database, same application.

I selected several elements on the existing form.
Went to the new form, used Copy Selected Elements, seemed to work OK.
I then renamed the elements to match the names I wanted on the new form, different from labels.

I then went back to existing form, and exported all program to a file.
Went back to the new form, and imported the exported program file.
Quick glance looked like all was OK.
BUT .... it turns out the none of the program code OnFormExit came over.
I went to the existing form, copied that code to clipboard and pasted into new form, all is OK.

BUT .... I looked at the exported file in text editor and the "missing" code was in the exported file.

The only anomaly that I saw was that in the existing form Program Editor, the first line in the OnFormExit section was blank.  My comments/code did not start until line 2 or 3.  Is it possible that contributed to the problem?  I still have the export file available if an analysis is needed. 

  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
Back to top
IP Logged
 
Ben
Lantica Support
*****
Offline



Posts: 218
Joined: Apr 7th, 2005
Re: Form Program Export/Import problem
Reply #1 - Oct 26th, 2007 at 3:39pm
Print Post Print Post  
The element names must be an exact match to the programming you are  trying to import. Sesame can't guess at where the programming is meant to go. The solution is to Import the programming before you start changing the names of the elements.
  
Back to top
IP Logged
 
Bob_Hansen
Senior Member
Members
*****
Offline


WOW, They have the Internet
on computers now!

Posts: 1861
Location: Salem, NH
Joined: Nov 24th, 2002
Re: Form Program Export/Import problem
Reply #2 - Oct 26th, 2007 at 8:46pm
Print Post Print Post  
Thanks for feedback Ben, but this time I don't think the diagnosis is correct.

The code that did not come in was OnFormExit, but the code for OnFormEnter did come in, so this is not an example where element names were not correct.  It was brought into the FORM section, not an element.  And the form name must be correct, or the OnFormEnter code would not have appeared.

Maybe you can check with Ray who has been working with me offline on this application that is suffering from some random issues that I associate with XML/export-import/CopySelectedElements/Color issues.  I susepct that this is related.

Thanks for listening...
  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
Back to top
IP Logged