I have cut and pasted a procedure to enable me to display pictures on a form and somehow got to be where I am right now with something that sort of works. Don’t ask me how I got this thing working because I have no clue. The fact that it works is truly a miracle of sorts.
There 3 issues which I cannot get sorted out with my extremely limited access knowledge
Firstly, when I start up my database – I get a “Security warning VBA Macro” which never happened before. I think this has to do with the picture procedure that I copied from the supplied site. As I know I should not have any macros in my system, there is probably one now embedded in there somewhere. If this is the correct line of thinking, can you please help me get rid of it. The second and more irritating issue is when I load my default form: Frm_Contacts_Details_All_Full_Page I get the following error Access cant find the field “Picture_Location” referred to in your expression. I have figured out that this must be in an expression on the form properties somewhere, but I’ll be dammed if I can find it. Please help! And lastly: Why is it that I can only open Frm_Pictures in the default view whereas all the other created forms, I can open and then select the design view.? If these problems can be solved by you, I will gladly send you the shell of teh database sa that you can see what I am actually talking about here.Thanks In advance Rob
An expert who has achieved level 2 by getting 100 points
An expert that got 5 achievements.
An expert who has written 50 answers of more than 400 characters.
An expert who has written 20 answers of more than 400 characters.
Re: Problem with macro and On Open procedure
Ignore the warning (it's there for your protection). Do a search for your default page and / or insert it into your expression, presumably a script of some sort from (who knows where and being a bit more specific would have helped....grrr). The last problem might be because you have them located in a different area (folder). Check and see. Search (or find) on the name of one that does show and one that does not appear.
A 6ya expert can help you resolve that issue over the phone in a minute or two.
Best thing about this new service is that you are never placed on hold and get to talk to real repairmen in the US.
The service is completely free and covers almost anything you can think of (from cars to computers, handyman, and even drones). click here to download the app (for users in the US for now) and get all the help you need. Good luck!
- If you need clarification, ask it in the comment box above.
- Better answers use proper spelling and grammar.
- Provide details, support with references or personal experience.
Tell us some more! Your answer needs to include more details to help people.You can't post answers that contain an email address.Please enter a valid email address.The email address entered is already associated to an account.Login to postPlease use English characters only.
Tip: The max point reward for answering a question is 15.
macro on means that the lenses of the camera are enabled to take pictures at a very short distance, it's like a zoom but with the camera placed very close to the object being photographed.
macro off disables this feature.
The default Excel
file format. Cannot store VBA macro code or Microsoft Excel 4.0 macro sheets
(.xlm files in Excel 4.0).
Uses the same basic
XML format as the Excel Workbook, but can store VBA macro code. Users saving
an Excel workbook that has VBA code or Excel 4.0 macro sheets (.xlm files in
Excel 4.0) are prompted to use this file format.
The default file
format for an Excel template. Cannot store VBA macro code or Excel 4.0 macro
sheets (.xlm files in Excel 4.0).
Can contain a
VBAProject part or Excel 4.0 macro sheets (.xlm files in Excel 4.0).
Workbooks created from this template inherit the VBAProject part or Excel 4.0
macro sheets that exist in the template.
program that runs additional code. Excel add-ins use the Open XML file format
to store data, and they support using VBA projects and Excel 4.0 macro
Highlighting is similar to cutting the portion of text to be pasted at an alternative area on the page displayed. Right clicking on the portion of text should generate the features list to cut text as copies to be later pasted onto another area. A situation where text cutting or copying is achievable though does to allow to paste on the same area has alternate capabilities of achieving success. Cut the email text required paste to an opened empty Microsoft word document to edit into desired specifications. Usually, the email has least capacity to allow several functions all at once. A cut text may be possible least allowing pasting since the program is still in enable mode until uncut is achieved. For example, cut the portion required to paste on clipboards or Microsoft word document. Once the text that was cut is pasted elsewhere, the function of cut has been disabled. Returning to the email area requiring pasting should be achievable with an open display area requesting a past feature. In which instance, the open Microsoft document contains the copy that would provide display to the email section requesting displays.
You can create a macro by using the macro recorder to record a sequence of actions, or you can create a macro from scratch by entering Visual Basic for Applications code in the Visual Basic Editor. Open a new document. From the Tools menu, choose Customize. Click the Commands tab and then scroll down in the Categories box and select Macros. You’ll see the names of any macros you've created in the Commands box on the right-hand side. Click, hold, and drag your macro onto any toolbar and release, as shown in Figure D. A button with the name of the macro will appear on the toolbar.
if the form "products" really exists, then your office 2007 security settings are not allowing to load macros. Try the following settings:-
Office 2007 has some security settings disabled by default to prevent any harm to your system.
go to trustcenter settings(click the office button at the top left of the office 2007 screen then click Access options, then select Trustcenter, then click trustcenter settings.)
In trustcenter settings, select message bar then select "Show the message bar in all applications when content is blocked" radio button.
Then from macro settings ,make sure to select "Disable all macros with notification" . Click ok twice to close the settings windows and try opening the file again.
It seems that you have your Database(.mdb) file is created in Office 2003.... thats why you are unable to open it in 2007.... I faced the same problem.... then I came back to 2003 in order to use our database......
You can set a default value in most form items under the properties of that item. Look for "value". You can also do this in code, by setting up a sub routine to set/reset the values on your form. Then just run the sub routine before you open or enter the form.
Private Sub resetForm()
'formname.itemname = value UserForm1.Label1 = "Hello World"
For the second one you have a couple of options, you can find the bottom on the data and store the row index in a variable, use a loop to find the next empty cell in a row, and store the value or you can use the current region method to select all the cells with data continously touching the selected range. Example below
Click the Microsoft Office Button , and then click Excel Options. In the Popular category, under Top options for working with Excel, select the Show Developer tab in the Ribbon check box, and then click OK.
Note The Ribbon is a component of the Microsoft Office Fluent user interface. To set the security level temporarily to enable all macros, do the following: On the Developer tab, in the Code group, click Macro Security.
In the Macros Settings category, under Macro Settings, click Enable all macros (not recommended, potentially dangerous code can run), and then click OK.
Note To help prevent potentially dangerous code from running, we recommend that you return to any of the settings that disable all macros after you finish working with macros. Open the workbook that contains the module that you want to copy and the workbook that you want to copy the module to. On the Developer tab, in the Code group, click Visual Basic. On the View menu, click Project Explorer . Drag the module that you want to copy to the destination workbook.
Hi, There a couple of different way you could do this and I have put two lots of VB code below that you can modify and use. Firstly you create the Combobox list by choosing the option that you will type the values yourself, you then type in all your report names on each line. After that you can then go to the VB code editor and paste my code in and modify it by changing my report names, (Customers) etc to your report names. Make sure you choose the Combobox and the On_Click option in the VB editor to paste the code into. I like the first method better which checks the value of the Combobox and then opens the corrosponding report in the maximised form. The second method does the value check before running an assigned macro to open each report. With this you must first assign macros to each report in Access. Remember each of these bits of code must be placed between the "Private Sub" heading and the "End Sub" ending, and change the "Combo23" name to reflect your combobox too. If you need a hand just email me.
If Combo23.Value = "Customers" Then DoCmd.OpenReport "Customers", acViewPreview, acWindowNormal DoCmd.Maximize
If Combo23.Value = "Customers" Then DoCmd.RunMacro "Macro1" DoCmd.Maximize ElseIf Combo23.Value = "Customers 1" Then DoCmd.RunMacro "Macro2" DoCmd.Maximize ElseIf Combo23.Value = "Customers 2" Then DoCmd.RunMacro "Macro3" DoCmd.Maximize End If