Page Index Toggle Pages: 1 [2]  Send Topic Send Topic Print Print
Hot Topic (More than 10 Replies) [Fixed Cannot import XML forms (Read 2500 times)
Hammer
YaBB Administrator
Lanticans
*****
Offline


Fire bad. Tree pretty.

Posts: 3436
Location: Ohio
Joined: Nov 22nd, 2002
Re: Cannot import XML forms
Reply #15 - Sep 20th, 2007 at 5:55pm
Print Post Print Post  
We will indeed do diagnosis, but regardless of what we find, we are not releasing a solution within the next day or so. As it sounds like you need an immediate workaround, Carl's suggestion sounds likely.
  

- Hammer
The plural of anecdote is not data.
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: Cannot import XML forms
Reply #16 - Sep 20th, 2007 at 7:16pm
Print Post Print Post  
OK Erika, thanks for the minimum time frame.  I will have to plan and adjust accordingly.  I was hoping a solution would be really quick. 

PS, I would be willing to take an unofficial patch before a formal release was ready.   We could call it a beta test.
  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
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: Cannot import XML forms
Reply #17 - Sep 24th, 2007 at 11:06pm
Print Post Print Post  
Hammer wrote on Sep 20th, 2007 at 5:42pm:
Quote:
or just export the entire programming for the form, delete all programming, export form to XML, import XML form to new location, and import programming back into the form after it's in its new location.

Since the problem characters seem to be contained in your code, have you tried Carl's other suggestion?

That still fails.  I looked inside the XML export for the form, and it includes functions code that was deleted from  the GLOBAL code.  GLOBAL secrion is definitely blank.  Must be getting from another form?

In any case, I used a text editor and removed the programming section from the XML file.  It was between tags for <specs> and </specs>.  At that point, I did import again, and the file was accepted.  I then opened up the form Program Editor and imported the code that had been exported earlier. 

So, I am able to use brute force to import XML form, but still see a major bug in the Export XML area.
I am not sure I am causing other problems by manually editing the XML file.  Taking some risks here.  Problem is these files are not for me, so I don't end up with the inherent possible problems.

So steps are:
1.  Copy the form to be exported to XML
2.  Export the programming
3.  Delete all programming.  Many sections to be done, may be import a blank file will be quicker ?)
4.  Save Programming Design
5.  Export form to XML
6.  Open XML file with text editor.
7.  Locate unwanted programming between <specs> .... </specs> and delete all in between, including those tags.
8.  Save the modified XML file.
9.  Open destination application.
10.  Use Database Manager, open the destination database.
11.  Import modified XML file.
12.  Open form design, open Program Editor, import the program file that was exported earlier.
13.  Close editor and Save Layout Design.
14.  Relink Form as needed,
15.  Save Layout Design.
16.  Test and troubleshoot as needed.
  



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


Fire bad. Tree pretty.

Posts: 3436
Location: Ohio
Joined: Nov 22nd, 2002
Re: Cannot import XML forms
Reply #18 - Sep 24th, 2007 at 11:43pm
Print Post Print Post  
Bob_Hansen wrote on Sep 24th, 2007 at 11:06pm:
3.  Delete all programming.  Many sections to be done, may be import a blank file will be quicker ?)

FWIW: Version 2 has a Delete All Programming choice that should ditch all the programming in a layout in one step.

Also, I have to check this, but I believe that code between the spec tags may be a saved mass update attached to the form. I'll have to look at source to confirm that though. There may be more than one instance of those tags.
  

- Hammer
The plural of anecdote is not data.
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: [BRF] Cannot import XML forms
Reply #19 - Sep 25th, 2007 at 3:03am
Print Post Print Post  
Thanks for pointing out "Delete All Programming".  Don't think I recall seeing that before.  So much new stuff!  That is great for this problem.

Erika, twp of these that are failing are really BASIC menu forms.  One has four buttons, no Mass Updates, no bound elements, buttons make calls to SelectTreeItems or ExitSesame.  Another form is simpler, only has one button that calls the four-button form.  I do have other more complex forms with multi tabs, subforms, 20+ buttons.  But don't even want to start until I can get these resolved.

