Advertisement

07.06.2008 at 07:02AM PDT, ID: 23541638
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

7.7

How would you prevent from displaying the Excel automatic message box question "Do want to save the changes you made to xx.XLS" when an Excel file is closed ?

Asked by zimmer9 in Microsoft ADP, Microsoft Excel Spreadsheet Software, Access Coding/Macros

I am developing an Access 2003 application using Access as the front end and SQL Server as the back end database. I use the DoCmd.Transferspreadsheet command to transfer an Access table to Excel.
After the user views the Excel file and attempt to close the file, Excel automatically asks the following question in the form of a Message Box:

Do you want to save the changes you made to 'AAACCTS_2008....XLS' ?   YES   NO   CANCEL

I use the following subroutine to DELETE the Excel file if the user chooses to do so. This routine works fine but I would like to prevent the Message Box generated by Excel from displaying and instead use my own MESSAGE BOX which would display the following question:

Do you want to save the file   YES    NO

Could you tell me how to prevent the 1st message box as follows:

"Do want to save the changes you made to 'AAACCTS_2008....XLS' ?   YES   NO   CANCEL"

from displaying that is generated by Excel automaticallly, perhaps by using the commands:

xlApp.DisplayAlerts = False
xlApp.DisplayAlerts = True

I just want the following Message Box to display:

Do you want to save the file   YES    NO
----------------------------------------------------------------------------------------------------------

Private Sub StartDocLexNex(filename, footnote, strScreenType, txtDateFrom, txtDateTo)
 
 Dim xlApp As Excel.Application
 Dim xlWB As Excel.Workbook
 Dim xlWS As Excel.Worksheet

 Dim intRows As Long
 
 Set xlApp = CreateObject("excel.application")
 
 xlApp.Workbooks.Open (filename)

 xlApp.Visible = True
 Set xlWS = xlApp.ActiveWorkbook.Worksheets(1)
 xlWS.Columns.AutoFit
 
 intRows = xlWS.UsedRange.Rows.count

 xlWS.Cells(intRows + 5, 1).Value = footnote
 
 xlWS.Cells(intRows + 6, 1).Value = "For the period " & txtDateFrom & " To " & txtDateTo
 xlApp.ScreenUpdating = True

 If (MsgBox("Do you want to save the file", vbYesNo)) = vbYes Then
   For Each xlWB In xlApp.Workbooks
       xlWB.Save
   Next xlWB

   Set xlWS = Nothing
   xlApp.Quit
   Set xlApp = Nothing
 Else
   
   xlApp.ScreenUpdating = True
   xlApp.Workbooks.Close
   xlApp.Quit
   Set xlWS = Nothing
   Set xlWB = Nothing
   Set xlApp = Nothing

   Kill filename
 End If

End SubStart Free Trial
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
Private Sub A1099AAAAccts()            
    Set cn = New ADODB.Recordset
    strScreenType = "A1099"
        
    cn.ActiveConnection = CurrentProject.Connection
    cn.CursorType = adOpenStatic
    cn.CursorLocation = adUseServer
    cn.LockType = adLockReadOnly
            
    DoCmd.Hourglass True
    strScreenType = "A1099"
    
    Set com = New ADODB.Command
    With com
       .CommandType = adCmdStoredProc
       .CommandText = "dbo.procUDLAAAAcctsMod"
       .Parameters.Append .CreateParameter("DteFrom", adDate, adParamInput, , CDate(txtDateFrom1099.Value))
       .Parameters.Append .CreateParameter("DteTo", adDate, adParamInput, , CDate(txtDateTo1099.Value))
       .ActiveConnection = CurrentProject.Connection
       Set rstQueryFS = .Execute
    End With
        
    ExportedFile = strAccessPath0 & "AAAACCTS" & "_" & intYearSP & "_" & Format(Now, "mmddhhnnss") & ".XLS"
 
    DoCmd.TransferSpreadsheet acExport, 8, "dbo.tblUDLAAAAccts", ExportedFile, True, ""
           
    footnote = "This file represents AAA Debit Card Account Activity."
       
    MsgBox "AAA Debit Card Account records have been exported to Excel", vbOKOnly, ""
      
    If isFileExist(ExportedFile) Then StartDocLexNex ExportedFile, footnote, strScreenType, txtDateFrom1099.Value, txtDateTo1099.Value
    
    DoCmd.Hourglass False
End Sub
[+][-]07.06.2008 at 07:23AM PDT, ID: 21940431

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 08:18AM PDT, ID: 21940572

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 08:37AM PDT, ID: 21940629

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 03:03PM PDT, ID: 21941779

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 04:27PM PDT, ID: 21941987

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 04:29PM PDT, ID: 21941993

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 04:36PM PDT, ID: 21942012

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 04:46PM PDT, ID: 21942029

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 04:50PM PDT, ID: 21942039

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 04:52PM PDT, ID: 21942041

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 05:16PM PDT, ID: 21942093

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 05:31PM PDT, ID: 21942132

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 06:27PM PDT, ID: 21942293

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 06:54PM PDT, ID: 21942396

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 06:59PM PDT, ID: 21942411

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 07:16PM PDT, ID: 21942442

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 07:21PM PDT, ID: 21942454

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 07:25PM PDT, ID: 21942469

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 08:10PM PDT, ID: 21942577

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.06.2008 at 08:19PM PDT, ID: 21942603

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Microsoft ADP, Microsoft Excel Spreadsheet Software, Access Coding/Macros
Sign Up Now!
Solution Provided By: Reafidy
Participating Experts: 4
Solution Grade: A
 
 
[+][-]07.07.2008 at 04:46AM PDT, ID: 21944129

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.07.2008 at 10:49AM PDT, ID: 21947117

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628