Ah got it its your TLocateOptions<br><br>
<div><span class="gmail_quote">On 19/05/06, <b class="gmail_sendername">Paul A Norman</b> &lt;<a href="mailto:paul.a.norman@gmail.com">paul.a.norman@gmail.com</a>&gt; wrote:</span>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
<div>
<div>Dear Phil,</div>
<div>&nbsp;</div>
<div>Just to help me understand, what is the story with the empty member [] ? It appears to be part of the locate function call, is there a bracket missing? Is it meant to be an array member?</div>
<div>&nbsp;</div>
<div>Otherwise, not sure but I know that there are issues when using <font size="2">VarArrayCreate Routine (which you are not <em>directly </em>doing) </font>with &quot;<font size="2">The element type of the array, given by the VarType parameter, is a variant type code. This must be one of the constants defined in the System unit. It cannot include the varArray or varByRef bits. The element type cannot be varString or a custom Variant type. To create a variant array of strings use the varOleStr type code. &quot; 
</font><br><br>&nbsp;</div></div>
<div><span class="e" id="q_10b4a2da1dbfc157_1">
<div><span class="gmail_quote">On 19/05/06, <b class="gmail_sendername">Phil Scadden</b> &lt;<a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:p.scadden@gns.cri.nz" target="_blank">p.scadden@gns.cri.nz
</a>&gt; wrote:</span> 
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Got a strange one.<br><br>This line:<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ADOTable1.Locate('Alarmtime',VarArrayOf([dt]),[]);<br><br>generates 'Could not convert variant of type (Array Variant) into type (Olestr). 
<br>(dt is TDateTime)<br><br>Any ideas what is going on???<br><br><br>----------------------------------------------------------<br>Phil Scadden, Institute of Geological and Nuclear Sciences<br>764 Cumberland St, Private Bag 1930, Dunedin, New Zealand 
<br>Ph +64 3 4799663, fax +64 3 477 5232<br><br>_______________________________________________<br>Delphi mailing list<br><a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:Delphi@ns3.123.co.nz" target="_blank">
Delphi@ns3.123.co.nz</a><br><a onclick="return top.js.OpenExtLink(window,event,this)" href="http://ns3.123.co.nz/mailman/listinfo/delphi" target="_blank">http://ns3.123.co.nz/mailman/listinfo/delphi</a><br></blockquote></div>
<br></span></div></blockquote></div><br>