I did do the two noted above manually, minor things to go through.  Still avoiding the larger one since even when "programming was removed", programming was still included in the XML file.  All of these are coming from the same application. 
  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
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: [BRF] Cannot import XML forms
Reply #20 - Sep 25th, 2007 at 1:41pm
Print Post Print Post  
Bob_Hansen wrote on Sep 25th, 2007 at 3:03am:
One has four buttons, no Mass Updates, no bound elements, buttons make calls to SelectTreeItems or ExitSesame.  Another form is simpler, only has one button that calls the four-button form.  I do have other more complex forms with multi tabs, subforms, 20+ buttons.  But don't even want to start until I can get these resolved.


Hello Bob

If you still have an original copy of one of the XMl files could you look inside the <spec> braces for where you saw that code and above the code you will see an entry that says <type>. I need to know what it says in that entry.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
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: [BRF] Cannot import XML forms
Reply #21 - Sep 25th, 2007 at 2:27pm
Print Post Print Post  
Here is a section where I removed code.  Has extra lines that are part of the code that should not be here:
Quote:
           </event>
     </element>
     <specs>
           <spec>
                 <name>Data Dictionary</name>
                 <type>5</type>
                 <field_specs>
                       <field_name>Temp</field_name>
                       <value>/*
Does not fill in name of Database - Fixed here
Does not handle new Read Only conditions - Fixed here
Need Positions and sizes in reversed order to match Element Editor - Fixed here.
Uses MSIE vs. default browser. - Fixed here.
Should include @Platform for Sesame Version.- Fixed here

Looks like Type = 5.

And I also recognize this code as coming from a Mass Update Spec in the application.  That is the code for Data Dictionary.  Those first lines are comments as I was modifying the Data Dictionary code.

Don't know why it is coming in the FORM export, would expect it with the Application export, but not the form.  This looks like the specific problem, getting Mass Update Code, not necessarily the "<=" values, they just happen to be in the code.  Carl had mentioned his problem code was also associated with Mass Update.  I feel good that a solution is close at hand.
  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
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: [BRF] Cannot import XML forms
Reply #22 - Sep 25th, 2007 at 2:49pm
Print Post Print Post  
Bob_Hansen wrote on Sep 25th, 2007 at 2:27pm:
Don't know why it is coming in the FORM export, would expect it with the Application export, but not the form.  This looks like the specific problem, getting Mass Update Code, not necessarily the "<=" values, they just happen to be in the code.  Carl had mentioned his problem code was also associated with Mass Update.  I feel good that a solution is close at hand.


Type 5 is a Mass Update spec. For future reference, The actual Form events that are programmed in Sdesigner show up inside the <Event> </Event> tags.

All specs are attached to the form from which they were created so the get exported with that form as they are one of it's objects. The problem is that the Mass Update code is not being parsed the same as the regular programming is being parsed, Not that the Specs are included as part of the form when exported.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
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: [BRF] Cannot import XML forms
Reply #23 - Sep 25th, 2007 at 3:13pm
Print Post Print Post  
AHA!
Now I see that the MassUpdate Spec is associated with the simple Menu Form. I just went into the preview mode, opened the menu tree that is normally closed for the menu form, and looked at the Spec Manager.  Even though there are no records, there was a Mass Update spec for the Data Dictionary.

Apparently I had inserted it there at one time, months ago, and then copied it to a form with bound elements, visible Menu Tree for Mass Updates, etc.  Never removed it from original menu form.  So I knew the Mass Update was associated with another form, (one of the complex forms that I cannot import), but thought this menu form was only buttons.

So now I see, that any Saved Specs associated with the form comes over with the XML.  Now that I said that, it is so obvious.  I was thnking that the layouts and programming was exported to XML, I never though of the Spec Manger codes.  That is great, that is how it should be, everything gets exported.

Now you only need to fix the parsing of the MassUpdate programming and we are good to go!

PS, you mentions Type 5 = Mass Update.  Is there a reference of the Type value meanings available somewhere? 
.........  AHhhh, so ,  <specs> ..... </specs> are the elements associated with Spec Manager! 
This is scary, I am beginning to understand the content of the Sesame XML files.


Thanks for help and explanation.
  



Bob Hansen
Sesame Database Manager Professional
Sensible Solutions Inc.
Salem, NH
603-898-8223
Skype ID = sensiblesolutions
Back to top
IP Logged
 
Page Index Toggle Pages: 1 [2] 
Send Topic Send Topic Print Print