zuloloxi / gmlibrary

Automatically exported from code.google.com/p/gmlibrary
0 stars 1 forks source link

Convert error #23

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

            GMDirection1.DirectionsRequest.UnitSystem := usImperial;
            GMDirection1.DirectionsRequest.Region := rUNITED_KINGDOM;
            GMDirection1.DirectionsRequest.Origin.Address := tpostcode+' UK';
            GMDirection1.DirectionsRequest.Destination.Address := qryResultBasePostcode.AsString+' UK';
            GMDirection1.Execute;

Where tpostcode is a UK postcode from a database (this is always valid).

It crashes with 'could not convert variant of type Null into type String.
On the line:
if SameText(Node.NodeName, LBL_D_COPYRIGHTS) then Result.FCopyrights := 
Node.NodeValue;

What version of the product are you using? GMLib 1.10 Final on Delphi 2007, 
Windows 7.

Many thanks,

Mike.

Original issue reported on code.google.com by mikemcc...@gmail.com on 16 Jan 2014 at 11:46

GoogleCodeExporter commented 9 years ago
Hi Mike

Can you send me a demo program that reproduce the error?

Thanks

Original comment by cadet...@gmail.com on 18 Jan 2014 at 2:35

GoogleCodeExporter commented 9 years ago
Hi,

I wrote a little test project and think I have found the answer.
It is happening when start and destination postcodes are the same.
So that's fine, I can trap this in my code.
Thanks for replying.

Mike.

Original comment by mikemcc...@gmail.com on 20 Jan 2014 at 11:16

GoogleCodeExporter commented 9 years ago
Perfect, I close this issue then

Original comment by cadet...@gmail.com on 20 Jan 2014 at 12:52