?
Solved

VB6 printout question ??

Posted on 2004-03-21
1
Medium Priority
?
414 Views
Last Modified: 2013-12-25

Hi experts  I have one small question 4 you.

I would like to print my text1 and text2 on particular coordinates  (x,y).
Please write me the source code.

thanks

.
0
Comment
Question by:datan00b
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 27

Accepted Solution

by:
Dabas earned 540 total points
ID: 10644770
Hi datan00b:
Public Sub PrintAt(intX As Single, intY As Single, strText As String, _
    Optional intFontSize As Integer, Optional strFontName As String, _
    Optional blnBold As Variant)
    Printer.CurrentX = intX
    Printer.CurrentY = intY
    If strFontName <> "" Then
        On Error Resume Next
        Printer.FontName = strFontName
        Printer.Print "";
    End If
   
    If intFontSize <> 0 Then
        SetFontSize (intFontSize)
    End If
    If Not IsMissing(blnBold) Then
        Printer.FontBold = blnBold
    End If
    Printer.Print strText
End Sub

Dabas
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses
Course of the Month10 days, 14 hours left to enroll

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question