Disable Save Query Definition Option Vba

Jan 25, 2007

I want to be able to disable the save query definition option for a worksheet using VBA. Right now I have to right click a cell and then go to Data Range Properties and then uncheck the save query definition box. If there is a way to automate this that would be great.

View 3 Replies


ADVERTISEMENT

VBA To Remove Query Definition

Jan 29, 2011

My WB imports external data on file open

I want to extend my VBA code to uncheck "Save query definition" after the updated workbook is saved.

View 4 Replies View Related

Disable The "Save" Option From File Menu And Allow Only To "Save As"

Sep 24, 2002

How do I disable the "Save" option from File Menu and allow only to "Save as"?
Excel 97/2000

View 9 Replies View Related

Disable Option Button On Userform?

Jan 26, 2014

I have two option buttons on a user form, one for a temperature of <250 & one for a temperature >250. I want the option button >250 to be greyed out or have it so that you cannot choose it & option button <250 selected if a certain criteria in a list box is selected. The list box is called Valve_Model & the criteria i want it to work on is if the valve model HPBV Soft is selected & HPBV Soft AC.

View 14 Replies View Related

Disable Copy / Paste Option For Particular Sheet?

Dec 8, 2013

I have workbook having 3 sheets out of them 1 sheet name "report". I want vba to disable copy /past option to sheet Report only with msg " copy not allowed" if key clt+c or copy option selected

View 1 Replies View Related

Disable Forms Option Button Once Checked

Apr 15, 2008

After a user has selected the required option buttons, is there a way to disable them without deleting, so that they are still visible (for history tracking) but not modifiable?

'09-- Check metrology info
If Worksheets(" Split Lot Info").MetrologyYes.Value = True Then
Worksheets("Split Lot Info").Shapes("MetrologyYes").Enabled = False
Worksheets("Split Lot Info").Shapes("MetrologyNo").Enabled = False
If Worksheets("Split Lot Info").MetrologyNo.Value = True Then
nResponse = MsgBox("Are metrology steps set up?", vbOKOnly, "Missing information")
Worksheets("Split Lot Info").Shapes("MetrologyYes").Enabled = False
Worksheets("Split Lot Info").Shapes("MetrologyNo").Enabled = False
End
End If
End If

View 3 Replies View Related

Option To Hide The Sheet When Disable Macros Is Clicked

Apr 29, 2009

Is there any option to deactivate the "Disable macros"

Or

When i open the userform it asks for enable and diable macros. If i click "Disable macros" then the users can manipulate the data inside the excel sheet. i need to avoid this problem.

So, is there any option that if i do "Disable macro" then the corresponding sheet for the which the Userform is linked should not be visible or hidden.

View 9 Replies View Related

Remove/Disable Open File As Read Only Option

Apr 9, 2008

Is there a way to remove the option to open a file as read only when the file is already open by another user? Ideally when a user tries to open a file that is already in use they would get a message to that effect and the only option at that point would be for them to select "notify" when file is available.

View 8 Replies View Related

Disable Query Refresh Message On Open

Sep 24, 2007

I have a model which extracts data from an external data sournce using an ODBC query. This data is then used to generate a pivot table. I have incorporated code to update the query and the pivot table on startup but would like to disable the Enable Query Refresh message box which occurs at startup (it would also be nice to disable the security warning but I know that is a no no)

View 2 Replies View Related

Disable Save And Save As Feature In VBA

Sep 5, 2012

I am trying to disable the save and save as function using a macro, i know that this in its self is quite simple but i am making VBA create a new workbook and i want this (nameless) workbook to have the save feature disabled.

View 1 Replies View Related

Disable Manual Save But Let VBA Save?

Oct 5, 2011

I need my spreadsheet to require that the user save it by clicking a macro button, and not the Save or SaveAs options in the file menu. I have found out how to disable saving entirely:

Code:
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
Cancel = True
If SaveAsUI Then SaveAsUI = False
End Sub

