我有一个记录: Public Loon As LonenRecordType LonenRecord 'Algemeen Status As String * 1 TijdvakNr As Integer TijdvakBegin As String * 10 TijdvakEinde As String * 10 Key As String * 10 WerkgeversNummer As String * 3 WnRecord As Integ
Public Loon As LonenRecord Type LonenRecord 'Algemeen Status As String * 1 TijdvakNr As Integer TijdvakBegin As String * 10 TijdvakEinde As String * 10 Key As String * 10 WerkgeversNummer As String * 3 WnRecord As Integer WerknemerNr As String * 4 AchterNaam As String * 25 Voorvoegsel As String * 15 and lots more end Type
我想把所有空的都变为“”或零
我可以:
with Loon .TijdvakNr = 0 .WerkgeversNummer = "" etc end with
有没有更简单的方法,f.i.与每个或任何?
分配到将处于默认状态的新值.'// return a new LonenRecord Function ResetLonenRecord as LonenRecord: End Function
然后:
'// overwrite variable Loon = ResetLonenRecord()