<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>Array</TITLE>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<STYLE type=text/css>BLOCKQUOTE {
        PADDING-BOTTOM: 0px; PADDING-TOP: 0px
}
DL {
        PADDING-BOTTOM: 0px; PADDING-TOP: 0px
}
UL {
        PADDING-BOTTOM: 0px; PADDING-TOP: 0px
}
OL {
        PADDING-BOTTOM: 0px; PADDING-TOP: 0px
}
LI {
        PADDING-BOTTOM: 0px; PADDING-TOP: 0px
}
</STYLE>

<META content="MSHTML 6.00.2715.400" name=GENERATOR></HEAD>
<BODY bgColor=#ffffff>
<DIV>Yves,</DIV>
<DIV> </DIV>
<DIV>To know how many lines are stored in the custom propery you can reference 
the keys() function and get a line count, as in </DIV>
<DIV> </DIV>
<DIV>  put the number of lines of keys(cName) into numKeys</DIV>
<DIV><BR>Assuming you have two keys per "index" (one is "student" and one is 
"prof"), you would divide 'numKeys' by 2, and then add 1 for the next index 
number:</DIV>
<DIV> </DIV>
<DIV>  put (numKeys/2)+1 into nextIndexNum</DIV>
<DIV> </DIV>
<DIV>Then, set your array to the next element:</DIV>
<DIV> </DIV>
<DIV>  set the cName[student,nextIndexNum] of <object> to 
"Peter"</DIV>
<DIV> </DIV>
<DIV>Note that variables can be used inside the array definition (nextIndexNum), 
but if you mistype it, it will use the string as part of the array. For 
example:</DIV>
<DIV> </DIV>
<DIV>  put 2 into Fred</DIV>
<DIV>  set the cName[student,Fred] of this stack to "Ken"</DIV>
<DIV> </DIV>
<DIV>'Fred' will be recognized as a variable and will be resolved to '2', which 
will set the cName[student,2] of this stack. However, if I do this:</DIV>
<DIV> </DIV>
<DIV>  put 2 into Fred</DIV>
<DIV>  set the cName[student,Fredd] of this stack to "Ken"  -- 
Mistyped 'Fred'</DIV>
<DIV> </DIV>
<DIV>'Fredd' will not be recognized as a variable and will therefore not be 
resolved and will be used directly, setting the cName[student,Fredd] of this 
stack.</DIV>
<DIV> </DIV>
<DIV>Hope this helps,</DIV>
<DIV> </DIV>
<DIV>Ken Ray<BR>Sons of Thunder Software<BR>Email: <A 
href="mailto:kray@sonsothunder.com">kray@sonsothunder.com</A><BR>Web Site: <A 
href="http://www.sonsothunder.com/">http://www.sonsothunder.com/</A></DIV>
<DIV> </DIV>
<DIV> </DIV>
<DIV>----- Original Message ----- </DIV>
<BLOCKQUOTE dir=ltr 
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV 
  style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B> 
  <A title=yvescoppe@skynet.be href="mailto:yvescoppe@skynet.be">yves COPPE</A> 
  </DIV>
  <DIV style="FONT: 10pt arial"><B>To:</B> <A 
  title=use-revolution@lists.runrev.com 
  href="mailto:use-revolution@lists.runrev.com">use-revolution@lists.runrev.com</A> 
  </DIV>
  <DIV style="FONT: 10pt arial"><B>Sent:</B> Sunday, May 05, 2002 10:04 AM</DIV>
  <DIV style="FONT: 10pt arial"><B>Subject:</B> Array</DIV>
  <DIV><BR></DIV>
  <DIV>Hello,</DIV>
  <DIV><BR></DIV>
  <DIV>A few weeks ago, I posted a message without answer. So I come again 
  :</DIV>
  <DIV><BR></DIV>
  <DIV><FONT face="Courier New" color=#000000 size=+2><BR><BR></FONT></DIV>
  <DIV><FONT face="Courier New" color=#000000 size=+2>I have a custom Property 
  Set which contains an array.</FONT></DIV>
  <DIV><FONT face="Courier New" color=#000000 size=+2>the name of thz set is 
  "cName"</FONT></DIV>
  <DIV><FONT face="Courier New" color=#000000 size=+2>the keys content 
  :</FONT></DIV>
  <DIV><FONT face="Courier New" color=#000000 
  size=+2>student,1<BR>prof,1<BR>Student,2<BR>prof,2<BR><BR><BR>each line gives 
  a name :<BR><BR>example :<BR>student,1  ===> 
  John<BR>prof,1     ===> Tom<BR></FONT></DIV>
  <DIV><FONT face="Courier New" color=#000000 size=+2>I'd like to add some data 
  on the existing custom set</FONT></DIV>
  <DIV><FONT face="Courier New" color=#000000 size=+2>so I start with a new 
  handler</FONT></DIV>
  <DIV><FONT face="Courier New" color=#000000 size=+2>I have to call the custom 
  property, know how much lines are stored in the custom and add one 
  line</FONT></DIV>
  <DIV><FONT face="Courier New" color=#000000 size=+2>for example :</FONT></DIV>
  <DIV><FONT face="Courier New" color=#000000 size=+2>Peter = 
  student,3</FONT><BR><FONT face="Courier New" color=#000000 
  size=+2></FONT></DIV>
  <DIV><FONT face="Courier New" color=#000000 size=+2>How to proceed 
  ?</FONT></DIV>
  <DIV><FONT face="Courier New" color=#000000 
  size=+2><BR>thanks.</FONT></DIV><X-SIGSEP><PRE>-- 
</PRE></BLOCKQUOTE></X-SIGSEP></BODY></HTML>