But this of course prevents my macro button from saving too!

Is there any way to allow VBA code to save the spreadsheet while simultaneously preventing the user from saving through the menu?

View 2 Replies View Related

- Disable Save As And Define The Save Name

Nov 16, 2006

I have a file that I have created that the users will use as a master template to create data that I need. Once they have finished, I want the file to define what the filename should be when they click save.

At the same time, I want to disable "Save As..." as some users will just use that and then will use a file name that another macro (that I will use) won't recognise.

View 7 Replies View Related

Disable Save & Save As Buttons

Dec 13, 2007

I use to send reports to my seniors on daily basis.
I want these reports to be with me and they can just open and check the reports, when I send them. If they try to save file through File-Save or File-Save As, they should not get these options at all in the File Menu.

View 9 Replies View Related

Disable Save As PDF Or XPS

Apr 16, 2013

Is there a way to disable 'Save as PDF or XPS' with the macro? I have tried disabling 'Save as' with the below VBA code but it does not disable 'Save as PDF or XPS'.

VB:
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
If SaveAsUI Then
MsgBox "Save As is disabled", vbInformation
Cancel = True
End If
End Sub

Also I have a macro which saves the excel report in a PDF format with 'Save as PDF or XPS' utility. I would like to enable 'Save as PDF or XPS' when this macro is started and again disable 'Save as PDF or XPS' when this macro stops.

View 1 Replies View Related

Save Option Off The File

Dec 11, 2003

I want to be able to take the save option off the file in my macro to stop any user whos using the spreadsheet from saving full stop.

Is there a code where it will totally disable the save function, I have tried using the code for workbook protection, however this still aloows one to save.

View 9 Replies View Related

Exit Without Option To Save

Sep 8, 2005

Is there anyway I can make excel quit using VBA without the option of saving the changes popping up?

View 5 Replies View Related

How To Disable Save Function

Jul 23, 2012

I currently have a macro which does data mining and saves the workbook in the end. I intend to disable to the save function of the workbook and force the user to use the macro everytime the workbook needs to be saved. this is what i have so far but it does not seem to work. Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)

Dim NoSave
NoSave = MsgBox("Changes have to be submitted before the workbook can be saved, Proceed and submit ?", vbYesNo, "Continue?")

[Code]....

View 3 Replies View Related

Disable Save As In Excel

Mar 22, 2007

I need to disable 'save as' in an excel file. I have read some previous topics but I cant understand it. Is there anyone who can explain it to me as detailed as possible?

View 9 Replies View Related

Prevent Save Option If Condition Not Met

Sep 28, 2006

I have a list dropdown from cells A2 to A10. If only when a user selects "orange", he has to key in some description in column B.

Eg if he selects orange in A2, he has to key in some description in B2.

Is it possible to set some formula or macro which prevents user to save this file if he leave blank in B2 or B10, depending on which row he has select "orange"?

View 8 Replies View Related

Disable Save As And Lock All Cells

Jul 10, 2013

I have a worksheet i want to disable

