Unanswered: Am really having a hard time with the printing. )=
Hi good morning.(=
I just recently learned vb and with the help of rocslide, i was able to create my first vb db which i would like to use at our office. Its a counter transaction ticketing system. Finding my way through the different code, i was able to came up with these one.
Public Class Form1
Dim iTicket As Integer
iTicket = iTicket + 1
getTicket = iTicket
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
MsgBox("Please proceed at Counter 17.Your ticket is number " & getTicket())
MsgBox("Print your number?")
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
iTicket = 0
Private Sub buttonOnClick()
But the thing is, even if i google the steps on how to print and even ask other friend how to do it, iam having a hard time making code for printing. Would it be to much if i ask you friends to give me an idea or a sample what code should i put for me to able to finish this project? Thank you so much in advance.
You have set up a variable called answer to hold the value from the message box but you are not actually assigning it the value from the message box. It is defaulting to some value when you set it up (this is where you have your Dim statement).
Have a look at the example at the bottom of this page MsgBox Method
Pay particular attention to how they are using/seting up their response variable.