Veröffentlicht 2. April 200817 j Hey Leute, momentan erstelle ich ein VBS und komme an einer Stelle nicht wirklich weiter. Und zwar möchte ich ganz gerne eine Datei (es handelt sich um eine Excel-Tabelle) ausdrucken. Zwar kenne ich den Befehl: xlsOutput.PrintOut schon und dieser funktioniert auch, wenn auch im Hochformat. Weiss jemand, wie ich einen Druck im Querformat veranlassen könnte, ohne auf das Printer-Object zugreifen zu müssen? Da muss es doch auch nur ein Parameter geben, oder nicht? Wäre für Eure Hilfe echt dankbar. MfG Chriz Schwarz
3. April 200817 j Hallo! Hochformat: Application.ActiveSheet.PageSetup.Orientation = xlPortrait Application.ActiveSheet.PrintOut Querformat: Application.ActiveSheet.PageSetup.Orientation = xlLandscape Application.ActiveSheet.PrintOut So long, words_of_silence
3. April 200817 j Hallo! Hochformat: Application.ActiveSheet.PageSetup.Orientation = xlPortrait Application.ActiveSheet.PrintOut Querformat: Application.ActiveSheet.PageSetup.Orientation = xlLandscape Application.ActiveSheet.PrintOut So long, words_of_silence Hey wods_of_silence, erstmal vielen, vielen Dank für Dein Posting. Du hast mich echt weiter gebracht. TOP!!! Leider kommt vbs nicht ganz mit "xlPortrait" und "xlLandscape" klar. So habe ich das mit dem Ersatz "1" und "2" getestet und es klappte hervorragend!!! Danke nochmal!!! Hier nochmal der Code für den Druck im Hoch(1)-/Quer(2)format: Application.ActiveSheet.PageSetup.Orientation = 1 Application.ActiveSheet.PrintOut oder: Application.ActiveSheet.PageSetup.Orientation = 2 Application.ActiveSheet.PrintOut
Archiv
Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.