(1) save as function (if someone wants to saveas another name then it will ask for password

(2) lock all cells but unable autofilter (in my document if some one type in textbox given above it filter as typing....

My target to make it copyproof sheet and if someone copies my sheet than it is useless without password although user can only search books...

View 1 Replies View Related

Disable Save As At Program Level?

Jan 29, 2014

I know the disabling of 'Save As' has been covered alot. I have successfully disabled both Save and Save As at the file level by the following:

Making file Read Only (which disables Save option)

Inserting the following VBA to make the Save As disabled.

[Code].....

The remaining problem I have is disabling the Save As prompting at the program exit level.

For example, if I have a read only file with Save As disabled and I choose the workbook (file) level close window (X) button, I am prompted to save the file but am not allowed to. This is the behavior I am looking for.

HOWEVER, if I choose to exit the file by selecting the program (Excel) level close (X) button, I am prompted to save a copy of the file and it allows me to do it.

I do not want my ~180 users to have any option to save the file once it is uploaded to a centralized server location. It is a large file and I do not need multiple versions floating around.

Is it also possible to disable the 'Save As' on close at the Program level??

View 1 Replies View Related

Disable Save Except When Pressing Button Or Using Modifier?

Apr 15, 2014

I have a button in a template file, that when clicked, saves the file as a new file with file name based on data in certain cells.

I want to disable the ability to save the file with the Save icon or Ctrl-S, but the button still needs to be able to save it (the button is technically doing a Save As, so no problem there). But, I, as the administrator of the template, need to somehow be able to save updates to the template file. Can this be accomplished by coding Save to work when used with a secret key combination that only I know (I can put it in password-protected VB code)?

Then, as if that's not tricky enough, the trickier part is that once the file is saved as the new file (no longer the template) - re-enable the Save button and Ctrl-S so the user can then save it as many times as they want.

View 3 Replies View Related

Disable Save & SaveAs Menu Items

Jul 13, 2006

Is there a code or a way to make it impossible to make permanent changes to a file without first saving it as something else? I have a master report that is done monthly.

I do not want anyone to be able to save any changes on the master report. How do I go about disabling save and the save as funtions in excel? I have a save as command button that I only want people to use.

Also is there a way to set up a print command button to print to any computers default printer? I have set up a print command button on my computer and it works fine on mine, but I have sent the file to another person and the button is not doing anything on their computer. I assume because we don't have the same computers.

View 6 Replies View Related

Disable Save / Save As

Aug 8, 2009

i tried all vba's here and on google to disable save / save as, but none of them work so i would like to know the other way , how to go with clearing the contents of cell, the moment someone clicks save / save as, with /without range by using beforesave event

View 9 Replies View Related

Want To Disable Save And Save As

May 9, 2002

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, _
Cancel As Boolean)
a = MsgBox("Save Is Disabled", vbOKOnly)
If a = vbOK Then Cancel = True
End Sub

How do I get out of this file with my changes? Don't laugh.

This what I ended up with:....

View 9 Replies View Related

Excel 2007 :: How To Initiate Auto Save Option

Apr 18, 2013

I want to know what is the way to auto save our excel sheet data ?

View 3 Replies View Related

Open Message Box Or Disable Option On Open

Mar 30, 2007

how to make a MsgBox open anytime a cell in Column A was double-clicked--and the content of the MsgBox was from the cell in the same row in column Z. I've now realized the double-clicking isn't an ideal solution, as it's easy to click in another cell and mess up all the formulas.

(1) Code that deactivates the "edit directly in cell" option when the workbook is opened.

(2) Code that opens the MsgBox when a cell in Column A is clicked just once (or similarly less fool-proof than double-clicking or right-clicking).

View 2 Replies View Related

Save Old Data When Web Query Refreshes

Jun 27, 2009

When the data is refreshed, how can i keep the previous data and use it in a graph that automatically updates?

View 12 Replies View Related

Macro To Hide Cut,copy,paste,save,saveas Option In Word

Feb 15, 2007

I want to restrict users to just read or print a word document. Document is very confidential so we dont want them to copy or manipulate the document.

I thought of giving password to restrict to read only option but that still lets users to copy and paste on to a new document.

View 9 Replies View Related

(Save As) Variable File Format Routine Query

May 31, 2012

The following code stops at the red line with "Method 'SaveAs' of object '_Workbook' failed.

FF="xlCSV". It works fine if I replace
Code:
FileFormat:=FF
with
Code:
FileFormat:=xlCSV

Code:

Sub SaveIt(FileNm, FF)
Dim FSO As Object, a
Set FSO = CreateObject("Scripting.FileSystemObject")
If FSO.FileExists(FileNm) Then FSO.DeleteFile FileNm
If FSO.FileExists(FileNm) Then

[code]....

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved