Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Text Box Printing, and Footer Question

1st Question, I have a colored VBA textbox that is linked to a cell
Sorta used for a form so people know to input their name there. I wan
to be able to print that without seeing the outline of the textbox o
color shade. I tried object printing False but it won't print the inpu
in the text box. maybe it needs some code?

2nd Question, when I have a header or a footer and want to link it to
cell, how would I do that. For instance when they input their name i
then Prints their name from that cell at the top or bottom of ever
page. I looked in the custom header and footer but no go. Thanks fo
your help

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default Text Box Printing, and Footer Question

Hi
For the second one you ma use the following code: Put it in your
workbook moudle 8links cell A1 of each sheet to the footer):

Private Sub Workbook_BeforePrint(Cancel As Boolean)
Dim wkSht As Worksheet
For Each wkSht In Me.Worksheets
With wkSht.PageSetup
.CenterFooter = wkSht.Range("A1").value
End With
Next wkSht
End Sub


--
Regards
Frank Kabel
Frankfurt, Germany

1st Question, I have a colored VBA textbox that is linked to a cell.
Sorta used for a form so people know to input their name there. I

want
to be able to print that without seeing the outline of the textbox or
color shade. I tried object printing False but it won't print the
input in the text box. maybe it needs some code?

2nd Question, when I have a header or a footer and want to link it to
a cell, how would I do that. For instance when they input their name
it then Prints their name from that cell at the top or bottom of

every
page. I looked in the custom header and footer but no go. Thanks for
your help.


---
Message posted from http://www.ExcelForum.com/


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Text Box Printing, and Footer Question

Thanks Frank for the reply, I'm lost on where you want me to put th
code and the worksheet name is Data.

I want to display Cell C11, C13, and C15 from Coversheet! on the Heade
Right side on Data! sheet. And I want to display a disclaimer which i
Cell A50 from Coversheet! on the Center Footer of Data! sheet.

Thanks again for your help. BTW and good books I can buy that will hel
me with code

--
Message posted from http://www.ExcelForum.com

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,885
Default Text Box Printing, and Footer Question

Hi
try the following
- open the VBA editor (hit ALT+F11)
- double click on 'ThisWorkbook' in the left explorer window
- paste the code from below (adapted to your specification)
- close the VBA editor

----

Private Sub Workbook_BeforePrint(Cancel As Boolean)
Dim wkSht As Worksheet
Dim source_wks as worksheet
Dim heading_str as string
set source_wks = me.worksheets("Coversheet")
heading_str = source_wks.range("C11").value & " " & _
source_wks.range("C13").value & " " & _
source_wks.range("C15").value

set wkSht = me.worksheets("Data")
With wkSht.PageSetup
.RightHeader = heading_str
End With
end Sub

--
Regards
Frank Kabel
Frankfurt, Germany

Thanks Frank for the reply, I'm lost on where you want me to put the
code and the worksheet name is Data.

I want to display Cell C11, C13, and C15 from Coversheet! on the
Header Right side on Data! sheet. And I want to display a disclaimer
which is Cell A50 from Coversheet! on the Center Footer of Data!
sheet.

Thanks again for your help. BTW and good books I can buy that will
help me with code.


---
Message posted from http://www.ExcelForum.com/

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Footer printing in wrong colour Jimmyschniz Excel Discussion (Misc queries) 0 January 18th 10 03:00 PM
Footer Printing Issue Liquid Excel Discussion (Misc queries) 0 February 19th 09 04:31 PM
Can I set a default to add a filepath footer when printing? bearcat1 Excel Discussion (Misc queries) 0 August 3rd 06 09:21 PM
Printing Full File Name in Footer Chaplain Doug Excel Discussion (Misc queries) 1 April 24th 06 04:14 PM
Add filename to footer before printing using VBA PCE Man Excel Discussion (Misc queries) 5 December 2nd 04 10:55 PM


All times are GMT +1. The time now is 12:38 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"