Normal Topic Array Index Overflow... (Read 2212 times)
Cliff
Full Member
***
Offline



Posts: 126
Location: New Hampshire
Joined: May 5th, 2006
Array Index Overflow...
May 12th, 2006 at 7:14pm
Print Post Print Post  
We are trying to utilize the wordmerge utility that is packaged with Sesame.  We have a very simple translated Q&A database that we have created a merge docuement for.  Everything seems to run well until we select the merge document, and then select the merge option for "this record only".  We receive the following error: Array index overflow.  When we click ok a subsequent error displays: A runtime SBASIC error has occurred please close this form and repair the condition before continuing.

There is nothing in the "server log" that indicates where or what the error could possibly be.

Any and all help is very much appreciated.

Cliff
  
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: Array Index Overflow...
Reply #1 - May 12th, 2006 at 7:25pm
Print Post Print Post  
Hello Cliff,

That error will occur if you are trying to access more blocks of an array than it has. For example, trying to access the 6th block of a array that only has 5.

At the top of the code an array is delcared. The line is
Code
Select All
Var F as array[25] of string 



Down below the F[] array is filled in with the list of element names available for merging. Take the biggest number that you used down there, add one to it, and put it up in the declaration of the array.

Example: If your code says
Code
Select All
F[63]="SomeElement" 

and 63 is the highest number used, you will want to change the declaration from
Code
Select All
Var F as array[25] of string 

to:
Code
Select All
Var F as array[64] of string 



-Ray
  

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



Posts: 126
Location: New Hampshire
Joined: May 5th, 2006
Re: Array Index Overflow...
Reply #2 - May 12th, 2006 at 7:34pm
Print Post Print Post  
Thanks Ray...will try and will let you know how we make out...

Much appreciated...

Cliff
  
Back to top
 
IP Logged
 
Cliff
Full Member
***
Offline



Posts: 126
Location: New Hampshire
Joined: May 5th, 2006
Re: Array Index Overflow...
Reply #3 - May 12th, 2006 at 7:43pm
Print Post Print Post  
Thanks Ray...that solved "that" problem, however, we have a new one...

When the merge document opens up the merge fields are populated with the field descriptors that we used in to program the wordmerge command button with.

That is instead of the number that shows up in the database form for "POLCIY_NO" we actually just get "POLICY_NO" in the merge document.  It should be "L1100" in this particular instance.

Again...your help is very much appreciated...

Cliff
  
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: Array Index Overflow...
Reply #4 - May 12th, 2006 at 7:56pm
Print Post Print Post  
Hello Cliff,

Which version of word do you have?

If it is Word 2000
Click Tools
Choose Mail Merge
Click the button that just says "Merge..."
In the "Merge to:" drop down choose New Document
Click the "Merge" button
Now do you see your data?

-Ray
  

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



Posts: 126
Location: New Hampshire
Joined: May 5th, 2006
Re: Array Index Overflow...
Reply #5 - May 12th, 2006 at 8:09pm
Print Post Print Post  
Yes!  However, I thought that this would have automatically appeared?  The demo files that came bundled with "wordmerge" automatically populated the fields when tested...

Am I missing something...

Again...appreciate your patience with me on this...

Cliff
  
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: Array Index Overflow...
Reply #6 - May 12th, 2006 at 8:32pm
Print Post Print Post  
Hello Cliff,

If you press ALT + F9 in Word with the merge document open it will toggle from displaying the field names to displaying the first set of data. I believe if you save the document like this it will display that way from now on when you merge.

-Ray
  

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



Posts: 126
Location: New Hampshire
Joined: May 5th, 2006
Re: Array Index Overflow...
Reply #7 - May 25th, 2006 at 12:46pm
Print Post Print Post  
Thanks again Ray...your assistance and patience is very much valued...

Cliff
  
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: Array Index Overflow...
Reply #8 - May 25th, 2006 at 1:06pm
Print Post Print Post  
You are welcome Cliff.

-Ray
  

Raymond Yoxall Consulting
ray.yoxall@gmail.com
ryoxall@lantica.com
Sesame Applications, Design and Support
Back to top
IP Logged