473,672 Members | 2,665 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Print Text Maintaining Tab Stops

I can locate tab stops in a RichTextBox but have not found a way to
maintain that positioning when I print. At the Knowledge Discovery
Keys Site (http://www.kdkeys.net/forums/3122/ShowPost.aspx) Baily
explains that character printing isn't really supported in VB .Net,
the TAB method does not apply. The DrawString method is used to send
strings to the printer. He notes a workaround is to write out the
content to a file (where the TAB method is sill supported) in the same
fashion as it would have been sent to the printer, and then stream
this to the printer.

I have tried this using his code attempting to take a simple text file
with some tabs, read it into a stream and then print - but the tabs
are gone. Appreciate a pointer to any code that might accomplish.

Ed
Nov 21 '05 #1
2 1933
Hi,

http://msdn.microsoft.com/library/de...ichTextBox.asp

Ken
-------------------
"Ed Bitzer" <ed******@yahoo .com> wrote in message
news:%2******** ********@TK2MSF TNGP14.phx.gbl. ..
I can locate tab stops in a RichTextBox but have not found a way to
maintain that positioning when I print. At the Knowledge Discovery
Keys Site (http://www.kdkeys.net/forums/3122/ShowPost.aspx) Baily
explains that character printing isn't really supported in VB .Net,
the TAB method does not apply. The DrawString method is used to send
strings to the printer. He notes a workaround is to write out the
content to a file (where the TAB method is sill supported) in the same
fashion as it would have been sent to the printer, and then stream
this to the printer.

I have tried this using his code attempting to take a simple text file
with some tabs, read it into a stream and then print - but the tabs
are gone. Appreciate a pointer to any code that might accomplish.

Ed

Nov 21 '05 #2
Ken,

Heavy.... looks like the answer but wonder if this old retired guy and
learn some new tricks. Thanks - I'll start studying

Ed

"Ken Tucker [MVP]" <vb***@bellsout h.net> wrote in message
news:uH******** ******@TK2MSFTN GP10.phx.gbl...
Hi,

http://msdn.microsoft.com/library/de...ichTextBox.asp

Ken
-------------------
"Ed Bitzer" <ed******@yahoo .com> wrote in message
news:%2******** ********@TK2MSF TNGP14.phx.gbl. ..
I can locate tab stops in a RichTextBox but have not found a way to
maintain that positioning when I print. At the Knowledge Discovery
Keys Site (http://www.kdkeys.net/forums/3122/ShowPost.aspx) Baily
explains that character printing isn't really supported in VB .Net,
the TAB method does not apply. The DrawString method is used to
send
strings to the printer. He notes a workaround is to write out the
content to a file (where the TAB method is sill supported) in the
same
fashion as it would have been sent to the printer, and then stream
this to the printer.

I have tried this using his code attempting to take a simple text
file
with some tabs, read it into a stream and then print - but the tabs
are gone. Appreciate a pointer to any code that might accomplish.

Ed

Nov 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

21
5725
by: Steel | last post by:
Hi at all, I have a very long html page with many photo. Therefore the best to print this page is to print the some page as PDF. Therefore I maked a PDF file like my page to print best. I'ld want that when the user press the print button in the browser , it print automatically the pdf file and not the html page. To do that I insert at the top of my page: <link media="print" rel="alternate" href="printthepage.pdf"> But it do not work and...
1
1782
by: RK | last post by:
Our Application solution consists Web Service and 3 other C# class libraries. We added Trace Listener to the application and writing log information in all our components. Since multiple sessions access the same application, log messages are interspersed and looks clumsy. And more its hard keep maintaining the log, as components calls among themselves multiple times. what is the better way of maintaining session level log writing to
1
4592
by: Mickey | last post by:
Hi, I have a script which works in both IE but is sluggish in Firefox. The script is a simple text scroller. It works perfectly in IE however in Firefox, the text scroll slower and eventually just stops. I would aprechiate it someone could look at the code below and maybe see where the problem is?
2
7520
by: mordac | last post by:
Hello, I was wondering if I could get some opinions on how best to handle printing in a max heap data structure. Right now my heap struct looks as thus: typedef struct heapStruct { int* heapArray; int heapSize; int arraySize; int maxSize; } heapStruct; arraySize holds the current number of elements in the array.
6
5098
by: moondaddy | last post by:
I have an application where I need to print images where the size has been reduced down to a fraction of a thumbnail and the original image is several inches high and wide. We're using a special printing process where the dpi is 2000x2000 or higher, therefore, when I reduce the size of the image, I don't want to loose any pixels. In other words, if the image is 200 px by 200 px and I reduce the size down to 1/4 inch, I want the printer to...
0
1611
by: sanjay.hurryup | last post by:
I have a problem with printing . I want to print on a roll paper, a long list, should stop the paper whenever the printing stops. In normal case single paper is used even if it has less to print. I only know to print on a single paper.
1
3439
by: Xah Lee | last post by:
Text Processing with Emacs Lisp Xah Lee, 2007-10-29 This page gives a outline of how to use emacs lisp to do text processing, using a specific real-world problem as example. If you don't know elisp, first take a gander at Emacs Lisp Basics. HTML version with links and colors is at: http://xahlee.org/emacs/elisp_text_processing.html
3
930
by: rohitscripts | last post by:
hi everyone.. My web application contains a login module in which i need to maintain the session of the user 1) for an unlimited period if the user is using the website 2) for 30 minutes from the last request sent by the user(ie need to maintain the sesion of the user for 30 min after the user stops using the websiite) Please help me out....in achieving this thanks in advance
1
1631
by: cryogeneric | last post by:
Hi, I'm writing an ASP application that can display PDF files in a frame. The user can save or download the PDF, but I need to know when they do this so I can add an activity record to my database. My first thought was to disable the PDF tool bar and allow saving and printing from buttons that I CREATE. This would allow me to trap the action. I was able to do this for saving using the LoadFromFile method in ASP. However, printing has...
0
8503
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
1
8640
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7469
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6254
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5720
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4239
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4439
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2836
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2091
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.