Subject [IBO] Re: Accessing 'previous' values during posting/commiting
Author bamber12001
--- In IBObjects@yahoogroups.com, Daniel Rail <daniel@a...> wrote:
> Hi,
>
> At October 14, 2004, 07:29, bamber12001 wrote:
>
> >
> > It does exactly the same thing - this was the way I originally
had
> > it (and I've changed it back, as I thought the same as you did).
The
> > error message looks like it has nothing to do with the actual
> > problem, which isn't much help!
>
> Here's the definition of OldValues:
>
> Property OldValues[constColumnName:string] : variant;
>
> So, you need to access the value as follows:
> VarToStr(qryBudgetItems.Fields.OldValues['DESCRIPTION'])
>
> VarToStr is to convert a variant to a string.
>
> Because, qryBudgetItems.Fields.OldValues['DESCRIPTION'].AsString
> isn't a valid syntax for a variant.
>
> So, essentially the variant error that you were getting was valid.
>
> --
> Best regards,
> Daniel Rail
> Senior System Engineer
> ACCRA Group Inc. (www.accra.ca)
> ACCRA Med Software Inc. (www.filopto.com)

Daniel,

Slight improvement - I don't get the error message any more, but the
values written to the text file are the new values, not the old ones!

Any ideas why this may be?

Gary.