Click here to Skip to main content
11,485,334 members (78,028 online)
Rate this: bad
good
Please Sign up or sign in to vote.
See more: VB
Is there anything else exept MsgBox, in the end to show the data, like a list of subject or a list of student names....to display data after button click?
and which one is right?
a) MsgBox("Your name is" ,&txtyourname.Text)
b) MsgBox "Your name is, txtyourname.Text"
c) Else...?
Posted 31-Dec-12 2:08am
San Dra391
Edited 31-Dec-12 10:18am
v3
Comments
Christian Graus at 31-Dec-12 15:17pm
   
For you to even need to ask this, means you didn't both even trying anything and have no idea about VB syntax or programming. Buy a book and read it. Do not learn VB6, it is obsolete. Also, try to give your question a real subject. Your tag says you're using VB, and we know you need help
San Dra at 31-Dec-12 16:37pm
   
Really that's Not msgbox syntax ...Hmmm..anyway thnxx for clear it up..
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Remove the comma and it should work fine. You need to concatenate the two strings together. You can do that with either + and &, where & is most efficient.

MsgBox("Your name is" & txtyourname.Text)

Good luck!
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Else:
MsgBox("Your name is " & txtyourname.Text)
Don't use ,& but &

Hope this helps.
  Permalink  
Comments
wolfcoder75 at 31-Dec-12 12:33pm
   
Did this question get answered, looks like there was question behind different ways to show a display box?

You can do a timed form which is much like a splash screen, you could also do a messagebox with a sleep which most people don't like to use because of the frozen thread.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 375
1 Maciej Los 365
2 C#developer.asp 204
3 Mehdi Gholam 190
4 OriginalGriff 149
0 Sergey Alexandrovich Kryukov 8,819
1 OriginalGriff 7,982
2 Sascha Lefèvre 3,199
3 Maciej Los 2,841
4 Richard Deeming 2,370


Advertise | Privacy | Mobile
Web04 | 2.8.150520.1 | Last Updated 31 Dec 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100