It is currently Fri May 25, 2018 9:48 pm

All times are UTC + 1 hour




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Pointer to string of string list?
PostPosted: Wed May 16, 2018 10:25 am 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Fri Jun 11, 2004 7:07 am
Posts: 541
Pointer to a single string or a string in a structured list works. But how I get the pointer to a string of a string list?
Code:
Procedure StringCheck(*string)

  *buffer.character = *string
  Debug *buffer\c

EndProcedure

test$ = "ABC"
StringCheck(@test$)
; = 65 = OK

Structure xxx
  test.s
EndStructure
NewList mylist1.xxx()
AddElement(mylist1())
mylist1()\test = "ABC"
StringCheck(@mylist1()\test)
; = 65 = OK

NewList mylist2.s()
AddElement(mylist2())
mylist2() = "ABC"
StringCheck(@mylist2())
; = 2208 = wrong, pointer to list element?


Top
 Profile  
Reply with quote  
 Post subject: Re: Pointer to string of string list?
PostPosted: Wed May 16, 2018 11:15 am 
Offline
Addict
Addict
User avatar

Joined: Mon Sep 15, 2003 5:55 am
Posts: 1320
StringCheck(PeekI(@mylist2()))

c ya,
nco2k

_________________
If OSVersion() = #PB_OS_Windows_ME : End : EndIf


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  

 


Powered by phpBB © 2008 phpBB Group
subSilver+ theme by Canver Software, sponsor Sanal Modifiye