Results 1 to 4 of 4

Thread: reset project? RESOLVED

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Mar 2007
    Posts
    20

    Resolved reset project? RESOLVED

    is there a command that resets the project? something that clears all text boxes ect.

    Thanks
    YT
    Last edited by YT100; Mar 18th, 2007 at 06:23 AM. Reason: resolved

  2. #2
    PowerPoster gavio's Avatar
    Join Date
    Feb 2006
    Location
    GMT+1
    Posts
    4,462

    Re: reset project?

    In run-time? If so, you can do a loop:
    Code:
    Dim frm As Form
    Dim ctl As Control
    
    For Each frm In Forms
        For Each ctl In frm.Controls
            If TypeOf ctl Is TextBox Then
                ctl.Text = vbNullString
            ElseIf TypeOf ctl Is Label Then
                ctl.Caption = vbNullString
            Else
                '...
            End If
        Next
    Next

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Mar 2007
    Posts
    20

    Re: reset project?

    thats done it, thanks heaps

  4. #4

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