Chip, I think you’re probably right. I’ve worked round the problem by cutting out the objects, and all is now OK even compiled.
Jeremy > > On 26 Feb 2019, at 14:47, Chip Scheide <4d_o...@pghrepository.org> wrote: > > Jeremy, > as I am sure you know pointers in 4D have some 'quirks'. > I suspect that you have found another. > > Chip > > On Tue, 26 Feb 2019 07:18:36 +0000, Jeremy Roussak via 4D_Tech wrote: >> Kirk, >> >> My apologies. I mistyped the offending lines! >> >> The lines causing the error dereference the pointers. So they are >> >> $to.toDate->:=$from.toDate-> >> $to.toAge->:=$from.toAge-> >> etc. >> >> The curious things are that (a) the dereferenced pointers do >> definitely point at variables of the same type; (b) although I get an >> alert with the error message, the assignment does in fact work (that >> is, if I click “continue”, everything is exactly as it should be >> when the method completes). >> >> I can get round the error by using pointer variables: >> >> $pTo:=$to.toDate >> $pFrom:=$from.toDate >> $pTo->:=$pFrom-> >> >> which works fine. I just don’t understand the actual error message, >> since I’m not doing what it’s accusing me of doing. >> >> Jeremy >> >> >> >>> On 25 Feb 2019, at 16:47, Kirk Brooks via 4D_Tech >>> <4d_tech@lists.4d.com> wrote: >>> >>> Jeremy, >>> Since you are writing the data to an object what's the value of using the >>> pointer? Why not just write the data? >>> >>> In fact, since TCMGetRow looks like it is simply holding the data for the >>> transfer you could make it a loop: >>> >>> For($i;1;number of objects) >>> >>> $o["_"+string($i)]:=Object get pointer(Object named;$root+string($i))-> >>> >>> End for >>> >>> This way you don't need to care about the data type assuming the 2 objects >>> actually have the same typed objects for each index. >>> >>> But to specifically answer your question I would take a look at the way the >>> date value is stored in your object and then how you reference it. There's >>> another post about dates and objects that sounds on point with what you are >>> doing. >>> >>> >>> On Mon, Feb 25, 2019 at 7:37 AM Jeremy Roussak via 4D_Tech < >>> 4d_tech@lists.4d.com> wrote: >>> >>> >>> >>> >>> -- >>> Kirk Brooks >>> San Francisco, CA >>> ======================= >>> >>> What can be said, can be said clearly, >>> and what you can’t say, you should shut up about >>> >>> *Wittgenstein and the Computer * >>> ********************************************************************** >>> 4D Internet Users Group (4D iNUG) >>> Archive: http://lists.4d.com/archives.html >>> Options: https://lists.4d.com/mailman/options/4d_tech >>> Unsub: mailto:4d_tech-unsubscr...@lists.4d.com >>> ********************************************************************** >> >> ********************************************************************** >> 4D Internet Users Group (4D iNUG) >> Archive: http://lists.4d.com/archives.html >> Options: https://lists.4d.com/mailman/options/4d_tech >> Unsub: mailto:4d_tech-unsubscr...@lists.4d.com >> ********************************************************************** ********************************************************************** 4D Internet Users Group (4D iNUG) Archive: http://lists.4d.com/archives.html Options: https://lists.4d.com/mailman/options/4d_tech Unsub: mailto:4d_tech-unsubscr...@lists.4d.com **********************************************************************