Results 1 to 2 of 2

Thread: DElete command

  1. #1

    Thread Starter
    Member
    Join Date
    Jan 2000
    Location
    derby,UK
    Posts
    38

    Post

    i have this peice of input code in my project, but i am struggling to make a delete command without meesing up my data:

    ' code to add new record 'arraycounter=
    '(how many records)

    ArrayCounterAF = (ArrayCounterAF + 1)

    ' code to re-dimension the array '

    ReDim Preserve ArrayDataAF(8,ArayCounterAF)

    'inputting a space so a new record can be
    'inputted

    For Counter = 1 To 8
    ArrayDataAF(Counter, ArrayCounterAF) = Text1(Counter - 1).Text
    Next Counter

    'saves data to file

    Open "AppointmentsFile.dat" For Output As #1
    For a = 1 To 8
    For b = 1 To ArrayCounterAF
    Print #1, ArrayDataAF(a, b)
    Next b
    Next a
    Close #1

    'save size of array (how many records

    Open "ArrayCounterSize.dat" For Output As #1
    Print #1, ArrayCounterAF
    Close #1

    ' i have used a control array (text1), and globally declared my variables

    PLEAS HELP SOMEONE ANYONE!!!!!!!!

  2. #2
    Former Admin/Moderator MartinLiss's Avatar
    Join Date
    Sep 1999
    Location
    San Jose, CA
    Posts
    33,175

    Post

    I don't know if this will help, but it's my answer to how to delete unwanted elements (blank entrys in the example) from an array.

    ------------------
    Marty
    Why is it called lipstick if you can still move your lips?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width