how to print strings from editboxes wherever you want on A4 paper
Hi I'm newly registered and I have a big problem. My application has
some editboxes, i like to print text that i input in theese editboxes
on various places in a A4 paper. but i don't have much success for now,
please if someone can point me to some tutorials, or explain it a bit
for me. thanks! cheers
Re: how to print strings from editboxes wherever you want on A4 paper
The simplest way is via WYSIWYG (for which MFC is already set up).
Assuming your edit boxes are in a dialog which is then dismissed:
1. Change your view to be CScrollView-derived instead of
CView-derived.(see the Scribble tutorial if you're not sure how)
2. Change your mapping mode to MM_LOMETRIC by putting the following in
SetScrollSizes(MM_LOMETRIC, CSize(2000,2700)); // A4
3. Put your drawing code in OnDraw(), using TextOut() (remembering that
y is now negative down the page instead of positive).
Run the program, check the text is where you want it to be, click