No, AFAIK there is nothing that returns value for pointer, like in your case.
Jussi 2011/5/18 Phạm Quang Dương <soleil...@gmail.com> > Hope this help :) > The key is Pointer. > > 2011/4/9 Benoît Minisini <gam...@users.sourceforge.net> > > > > aStruct * anExternFunc(...) > > > > with: > > > > aStruct { > > > > aClass *data > > aStruct *previous > > aStruct *next > > } > > > > > > How to get all *data > > I tried > > > > pNext = anExternFunc(...) > > while pNext <> null > > > > pData = Pointer@(pNext) > > > > ... > > > > pNext = pData + SizeOf(gb.pointer)*2 > > > > wend > > > > and failed. > > > > --8<-------------------------- > > > > -------------------------------- > > > > pStruct = anExternFunc(...) > > > > While pStruct > > > > pData = Pointer@(pStruct) > > > > ... > > > > pStruct = Pointer@(pStruct + Sizeof(gb.Pointer) * 2) > > > > Wend > > > > --8<---------------------------------------------------------- > > > > That should work. Does it? > > > > You can use a memory stream and a structure too: > > > > --8<---------------------------------------------------------- > > > > Struct MyDataSlot > > Data As Pointer > > Previous As Pointer > > Next As Pointer > > End Struct > > > > ... > > > > Dim hMem As Stream > > Dim hSlot As MyDataSlot > > > > pStruct = anExternFunc(...) > > > > While pStruct > > > > hMem = Memory pStruct For Read > > > > hSlot = Read #hMem As MyDataSlot > > > > pData = hSlot.Data > > > > ... > > > > pStruct = Pointer@(hSlot.Next) > > > > Wend > > > > --8<---------------------------------------------------------- > > > > Regards, > > > > -- > > Benoît Minisini > > > > ------------------------------------------------------------------------------ > What Every C/C++ and Fortran developer Should Know! > Read this article and learn how Intel has extended the reach of its > next-generation tools to help Windows* and Linux* C/C++ and Fortran > developers boost performance applications - including clusters. > http://p.sf.net/sfu/intel-dev2devmay > _______________________________________________ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > ------------------------------------------------------------------------------ What Every C/C++ and Fortran developer Should Know! Read this article and learn how Intel has extended the reach of its next-generation tools to help Windows* and Linux* C/C++ and Fortran developers boost performance applications - including clusters. http://p.sf.net/sfu/intel-dev2devmay _______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user