Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Programming / November 2007

Tip: Looking for answers? Try searching our database.

Variable in Message Box Q

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Sean - 10 Nov 2007 11:00 GMT
I have a very simple Message Box that appears when a file is opened.
How could I have a variable referred to within this message box e.g if
my text to appear in the message box was referenced to G1 in sheet
"Sales"?

Thanks

Private Sub Workbook_Open()

MsgBox "Maximise Sales for w/c 05/11/07"
Range("A1").Select
Application.DisplayAlerts = True
Application.ScreenUpdating = True

End Sub
Jay - 10 Nov 2007 11:16 GMT
Hi Sean -

MsgBox "Maximise Sales for " & Worksheets("Sales").Range("G1")

---
Jay

> I have a very simple Message Box that appears when a file is opened.
> How could I have a variable referred to within this message box e.g if
[quoted text clipped - 11 lines]
>
> End Sub
Sean - 10 Nov 2007 12:13 GMT
Thanks Jay, its that simple!
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.