View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
michael michael is offline
external usenet poster
 
Posts: 28
Default deleting array element

I am kind of new to the programming world and am trying to
create a loop that will check certain fields of a user
defined data type and delete it if it meets certain
criteria. My user-defined data type looks like this;

Type SwitchingTimes
DayofWeek As String * 3
TimeSwitch As Date
Phase As String * 1
SwitchON As String * 3
feeder As Long
kVARs As Long
End Type
Dim Switching() As SwitchingTimes

I would like to delete all elements at a time... for
example if at i=3 the criteria are met, I would like to
delete Switching(3).DayofWeek, Switching(3).TimeSwitch,
Switching(3).Phase, etc for all. I tried the code Set
Switching(i)= nothing but that gives an error... thanks
in advance for the help