Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Dealing with pop-ups


I wrote some code in VBA in order to make a excel form available fo
multiple data entry (share workbook). As the spreadsheet has som
linked data field, when people open it, it always ask for whether t
update all links.

Can VBA automate this ?

Also, I use some code to save the workbook and the workbook thus alway
ask users whether s/he want to save as a new name or replace the ol
file with the same name.

Can VBA automate this as well?

When I try to use the VBA code to make a shared workbook into exclusiv
use, it always ask user for confirmation by a pop-up (ask for yes o
no).

Can VBA automate this ?

Thanks a LOT....


Jason

--
Jason
-----------------------------------------------------------------------
Jasons's Profile: http://www.excelforum.com/member.php...fo&userid=1610
View this thread: http://www.excelforum.com/showthread.php?threadid=27602

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 52
Default Dealing with pop-ups

The easier questions first.

Surrounding your code with
application.displayalerts = false
'your code here
application.displayalerts = true

can stop a lot of those pop up messages--like you get when you save or unshare a
workbook:

'share it
Application.DisplayAlerts = False
ActiveWorkbook.SaveAs Filename:="C:\My Documents\excel\book2.xls", _
AccessMode:=xlShared
Application.DisplayAlerts = True


'unshare it
Application.DisplayAlerts = False
ActiveWorkbook.ExclusiveAccess
Application.DisplayAlerts = True



The links question:

You can toggle the setting (user by user, though) via:

Tools|Options|Edit Tab.
There's a checkmark for "ask to update automatic links"

But this means that you suppress the question--the links still get updated.

This setting is for the individual user--and affects all their workbooks.

If you want more control:
Try creating a dummy workbook whose only purpose is to open the original
workbook with links updated:

Kind of like:

Option Explicit
Sub auto_open()
Workbooks.Open Filename:="c:\my documents\excel\book2.xls", UpdateLinks:=1
ThisWorkbook.Close savechanges:=False
End Sub

Then you open the dummy workbook and the links will be refreshed.

And xl2002 added an option that allows you to have more control:
Edit|links|startup prompt button.
check the "don't display the alert and update links"



Jasons wrote:

I wrote some code in VBA in order to make a excel form available for
multiple data entry (share workbook). As the spreadsheet has some
linked data field, when people open it, it always ask for whether to
update all links.

Can VBA automate this ?

Also, I use some code to save the workbook and the workbook thus always
ask users whether s/he want to save as a new name or replace the old
file with the same name.

Can VBA automate this as well?

When I try to use the VBA code to make a shared workbook into exclusive
use, it always ask user for confirmation by a pop-up (ask for yes or
no).

Can VBA automate this ?

Thanks a LOT....

Jasons

--
Jasons
------------------------------------------------------------------------
Jasons's Profile: http://www.excelforum.com/member.php...o&userid=16108
View this thread: http://www.excelforum.com/showthread...hreadid=276028


--

Dave Peterson

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
Dealing with #VALUE! Maracay Excel Discussion (Misc queries) 3 February 10th 09 03:35 PM
dealing with time Rhydderch Excel Worksheet Functions 5 January 12th 09 11:37 PM
Dealing with +/- Values, Need Help Dust Devil Excel Worksheet Functions 1 April 18th 08 11:02 PM
Dealing with #N/A results SandyLACA Excel Discussion (Misc queries) 1 April 28th 06 04:11 PM
Dealing with errors [email protected] Excel Discussion (Misc queries) 6 March 27th 06 01:27 PM


All times are GMT +1. The time now is 02:26 AM.

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

About Us

"It's about Microsoft Excel"