Oh yeah, the variable declarations are:
Dim xlApp As Excel.Application
Dim xlBook As Excel.Workbook
Dim xlSheet As Excel.Worksheet
If the variable declarations aren't working, you need to make sure you have a reference to Microsoft Excel Object Library under Tools/References
Try this instead:
Set xlApp = New Excel.Application
xlApp.Visible = False
Set xlBook = xlApp.Workbooks.Open(fileIn)
Set xlSheet = xlBook.Sheets(sheetIn)
Where fileIn and sheetIn are the file and path - you can see all the code at
http://www.tek-tips.com/viewthread.cfm?qid=1201057
My post...
The MsgBox should be called somewhat differently...
dim intReply as integer
intReply = MsgBox( .FileName, vbOKCancel, "Import Bakery Mfg Recipes)
if intReply = vbOk then
...
End if
This is checked.
In my troubleshooting I created an AutoReport: Columnar based on a table with 1 record. The report appeared in the taskbar when run. The only change I make is to add DoCmd.Maximize to the open event. The report then does not appear in the taskbar when run.
Nope.
In my troubleshooting I created an AutoReport: Columnar based on a table with 1 record. The report appeared in the taskbar when run. The only change I make is to add DoCmd.Maximize to the open event. The report then does not appear in the taskbar when run.
Are you seeing different...
ZmrAbdulla:
I have Windoes In Taskbar set to yes. When the report is opened without the DoCmd.Maximize, it appears in the taskbar. When DoCmd.Maximize is used it does not. I am attemtping to maximize reports when they are opened and still have them appear in the taskbar.
Any ideas?
Hi -
Typically in all my reports I put:
Private Sub Report_Activate()
DoCmd.Maximize
End Sub
This is so that the report opens maximized. However, when I do this, I don't get a taskbar entry for the report. I can see it in the "Window" menu in Access, but can't get to it by using...
Hi -
Typically in all my reports I put:
Private Sub Report_Activate()
DoCmd.Maximize
End Sub
This is so that the report opens maximized. However, when I do this, I don't get a taskbar entry for the report. I can see it in the "Window" menu in Access, but can't get to it by using...
vttech - I use a function to checked required entry field in forms (below). It pops an error for any indicated elements that are NULLs or empty strings. You can change what fields are checked by changing the array definition - the actual checking of the fields is looped based and doesn't need...
Have you considered youing DNSLess connections? I think this is probably the better way to go about fixing this problem.
***fMsgBox is a formatted MsgBox - you can repace this with MsgBox
tableIn is a table that contains 1 record. A field in that record is SQLServerConnectString...
I suggest skipping that FAQ and using Lebans calendar control - I think the FAQ is more of an example. Lebans calendar is a production ready classs you can drop into any application. The best calendar I have seen for MS access.
http://www.lebans.com/monthcalendar.htm
I do this fairly often. I create the query and export it to excel. You than open the excel sheet, select, 'Tools/Macros/Record New Macro' and make your formatting changes. You end the recording, hit ALT-F11 to get into code view and view the VBA generated in module1 in the 'modules' section...
Another take on getting the proper case - this will work for addresses, hyphenated names, full names, etc. This does mulitple iterative calls to a sub function, so not the speediest function in the world but pretty flexible and handles alot of scenarios.
? pcase ("141 e.14 st., john...
I was looking to do this the other day. Found this code that uses ADO stream. Need to have an ADO reference in the project (ADO 2.5+ I believe). Combined with Dev Ashish's apiShellExecute code, you can load files to an OLE/BLOB field, detach them and then launch them with the proper ap. Good...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.