Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

I have a login form with username and PW textboxes and I want to pass the username into a variable on another form.

 

However when I try to test to make sure it's working it outputs nothing in my test label.

 

I have my Username Textbox set to public so I don't know why this isn't working...

 

Here is my code, what's wrong!!?

 

Public frmLoginInstance As New frmLogin()

   Public strUsername As String = CStr(frmLoginInstance.txtUserName.Text)

 

Thanks

Posted

So if I did a class with just a property for the Username, and then instantiated an object as that class type, and then set the username property of the object to CStr(frmLoginInstance.txtUsername.Text) it would work?

 

Seems like that isn't really doing anything different but then again I'm lost and clueless when it comes to programming so maybe you meant something else?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...