[VBA Excel] Finish with an accent

DSC_5785.jpg

Let’s say: we have our macro almost completed, all we need to do at the end is customize our worksheet and save the file properly, with password required at next opening.

We can record some part of the code and use options descirbed already here.

This little sample might be useful for you. You can develop following code by adding color for worksheet, hide formula bar, save copy wiht other format etc.

Example of report close ready to generate

smpl of rep.jpg

Code ( You can copy below presented code, if you want to: LastSteps&Saving )smpl of rep2.jpg

smpl of rep3

DoCMD basic moves on Access objects

DSC_5759.JPG

From few weeks we have in whole country mushroom fever. No one expected such a mass of funguses, especially spill of boletus. So, nowdays I spend lot of time in the forest, for hours, with my family. And yes, I’ve seen lot of wilds, mostly deers. But it’s really hard to bend over your find and take a photo of beautiful proud bull with majestic antler at the same time 🙂 Anyway , if you are also type of threatened mushroom picker, be carefull, and whatch your steps,  cause mother-in-law is always follow ^^.

DSC_5617kk.jpg

With my latest post about importing Excel files into MS Access using VBA codes we already met simple examples of DoCommands. Time to get some other most useful methods for our project objects: tables, forms, querries and modules.

if only we will start writing DoCmd. built-in-library show us basic methods from the quicklist:

ex1

With following short procedures you can easily get knowdledge how to open, close and delete obejcts form code side.

Let’s make a copy first

DoCmdCopy.jpg

and then open it in different ways

DoCmdOpenCopies.jpg

As you can see for table I choosed pivot view.

Time to close our copies, delete them and quit whole application after.

DoCmdcloseCopies.jpg

for more DoCMD methods visit docs.microsoft.com. Enjoy!