CompuServe Thread

#Paper Orientation

31 messages in this thread
#1944From: Dennis L. HarringtonOct 8, 1991 12:57 AM
George, OK. Here's how you can change the printer orientation from within VB: '***** in the global module Type ORIENT Orientation as Long Pad as string * 16 End Type Declare Function PrtOrient% Lib "GDI" Alias "Escape" (ByVal hDc%, ByVal nEsc%, ByVal nLen%, lpData as ORIENT, lpOut as Any) '***** when you want to change orientation Dim prtO as Orient O.Orientation = (1 for portrait, 2 for landscape) x% = Escape(Printer.hDC, 30, len(prtO), prtO, 0&) x% simply returns the previous paper orientation. The value in O.Orientation is what determines the paper orientation (1=portrait and 2=landscape) –dennis There are 2 Replies.
#1995From: George CampbellOct 8, 1991 8:50 AM
Dennis, Thanks again for the additional printer information. I'm really impressed with the value of the user-to-user help that's appearing for VB. It reminds me a lot of the early days, with everyone helping each other to solve all the little problems. Now, if MS will listen to all this and give everyone a more capable version 2.0 of VB, I'll be overjoyed. George There are 2 Replies.
#2207From: Don FunkOct 9, 1991 12:59 PM
Hi Goerge, Let's remember that this is only version *1.0*. If Microsoft did not listen to the people, we would still be programming Windows with SDK. By listening to the needs of the customers, Visual Basic was developed…an easier means of programming a Windows application that is quick, simple and powerful. We also listen to individual needs also, that is why the printing of the bitmap example was developed for your application here at Product Support. If you have any suggestions, please feel free to address them to me or anyone here in the forum. I have been known to be way off as far as what developers what and with additional feed back, I call pass on what "you" and "others" want.<g> Don Funk There is 1 Reply.
#2249From: Jonathan Zuck (UFI)Oct 9, 1991 4:11 PM
Don, How about the source to the XREF control? -=- Jonathan There is 1 Reply.
#2283From: Don FunkOct 9, 1991 6:27 PM
Hi Jonathan, What XREF control are you talking about? PropView? Don Funk There are 2 Replies.
#2338From: Ted M. YoungOct 9, 1991 11:30 PM
Don, I dunno what XREF tool Jonathan is talking about, but I'd certainly like to see the source code for the PropView custom control!! – Ted There is 1 Reply.
#2432From: Don FunkOct 10, 1991 12:15 PM
Hi Ted, I've seen the source<g>. I will pass the suggestion as far as Propview code. Thanks. Don Funk
#2342From: Jonathan Zuck (UFI)Oct 9, 1991 11:51 PM
Don, Yes, PropView. It seems to do things consistently that are normally quite flaky in the CDK. It would be nice to see how it works. Is it using Windows calls to find all of the children of its parent and then going through and VBGethWndControl for each of the children? Look forward to seeing it! -=- Jonathan There is 1 Reply.
#2433From: Don FunkOct 10, 1991 12:15 PM
Hi Jonathan, I'm glad this thread is back on track. For a moment there I thought we were going to take a poll on who uses finger nail polish<g>. Some type of enum function was called to look at the properties of each child control. I will pass on the desire to get ahold of the Propview code. Don Funk There are 2 Replies.
#2466From: Jonathan Zuck (UFI)Oct 10, 1991 2:30 PM
Don, Thanks. It would be nice to see the code for the control. One interesting ramification of the manner in which the CDK is set up (with the routines held in SS) is that you cannot examine the controls of a program from within another program. That's a shame. -=- Jonathan
#2490From: Mark Novisoff/MicroHelpOct 10, 1991 4:10 PM
Don, While you're at it, I'd like to see the source for VB! <smile> Mark
#2256From: Don FunkOct 9, 1991 4:48 PM
Hi Goerge, Let's remember that this is only version *1.0*. If Microsoft did not listen to the people, we would still be programming Windows with SDK. By listening to the needs of the customers, Visual Basic was developed…an easier means of programming a Windows application that is quick, simple and powerful. We also listen to individual needs also, that is why the printing of the bitmap example was developed for your application here at Product Support. If you have any suggestions, please feel free to address them to me or anyone here in the forum. I have been known to be way off as far as what developers what and with additional feed back, I call pass on what "you" and "others" want.<g> Don Funk
#1997From: john keslerOct 8, 1991 8:53 AM
Dennis, Thanks for the Escape API tip for changing a printer's orientation. I saw it in my Windows Programmer's Reference, but was intimidated by the implementation details. Any of you "book writers" out there: There's got to be a better way to show how to use some of these API commands that a mere mortal (read here non-ASM, C-novice) can read, understand, and put into use. The Escape API function clearly looked to me to be useful for changing a Printer's orientation, but the MS docs were a bit too cryptic for me to figure it out. Thanks again Dennis. john k There is 1 Reply.
#2017From: Dennis L. HarringtonOct 8, 1991 10:59 AM
John, << Saw it but was intimidated by the implimentation details >> Confession time – so was I. I even originally messaged George that it couldn't be done using Escape because the value of GetSetPaperOrientation wasn't in the VB API ref. Thanks to some timely encouragement from Don Funk, I finally figured it out. Another confession – I know absolutley nothing about C, the SDK, or anything else but PDS and VB, and programming is strictly a hobby. What I have found with using the API is that lots of playing yields big results. One caveat is to always backup before trying new API calls. They have to be the finest method in the world to create UAE's! –dennis There is 1 Reply.
#2175From: john keslerOct 9, 1991 9:25 AM
Dennis re:The confessions of a VB/API programmer. 🙂 That's one thing about experimenting with API calls. Often the call doesn't _just_ fail to work properly, instead your reward is a fine UAE. Kind of takes the fun out of it… john k There is 1 Reply.
#2185From: Dennis L. HarringtonOct 9, 1991 10:24 AM
John, << … Your reward is a fine UAE. Kind of takes the fun out of it … >> Ah, the game is always more interesting when you use real bullets! –dennis There is 1 Reply.
#2242From: Dan BarclayOct 9, 1991 3:36 PM
Dennis, John, << fine UAE >>> << real bullets >> How soon we forget the "good old days". I remember working for hours on end waiting for my PC to reboot (and reboot and reboot) while developing my first TSR. Damn near wore out the little red switch. If you don't remember, the old machines took *forever* to do a cold boot and didn't show anything on the screen in the process. I had to go to Dallas to get my first PC and was the proud owner of one of the highest of tech *double sided* floppy machines around. UAE is just another flavor of the same old critter. Dan PS: I finally got Periscope and put an end to that cold boot foolishness. There is 1 Reply.
#2246From: Dennis L. HarringtonOct 9, 1991 3:56 PM
<< the proud owner of one of the highest of tech *double side* floppy machines around. >> My, you're just a kid then! <g> I've still got my first IBM in the cloest with 160k single sided drives and a 64k motherboard. Even ran across my original copy of DOS 1.0 the other day. Yeh, booting those machines was always a good excuse for a cup of coffee. I don't have periscope, but I did write a little diddy to do a windows restart from within windows. –dennis There are 2 Replies.
#2250From: Jonathan Zuck (UFI)Oct 9, 1991 4:11 PM
Dennis, Oh yeah! Well, my first program was a video game for the TRS-80 and it was loaded onto the machine with a cassette tape!! -=- Jonathan There are 5 Replies.
#2282From: Don FunkOct 9, 1991 6:27 PM
Hey, I had one of those tape driven beast and I'm not really that old! Boy have computers come a long way. Don Funk
#2300From: Susan LemieuxOct 9, 1991 7:39 PM
Jonathan – My first computer was a TRS-80 Model 1 Level 2 (?). I remember the day when I emptied my piggybank and bought 2 external floppy drives. Each diskette held about 160k I think and when the stupid things would constantly drift out of alignment, I'd open up the drives and paint fingernail polish on the alignment screw to hold it still! (Even got the local Local Radio Shack doing it!) Well…..it WORKED! <g> — Susan There are 3 Replies.
#2340From: Ted M. YoungOct 9, 1991 11:30 PM
Susan, I got an Apple II+ (with DOS 3.2 and the UCSD-Pascal language system, a whole 64K!) before I had a chance to upgrade my TRS-80 to a floppy drive system, and from what I remember about TrashDos, err, TRSDOS, I'm glad I got out! But I remember the first program I'd load up before doing anything else (though with my cassette player, I usually had to load it twice) was that keybounce-fix program. – Ted
#2344From: Jonathan Zuck (UFI)Oct 9, 1991 11:51 PM
Susan, Nail polish is one of the most amazing things! I've kept a bottle handy since I was about 15…no! not for my nails! I just thought I should cut that "thread" before it started!<g> -=- Jonathan There is 1 Reply.
#2431From: Don FunkOct 10, 1991 12:15 PM
Hi Jonathan, Only on Compuserve would a thread talking about "Paper Orientation" turn into "Why Jonathan uses finger nail polish".<g> Don There is 1 Reply.
#2544From: Charles GalloOct 10, 1991 9:31 PM
Susan, GLYPTOL works better than nail polish to hold set screws and pots. That is what is used on most electronics Charlie
#2339From: Ted M. YoungOct 9, 1991 11:30 PM
Jonathan, TRS-80 Level I, 4K? Gawd, I was so excited when I upgraded to Level II, 16K! What a thrill! And now I have 12meg, which is barely enough. My how time flies. – Ted
#2366From: Dennis L. HarringtonOct 10, 1991 2:10 AM
<< … it was loaded into the machine with a tape!! >> Was that paper punch tape or audio tape? <g!> –dennis There is 1 Reply.
#2463From: Jonathan Zuck (UFI)Oct 10, 1991 2:15 PM
Dennis, Actually, the teletype terminal hooked in the time share service at the local community college did have paper tape. I guess my *real* first program was the one that made little banners on the tape. I never seem to count that! It was amazing to me how impressed people were with the Star Drek on that machine! -=- Jonathan
#2510From: Nelson FordOct 10, 1991 5:02 PM
Yeah, it was a big day when I went from tape to that 80k disk drive. Hi-tech all the way! <g>
#2303From: Dan BarclayOct 9, 1991 7:44 PM
Dan, Yep, I'm just a kid. The double sided drives came out about 6 mos after the 1st IBM-PC. I splurged and got the extra RAM also (boosted myself up to a whoping 64k like yourself) Then again, that machine was my second. I avoided the Apples but I did get a TRS Model II (8"drive) because I could run both TRS-DOS and CP/M on it. A friend had one of the Model I's and I "helped" him play with it. He wrote an inventory program for a local furniture store using the tape drive (a bit laughable, no?). Obviously it was a small store <g>. re: your little diddy to restart windows … Is it for use after a UAE? If so, is that enough cleanup? I thought all of memory including DOS (read: drive tables) were also in jeopardy after a UAE. Dan There is 1 Reply.
#2358From: Dennis L. HarringtonOct 10, 1991 1:23 AM
Dan, What have you started in my life!? My wife's been grinding on me for weeks to set her up a system so she could use her customer tracking program at her new shop instead of at home on my machine. So finally last night I dig out an old XT I thought would work, but discover it's only got a full height 360k flopy drive. As I've only got HD drives and the XT has no serial port, I need to do something to transfer the programs and data. So tonight I bring home a 720k 3.5", a HH 5.25" and the controller with it's own bios to run them. Get it all installed but sorry, no work. Hmm. Then the light goes on (very dim light). An XT has dip switches to set the number of drives. About an hour later, by some devine miracle, I find the old IBM XT configuration manual and get the switches set. Load her apps thinking I'm done, but wait, they won't work. Illegal Function call error! Hugh!? What gives? Oh, another light flickers. I've compiled them in PDS for the 286 instruction set. So a few new compiles later, and it's working. Yep, they sure don't build 'em like they used to, and THANK GOD! –dennis