Site Logo
Site Logo
 
It is currently Sun Apr 02, 2017 10:18 pm

All times are UTC [ DST ]




Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: type list (of psline )
PostPosted: Tue Nov 29, 2016 7:28 pm 
Offline
DELCAM Guru
DELCAM Guru

Joined: Tue Nov 07, 2006 1:16 pm
Posts: 75
hi,
i can't use the type list (of psline )

sample:
i select on line and put here into the list

Dim Linee as list (of psline )
linee.Item(0) = psm.SelectedItems(0) ' Not work !!!!!

otherwise i use a simply array
dim linee(1) as psline

line(0) = psm.selecteditems(0) ' Work correctly

why ??

Thanks


Top
 Profile  
 
 Post subject: Re: type list (of psline )
PostPosted: Tue Dec 06, 2016 11:34 pm 
Offline
DELCAM Staff
DELCAM Staff

Joined: Tue Mar 17, 2009 2:30 pm
Posts: 108
That's standard list behaviour. You have declared a list but not initialised it. You need to do something like:
// Create a new list and initialise it with "New"
Dim myList As New List(of PSLine)
// Add an item to the list
myList.Add(psm.SelectedItems(0))


Top
 Profile  
 
 Post subject: Re: type list (of psline )
PostPosted: Wed Dec 07, 2016 12:01 am 
Offline
DELCAM Guru
DELCAM Guru

Joined: Tue Nov 07, 2006 1:16 pm
Posts: 75
Ok ok thanks !!!


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


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
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB