Results 1 to 2 of 2

Thread: Passing Variable to Another Form

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Aug 2000
    Posts
    316

    Passing Variable to Another Form

    How can I pass a string value into the variable on another form.

    Example Setup:

    Form XYX
    ========
    Dim strData As String
    strData = 123
    Forms![ZYX].strLocation = strData

    Form ZYX
    ========
    Public strLocation As String
    Using VS 6 Enterprise w/ SP5 & Windows 2000 Professional

  2. #2
    PowerPoster kfcSmitty's Avatar
    Join Date
    May 2005
    Posts
    2,248

    Re: Passing Variable to Another Form

    declare the variable in a module as Public

    Then set the variable as such

    VB Code:
    1. variable = forms![ZYX].textbox1.text

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