i have a format for printing and printin must be done in that format only also the page setup shud be shown i tried this code but not gettin anything with the format so plz help


Try
Dim con As New SqlConnection("conn str")
Dim cm As New SqlCommand
cm.Connection = con
cm.Connection.Open()
cm.CommandText = "Insert into table values(" & Val(txtbillno.Text) & ",'" & txtadd.Text & "','" & txtname.Text & "')"


cm.ExecuteNonQuery()

cm.CommandText = "Insert into table values(" & Val(txtadd.Text) & ")"

cm.ExecuteNonQuery()


Catch ex As Exception
MsgBox(ex.Message)
End Try

Me.Refresh()
Me.PrintDialog1.ShowDialog()


so what will be the code for tht format
its an excel sheet format
so do i hv to use file system????
n import it from thr how to do it

plz help.....

Edited 6 Years Ago by steelnaaz: n/a

Hi Steelnaaz, nice to meet you :)
This forum is for community introductions, so you probably don't find the answer here. You could start with "Similar threads".

Hi Steelnaaz, nice to meet you :)
This forum is for community introductions, so you probably don't find the answer here. You could start with "Similar threads".

i m hving prob not gettin anythg cud u plz help a liitle wht thread how to post thr ???

steelnaaz, as Maceman said wrong section, you need to post in the VB section like you did, you have to understand that if you are not willing to read and understand you will stay stuck.

Also you have to understand that people on the forum are helping you in their own free time for free. so following some basic simple rules should not be too hard to follow on your part.

Edited 6 Years Ago by finito: n/a

steelnaaz, as Maceman said wrong section, you need to post in the VB section like you did, you have to understand that if you are not willing to read and understand you will stay stuck.

Also you have to understand that people on the forum are helping you in their own free time for free. so following some basic simple rules should not be too hard to follow on your part.

so i posted on rite place????or not

This article has been dead for over six months. Start a new discussion instead.