Pointers and string lists?

From: J West (jimw_at_fluffypaws.co.uk)
Date: 12/29/04


Date: Wed, 29 Dec 2004 13:11:58 -0000

I have a TStringList containing objects of type TpfDCSupplier
I need to add a pointer to each of these objects into a corresponding data
property of a TTreeNode
Could anyone tell me how I can do this?
    tv1.Items.AddObject(tv1.Items[0], p.SupplierName,
@TpfDCSupplier(fList.Objects[x]));
doesn't work as this points to the actual function of the Objects property
rather than the object itself.
casting the object to the local variable and adding the pointer to this
doesn't work either as the pointer points to the local variable rather than
the object in the object list.

Any ideas would be most gratefully received.

Regards

James West



Relevant Pages

  • Re: Pointers and string lists?
    ... >I have a TStringList containing objects of type TpfDCSupplier ... > I need to add a pointer to each of these objects into a corresponding data ... > doesn't work as this points to the actual function of the Objects property ... > James West ...
    (alt.comp.lang.borland-delphi)
  • Re: Application Crash with Error 5 when calling DeviceIOControl,...
    ... in fact it does not (psTargetString is a Pointer to a CString Object ... HANDLE hStorageDevice = NULL; ... "Bytes per Sector: %ul\r\n" ... Best regards ...
    (microsoft.public.win32.programmer.kernel)
  • Re: Search Engines & Frames
    ... Many thanks for the pointer - it was something I had simply not previously ... menus on each page so you wouldnt necessarily *have* to see the graphic ... Ian Bull wrote: ... >Thank you & Regards ...
    (microsoft.public.frontpage.client)
  • RE: Screen capture
    ... To move the mouse pointer and simulate clicks you can use SendInput function ... > contains the main portion of the form. ... > Best regards ...
    (microsoft.public.dotnet.languages.csharp)
  • Convert loop with Match function to avoid nested loop???
    ... MATCH function? ... As always, any help is much appreciated, even if it's only a pointer in ... Regards, ... Adrian ...
    (microsoft.public.excel.programming)