Hi,
Is there any way of creating some form of copyright message that pops
up when a user opens a particular workbook? They then have to agree to
the terms to enter.
Thanks,
Mark.--
mevetts------------------------------------------------------------------------
mevetts's Profile: www.excelforum.com/member.php...oamp;userid=29130
View this thread: www.excelforum.com/showthread...hreadid=496603Not foolproof but one way
Private Sub Workbook_Open()
ans = MsgBox(quot;© MEvettsquot;, vbOKCancel)
If ans = vbCancel Then
ThisWorkbook.Close savechanges:=False
End If
End Sub
'This is workbook event code.
'To input this code, right click on the Excel icon on the worksheet
'(or next to the File menu if you maximise your workbooks),
'select View Code from the menu, and paste the code--
HTH
Bob Phillips
(remove nothere from email address if mailing direct)
quot;mevettsquot; gt; wrote in
message ...
gt;
gt; Hi,
gt;
gt; Is there any way of creating some form of copyright message that pops
gt; up when a user opens a particular workbook? They then have to agree to
gt; the terms to enter.
gt;
gt; Thanks,
gt;
gt; Mark.
gt;
gt;
gt; --
gt; mevetts
gt;
gt;
gt; ------------------------------------------------------------------------
gt; mevetts's Profile:
www.excelforum.com/member.php...oamp;userid=29130
gt; View this thread: www.excelforum.com/showthread...hreadid=496603
gt;
Hi,
I have pasted the code in, but I get an error message in Visual Basic
when I open the workbook.
It says - 'Compile error: Ambigious name detected: Workbook_Open'
Any thoughts?--
mevetts------------------------------------------------------------------------
mevetts's Profile: www.excelforum.com/member.php...oamp;userid=29130
View this thread: www.excelforum.com/showthread...hreadid=496603You only get one workbook_open event.
So you'll have to extract Bob's code and merge it into your existing
workbook_open routine.
mevetts wrote:
gt;
gt; Hi,
gt;
gt; I have pasted the code in, but I get an error message in Visual Basic
gt; when I open the workbook.
gt;
gt; It says - 'Compile error: Ambigious name detected: Workbook_Open'
gt;
gt; Any thoughts?
gt;
gt; --
gt; mevetts
gt;
gt; ------------------------------------------------------------------------
gt; mevetts's Profile: www.excelforum.com/member.php...oamp;userid=29130
gt; View this thread: www.excelforum.com/showthread...hreadid=496603
--
Dave Peterson
Ah, ok. Thanks, will do.--
mevetts------------------------------------------------------------------------
mevetts's Profile: www.excelforum.com/member.php...oamp;userid=29130
View this thread: www.excelforum.com/showthread...hreadid=496603
It works nicely, thanks. It is dependent on the user enabling macros,
but they need to do this anyway.
Thanks again.--
mevetts------------------------------------------------------------------------
mevetts's Profile: www.excelforum.com/member.php...oamp;userid=29130
View this thread: www.excelforum.com/showthread...hreadid=496603If macros aren't enabled, then none of your macros will work. (You can't use
macros in the workbook to enable macros for that workbook.)
mevetts wrote:
gt;
gt; It works nicely, thanks. It is dependent on the user enabling macros,
gt; but they need to do this anyway.
gt;
gt; Thanks again.
gt;
gt; --
gt; mevetts
gt;
gt; ------------------------------------------------------------------------
gt; mevetts's Profile: www.excelforum.com/member.php...oamp;userid=29130
gt; View this thread: www.excelforum.com/showthread...hreadid=496603
--
Dave Peterson
Indeed.
--
mevetts------------------------------------------------------------------------
mevetts's Profile: www.excelforum.com/member.php...oamp;userid=29130
View this thread: www.excelforum.com/showthread...hreadid=496603
Is there any way of creating a line break in the text?
I would like two short pieces of info in the pop up, but I don't know
how to create a new paragraph. When I just hit enter in the code it
turns the line to red and gives and error message!
Cheers.--
mevetts------------------------------------------------------------------------
mevetts's Profile: www.excelforum.com/member.php...oamp;userid=29130
View this thread: www.excelforum.com/showthread...hreadid=496603Private Sub Workbook_Open()
ans = MsgBox(quot;© MEvettsquot; amp; vblf amp; quot;second linequot; amp; vblf _
vblf amp; quot;another linequot;, vbOKCancel)
If ans = vbCancel Then
ThisWorkbook.Close savechanges:=False
End If
End Sub
mevetts wrote:
gt;
gt; Is there any way of creating a line break in the text?
gt;
gt; I would like two short pieces of info in the pop up, but I don't know
gt; how to create a new paragraph. When I just hit enter in the code it
gt; turns the line to red and gives and error message!
gt;
gt; Cheers.
gt;
gt; --
gt; mevetts
gt;
gt; ------------------------------------------------------------------------
gt; mevetts's Profile: www.excelforum.com/member.php...oamp;userid=29130
gt; View this thread: www.excelforum.com/showthread...hreadid=496603
--
Dave Peterson
- Sep 29 Fri 2006 20:09
Copyright message?
close
全站熱搜
留言列表
發表留言