IE is the only browser that provides external API access to control it. The browser does so much more than just read simple HTML. It parses JavaScript and CSS, downloading all the support files as well as making AJAX calls where appropriate. It is actually pretty complex. Google for an overview of everything your web browser does.
You wouldn't be able to use other objects for anything but the most basic of websites or to talk to web services directly. Google VBA and WinHttp object for more details as one object that will allow you direct access to a URL.
One challenge that I recently had to overcome was how to get at the data that is populated through AJAX (most likely to make it harder to scrape and access said information, but possibly just for speed so that the rest of the page would load and the data would load as it became available) in an iframe. See below for my solution to get at that data.
Security and limitations in all the browsers are typically because they were exploited by people with malicious intent, ruining it for programmers who want easy access to the browser and its data.
I've used Selenium recently to control other browsers and this article may give some insight in how to do so using VBA: http://www.makeuseof.com/tag/how-to-automate-firefox-or-chrome-with-vba-and-selenium/
It will require installing some 3rd party stuff to get work but will give you complete access to the data in the web browser after it has loaded said data in the browser.
Edit: missing word
I'm old school and prefer learning by book rather than videos.
"Power Programming with VBA" is an excellent resource. I believe this is the latest edition.
OK here's my finished work...
This worked in my tests, but obviously your system will be unique and we'll almost 100% have some small bugs to fix. Let me know if you have any questions or issues. Happy to fix any problems that come up.
Note this is very bare bones... I tried to keep it very simple. I adopted this from existing code I use which is thousands of lines long, but it's much more modular, with advanced error handling and stuff like that.
If you already know how to write in any programming language learning a new one of the same paradigm isn't too difficult. and if you already know VBA (an imperative object-oriented language) then transitioning over to Typescript shouldn't be too hard.
https://www.typescriptlang.org/docs/ here is the official typescript documentation page, it has pages for people coming from different languages as well as a guide for new programers. I can only vouch for the quality of the "TS for Java/C# Programmers" page, but I am assuming all the others are of a similar level of quality.
the biggest hurdle will be leaning how to use all the new features that modern languages give you that VBA lacks; most notably, inheritance and other OOP principles (while at the same time allowing free functions so you don't need to mess around with static classes & singletons like you do with 'pure' OOP languages like Java & C#), template metaprogramming using generics, first-class functions, async/await, & namespaces.
Stack Overflow confirmed my suspicion. Nothing in your sheet looked suspicious- could certainly be optimized (do you want to live in a world where Copy and Paste are never bothered with? because that's possible, and faster, too) if you were making a huge project, but fine for one worksheet that isn't enormous.
Honestly until I understood some of the basics of programming, googling "VBA <insert problem or function>" got me through a lot.
The physical task of taking your formulas and filling down the range isn't performed until the AutoFill command is passed, so any problem with AutoFill should start there, assuming the references to worksheets and ranges are fine. And they are, because you'd get an error message otherwise.
I mentioned using F8 earlier and I recommend you look into it for future debugging, as well as learning what the Locals Window is. By stepping through the code line-by-line you can see that the code executes as expected on every line except the AutoFill line. So that's where I started looking for problems, and found that activating the destination sheet was my solution.
/r/learnjavascript
https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures
r/learnprogramming/
There are thousands more I'm sure
If you've got no programming experience outside of VBA, it can be a little rough to get started because you likely need to learn the basic fundamentals of programming. Things like loops, ifs, classes, functions, variables, arrays, etc. You may have experience with some of that through vba, but once you have a strong grasp of the fundamentals, learning other programming languages becomes easier because the fundamentals are mostly the same between the languages. all that really changes is the "grammar" (how the various things are constructed and laid out).
I'd consider another language anyway, since if you're already making the effort to refactor everything, porting it at the same time isn't that much added effort. I say this because most of your calls will be into the Excel's COM interface, which is nearly the same no matter what language you're using to access it.
Anyway, Stack Overflow has a list of general best practices for VBA, but these may be old news to you if you're at the point of using classes. As for your specific questions:
> what should exist in the Add-In and what should be in the workbooks?
I would put nearly everything into the add-in. With .xla
add-ins, you can include sheets in the add-in, then copy them from the add-in to the active workbook. That gives you a way to insert template sheets from the add-in.
> Can/should I control formatting from the Add-In?
What do you mean by this? All the VBA functionality exposed when adding code to a workbook is also exposed in an add-in. However, I rarely find the need to call formatting commands, as it's better to set up conditional formatting on your template sheets.
> Is it recommended to load and unload the add-in automatically when a workbook opening and closing a workbook?
I would keep the add-in loaded at all times, and use some identifier attached to the workbook – like a workbook-level named range – to determine whether the add-in should be active or not.
> Multiple lookup tables and parameter values are shared between the workbooks, should/can store these values in the Add-In?
You can, and if you're going that route I would recommend putting the lookup tables into a sheet in the add-in, then creating a UDF for each table that wraps around INDEX
/MATCH
. But really, you should be using a database for this stuff.
The IE object is a bit limited.. here's a blurb from StackOverflow about it though
Again, this assumes you're sending e-mail outside your company, if you're spamming your employees, no one will care.
EU CAN-SPAM Looks like it's called "ePrivacy Directive", and GPDR looks to be sticking its nose in too...
Using a company that is dedicated to sending out mailings will help you avoid pitfalls, and maybe even fines. Plus they can offer analytics and such.
i think i found the issue you're looking at
It has to do with your copy and paste into a text editor. There are several solutions in the link.
There's some snippets linked from StackOverflow about Finding e-mails more efficiently.
Or, do you mean that its doing it on EVERY e-mail, whether or not it has the keyword?
Shows using post. You could cobble together this with the other code if needed.
The HTML on this page is a mess and it loads the weather using javascript after the page load so you have to open an instance of IE which is the slow way to do this. I would find a better source like getting an API key for Google or openweathermap.org. The query to an API will take an eye blink, this take several seconds (10-20 depending on your machine).
Don't forget the references!
Option Explicit 'requires references to: 'Microsoft HTML Object Library 'Microsoft Internet Controls
Sub getHumidity()
Dim tbl As HTMLTable Dim humSpan As HTMLSpanElement Dim ie As InternetExplorer Dim htmlDoc As HTMLDocument Dim strdata As String Dim data Dim x As Long Dim y As Long x = 1 y = 1
Set ie = New InternetExplorer ie.Visible = False ie.navigate "https://weather.com/weather/today/l/78238:4:US"
Do While ie.readyState <> READYSTATE_COMPLETE DoEvents Loop
Set htmlDoc = ie.document
Set tbl = htmlDoc.getElementsByTagName("table")(0)
Set humSpan = tbl.getElementsByTagName("span")(1)
'print the humidity to the Immediate Window Debug.Print humSpan.innerHTML
ie.Quit
Set humSpan = Nothing Set tbl = Nothing Set htmlDoc = Nothing Set ie = Nothing
End Sub
Give UpWork.com and Guru.com a try. I've been freelancing on UpWork for the past six years. It takes time to build up reviews, but over time, you'll receive invitations almost daily.
If you're just trying to visualize an STL, you can try FreeCAD.
As the name implies, it is free. I haven't used it much but I just tried importing a .stl file and it worked without issue.
Alternatively, this is a stretch, but if you have access to Solidworks, the macro API supports VBA. That would be relatively simple to import an STL programmatically.
It's not trivial, but it certainly can be done via VBA.
Here's something to get you started.
Here is one I did for a fellow redditor ages ago that may be of help:
http://www.filedropper.com/producttracking2
It has a summary page, derived from the data page that has a running total instead, but the code can be easily changed if you need it to.
To automate running your job you could use Jenkins
Or
Microsoft Power BI has scheduling functionality but If you would rather use VBA you could use code similar to below ( this would require leaving Excel open all the time (not a good idea). Not my code!
You are definitely outside the realm of Excel here. And, I would say, Access as well.
Depending on what your company allows, etc. I would go PostgreSQL. Also, Excel & PostgreSQL work together well, including via VBA
VBA is perfectly capable of doing everything you want. However, it may be easier for you to use a cloud based project tracking application. There are tons of them from Monday.com to airtable.com
I'm a big fan of Excel and Access and currently use both in my work life, but you'd need someone to build this for you (which would take several hours), or you'll need to learn this skill yourself.
If you want to start to learn yourself, play around with the "Record Macro" function in Excel. Perform a few tasks and see what the VBA looks like.
People here are going to shy away from people with zero experience looking for a free build. This site is more about helping when you're stuck on a build. What you're looking for isn't overly difficult, it's just time consuming.
Just saw this on LinkedIn and might be worth checking out.. Not VBA per sec but really good coverage on all of Excel's latest tools.
Author has a good pedigree
Advanced Excel Success: A Practical Guide to Mastering Exce... https://www.amazon.co.uk/dp/1484264665/ref=cm_sw_r_wa_awdb_imm_t1_XP43FbYNB4CRR
Looking forward to the release of this, although the release is listed as April 1st on Amazon so hopefully it's not a prank ;-)
You should speak to our own /u/excelevator near the time to see if you could get some sort of announcement/AMA on /r/excel.
Due to the amount and type of data that is pulled from the other workbook that I do not have control over, I am unable to obtain a copy; however, I was able to sanitize a copy of the active workbook that is being used. See it here:
https://drive.google.com/file/d/0BwqTmhq1er0wOGVYRlNxRTRYNEk/edit?usp=sharing
To explain what happens. We have a badge reader that inputs text from the employee's proxy badge. The guard selects the next available cell in the B column. The "requestie" will swipe their badge, it converts their badge ID into text and inputs it into the cell. At that time a VLOOKUP will pull from the other data sheet to fill in that person's name. The macro will then unlock the workbook, put a time stamp of activity in the C column and then relock the workbook. To ensure that no one is fudging with the entries, another tab called "Log" records all changes done to the main tracker.
The guard then swipes the badge assigned to the appropriate key which does a VLookUp for that information.
Lastly, when the key is turned in, the guard will select the appropriate F cell for that key and the person will swipe their badge again, doing all of the first step all over again.
I hope that is helpful. Let me know if there is anything else I can do.
Again, not positive, but I THINK if you dump CreateInstance, and rename "Initialize" to "Class_Initialize", it'll be automatically called when you New the class, eliminating a step.
Not sure why ignorance is worth downvoting though, you admit what you don't grok at least. :)
If you are going by your gut, yeah, a computer can't help you. But if you clarify your thinking by making an algorithm, then you can write some code to evoke conditions more surely and make your decisions faster.
Possibly there is value in knowing the drops based on the algorithm I showed you for determining all the drops. But permit me a bit of editorializing when I ask, "Where are the customer's yachts?"
Sub hidespecificcells()
'
'
Range("A4").Select
With Sheets("sht1").PivotTables("Pivottabell1").PivotFields("supplier")
.PivotItems("").Visible = False
.PivotItems("A Raymond GmbH & Co KG").Visible = False
.PivotItems("AB Vårgårda Kromverk").Visible = False
.PivotItems("adunox GmbH").Visible = False
.PivotItems("Advanced Power Components PLC").Visible = False
.PivotItems("Ahlsell Sverige AB").Visible = False
.PivotItems("Air Tool Matic AB").Visible = False
.PivotItems("Alpha Grainger MFG.INC:").Visible = False
.PivotItems("AMBROVIT SpA").Visible = False
.PivotItems("AMGAB EL AB").Visible = False
.PivotItems("Appelqvist AB, J H").Visible = False
.PivotItems("Avdel UK Ltd. (Avdel)").Visible = False
.PivotItems("Avdel UK Ltd. (Emhart EUR)").Visible = False
.PivotItems("AWAFAST SRL").Visible = False
.PivotItems("Aztec International S.A").Visible = False
.PivotItems("Bossard Sweden AB").Visible = False
.PivotItems("Bralo Sa").Visible = False
.PivotItems("BRD Klee A/S").Visible = False
.PivotItems("Bufab Sweden AB").Visible = False
.PivotItems("Bufab Teknik AB").Visible = False
.PivotItems("Bulten Sweden AB").Visible = False
.PivotItems("Byggtema AB").Visible = False
.PivotItems("Celo Befestigungssysteme GmbH").Visible = False
.PivotItems("CHEMOFAST Anchoring GmbH").Visible = False
End With
end sub
Exactly what you are describing. It discusses good design patterns and how to avoid general bad things like magic numbers. Most of the code he uses is pseudo code to get his point across.
Sub get_exchange_rate()
Dim XMLRequest As New MSXML2.XMLHTTP60, testopagina As String, inizio As String, fine As String, exchange_rate As Single
XMLRequest.Open "GET", "https://www.xe.com/currencyconverter/convert/?Amount=1&From=EUR&To=USD", False
XMLRequest.send
If XMLRequest.Status <> 200 Then
MsgBox "Internet connection error " & XMLRequest.Status & " - " & XMLRequest.statusText, vbExclamation
Exit Sub
End If
testopagina = XMLRequest.responseText
inizio = InStr(1, testopagina, "<p>1 USD = ")
fine = InStr(1, testopagina, " EUR</p>")
exchange_rate = Replace(Mid(testopagina, inizio + 11, fine - inizio - 11), ".", ",")
Debug.Print exchange_rate
End Sub
After this is quite easy isn't it?
I also found this.
https://stackoverflow.com/questions/1344910/get-the-content-of-a-sharepoint-folder-with-excel-vba
You can try to use that but make sure to know the difference between modules and class modules. If you confuse the two then you'll get errors.
The key to getting your solution is learning how to map to your SharePoint - that is what path you need to use to access your files.
Awesome! I love that second script, I think that will be perfect. I am attaching a fake sample of what I need accomplished. I THINK the first is a little different because i am likely going to need the instr function, not isinarray. See if the attached clarifies the goal:
https://drive.google.com/file/d/0B28HJeWfM0NARFlOOGljMTVRVU0/edit?usp=sharing
here it is. I want the cell D9 on sheet 1 to be a drop down list, that changes the value in the first column of the table on sheet one with values on sheet 2.
Did you try https://workspace.google.com/marketplace/app/macro_converter/383201976440 ? Google seems to have built a tool to make the conversion easier.
But do know that VBA is not Google Script: it's like with languages: sometimes you can translate words or sentences, but the translated text won't make sense. Intricacies like proverbs etc. need manual translation still.
See this Stack Overflow question for information about the Google Voice API:
https://stackoverflow.com/questions/1668619/is-there-a-google-voice-api
Looks like you will need to program at least the part actually interacting with Google Voice in Python. May be easiest to do the whole thing in Python.
Uploaded a quick file with three records. The first two include the issue, and the third row is a simple single line (non-issue) record. Thank you in advance for looking into this!
http://www.filedropper.com/multilinediagexample
Also thanks for teaching me about filedropper. Really useful tool.
There is a free program called PDF Split and Merge which would allow you to combine the PDFs into a single document: https://pdfsam.org/ Depending on the structure you may be able to open in Excel and extract the details.
For sure. One thing I neglected to clarify that this is not on a UserForm. Just an ActiveX Combo Box control sitting on the sheet. There's not really any other code involved for setup other than that initial line where I set the .list property to the databodyrange value in the (single-column) table. That all works great and I can choose from the dropdown.
.cmbStockCode.List = Sheets("StockCodes").ListObjects("tblStockCodes").DataBodyRange.Value
It's a pretty long list - round 6000 items, maybe that's an issue? When I set MatchRequired to true on the ComboBox, and enter an item not in that list, I can still tab-off or click away from the ComboBox without any type of error or message preventing me from leaving the control. Here is a screenshot of the settings. I did try all 3 of the MatchEntry settings, maybe there's something I'm missing in there: https://www.screencast.com/t/VCfgV6SlVUy4
Option Explicit
Private Declare Function ShellExecute _ Lib "shell32.dll" Alias "ShellExecuteA" ( _ ByVal hWnd As Long, _ ByVal Operation As String, _ ByVal Filename As String, _ Optional ByVal Parameters As String, _ Optional ByVal Directory As String, _ Optional ByVal WindowStyle As Long = vbMinimizedFocus _ ) As Long
Public Sub OpenUrl()
Dim lSuccess As Long lSuccess = ShellExecute(0, "Open", "www.google.com")
End Sub
One thing to bear in mind is that macro security settings will need to be enabled in Outlook for any code to run.
Hey, just had a chance to upload a file, here it is:
Still isn't working for me, even on a different computer.
Another interesting thing, I changed the "People" several times an noticed that old "People" were coming up after updating, until I changed the pivot table options (Number of items to retain per Field to None).
This isn't really VBA related. If you want to learn HTML and the DOM then there are loads of sites out there.
freeCodeCamp offer a interactive tutorial to teach you some basics. You can start here:
https://www.freecodecamp.org/learn/responsive-web-design/basic-html-and-html5/
An alternative to VBA: Visual Studio - pick Community Edition, probably free, but check: License
Maybe think about this from the other end - can you make date entry into the "master file" easier? Other than that, I think this is not a programming problem, it is a "boss problem". Good Luck!
Is utilizing something like Microsoft Forms a possibility for your situation? It would allow users to submit data to you to get stored in an excel spreadsheet allowing you to do what you need to do with the data once you are able to get to it.
Thank you for help. Yes it is the same project :)
Isn't it possible to add the count function into the formula somehow?
So I want to learn a specific category like colors. So I filter them and there are 15 colors.
I have the counted rows in cell A4 = 15
I would assume that you alter the function something like below.
Sub Randomnumb()
For x = 1 To
"A4"
or
For x = 1 To
count(S:S)
ThisWorkbook.Sheets("Sheet1").Cells(1, 1).Value = RandomNumber(1, x)
Next
But above gives me errors or output value = 1
https://snipboard.io/YreQz5.jpg
I'm a total newbie with this so your help is much appreciated
so, just removing the single instance of the 'Sheets("01-Core Input").Select from the code and im still getting tabs toggling. There is no other Select statements in this module. https://www.screencast.com/t/uDBduuSu
There are a lot of sites out there with free guides. All you need to do is Google them.
If you want a course from someone who is "more experienced" let's say, I would suggest you look up some courses on lynda.com or some cheaper alternatives on udemy.com (The Ultimate Excel Programmer Course - Daniel Strong for example is good for beginners).
> Are you saying you know alternative when it comes to displaying pdf?
Sure, adobe acrobat reader. And if you really want to use the browser use pdf-js.
If you really need to do this with a file stored on an SFTP server then a tool like ExpanDrive will allow you to map an SFTP server to a drive letter. It's not free though, $50 for one user.
SFTP Drive says it does the same thing and there is a free version for non-commerical use.
Hi there.
I’ve added a sheet for the macro to move the data if it’s not in row 5 and column A. Turns it into a table, then sets a filter on the author column.
I’ve added comments to the code to let you know what each part is doing and what you need to change.
https://pixeldrain.com/u/XSecudpX
Let me know how you go.
Hey :)
Just added the dummy file to pixeldrain - https://pixeldrain.com/u/E1pknJpf
I grossly underestimated the amount of employees (Authors in column D) that pulled through on the raw data but the principle is the same. I only require it to filter to a certain 7 authors/employees.
So basically, "Author" could be in D on a Monday and E on the Tuesday. The raw data pulls through the same info daily (with additional rows with info from the previous day) but it's never in the same columns which is why me recording the macro live didn't work. I did the same for the "CreatedDate" column - the macro I recorded won't work because that will change daily too.
Any info or help you can give will be greatly appreciated :)
You got what I need. I noticed this works if the questions are in cells. I'll figure this out.
Here's my document if you wanna fool around with it: https://pixeldrain.com/u/XYstXbgl
I didn't put all the answers for the other questions because I'm trying to figure this out first.
THANKS A BUNCH. I'll let you know if I managed or if I hit a wall.
Hi, not sure how to reproduce what you're describing tbh. Here's a quick file to test what I suggested and it seems to work for me.
In general though, I agree that u/sooka's advice of using a combo box is preferable to free text if there is only 2 valid options.
I don't really know what the answer is because it is difficult for me to mentally picture the issue. Here is a quick file im working with.
If you can get the issue to reproduce there then maybe I can help (but probably not tonight - I'll try to respond in the morning).
Can you show us an example of such a file?
Also, I like to use XVI32 for examining files. If you were to do so to a file you created via, say, Notepad, you will see that there are no metadata in the file itself.
When I create a file in Excel that has such cells as you describe, save it as a CSV, and use the OpenText method exactly as you do in lines 28-29, my file looks exactly as we'd like it to. Perhaps your CSV was created in such a way as OpenText can't handle it the way you'd like? Maybe just try Open instead.
Failing that, I would look at the file in a program that shows you exactly, byte by byte, what the file looks like. (I use XVI32 for that.) So if C2 contains
a
b
then in the CSV, that cell needs to be described as 22 61 0A 62 22
. I would think that if that's the case, it'd be fine.
HTH.
Take a look at using Python, Fast API and uvicorn, very simple to create web services. Python also has some really good libraries for creating/updating Excel files, openpyxl is a very popular library.
Depending on exactly what you want to see, maybe try DLL Export Viewer or Dependency Walker. But really, there's no substitute for actual support; for instance, AFAICT neither of these would suggest to you that including the Microsoft Scripting Runtime DLL as a reference allows you to use Dictionary objects in VBA. I urge you to pester the owner of the DLL(s) in question for support.
Maybe someone has a better answer for you.
I would use the network monitor to figure out what is posting and duplicate this using http requests in VBA.
In your example I would define it as a Composition relationship ("has a") because ClassA has a ClassB.
I tried using IE but I ended up extremely confused. In the end, I went in a slightly different direction. Here's what I came up with: http://collabedit.com/eduad
I used code from a few different macros that did similar things to what I'm trying to do. But, I've never done anything like this before so I'm not sure where I went wrong. The code above doesn't work.
I'm using URLs like the following: https://www.linkedin.com/company/microsoft
Do you know what I've done wrong? I'm rather lost at this point.
If you buy digital email author for code disc download.
One particular topic that increased my power is to dive deeper into ADO. The ability run SQL queries on excel files, csvs, connect to other databases and execute stored procedures there using parameters from excel. Very powerful and flexible. Here’s an excellent book on ADO that has many VBA examples:
https://www.amazon.com/ADO-ActiveX-Creating-Data-Driven-Solutions-ebook/dp/B00ZDXDTTS/ref=nodl_
Here’s a decent machine in that price range.
Amazon Renewed 4.6 out of 5 stars 4 Reviews Dell Precision M5510 15.6" Workstation Intel Core i7-6820HQ 3.6GHZ 32GB 512GB PCIe M.2 NVMe Class 50 Solid State Drive Windows 10 Professional WEBCAM (Renewed)
Save the money. Use what you have and continue to save then evaluate based on that and how your current setup works keeping notes on what hurdles you run into.
https://www.amazon.com/dp/1119514924/ref=cm_sw_r_cp_awdb_t1_TUriDb8ZQMH18
I just bought this book for the same reason, and I have found it tremendously helpful. I am reading it cover to cover. It’s like 750 pages.
Link to Amazon.co.uk. I cannot remember the edition I have (it's in the garage somewhere) but that seems to be the most recent.
http://www.cpearson.com/Excel/Topics.aspx
However if you want to have a strong foundation in programming, as in, writing clearer code, using design patterns, implementing proper algorithms, take an intro course for any language or get a well known textbook like Structure and Interpretation of Computer Programs or The Art of Computer Programming. Even if they aren't in VBA they will improve your ability to write better code in general.
For your own work, I suggest Code Complete.
As for getting your co-worker to change, don't bother wasting your time, as life is too valuable to deal with stuff like that.
Just do your own work to the best of your abilities and let that speak for you.
Not to be an arse but if you are writing anything significant I think you might gain a real lot out of having a look at even an introductory level programming book. I'd highly recoment Code Complete if you have the time...
Honestly, if you are experienced, I really don't think a book will do.
If you must though, check out Getz's "VBA Developer's Handbook." It's extremely old ( VBA 5 era ). The language hasn't changed much and this will cover some of the higher level abilities of VBA (registry manipulation, API Calls) as well as some basics, like string handling. It will not cover the different office object models (Word, Excel, Access, etc). For that consider "Using Visual Basic for Applications"
For getting a feel for Office object models, just record a macro in Excel. Then try experiment with the object model. Work on reducing the number of direct calls to the cells (ranges). Figure out how to format cells, move data, put in formulas, finding the last row, etc. You can learn a lot about VBA, just by reviewing what's there. Learn late-binding vs early binding. The IDE is robust and makes things pretty easy.
Do yourself a favor, turn on "Require Variable Declaration" in the VBA editor's options (Tools | Options). This adds "Option Explicit" to the top of all of your modules. You might want to turn off "Auto Syntax Check" in the future. Those message boxes become rather annoying after you get used to knowing what is causing your errors.
I used the 2007 edition of Power Programming VBA
It has the normal "Hello World" type of introuduction, but has a great glossary for looking up specific terms/case scenarios. It also came with a disc that included workbooks with macro code, so you can see it in action. But it looks like the 2013 edition has gone with a web based host for the documents.
I used it to get up to speed with VBA, then used it as reference, and after about 1-2 years it's now collecting dust. However, it was definitely worth it to get off the ground and I can't recommend it enough.
Select Case True
If VBAforDummies = http://www.amazon.com/Excel-VBA-Programming-Dummies-Walkenbach/dp/1118490371/ref=sr_1_1?ie=UTF8&qid=1429022801&sr=8-1&keywords=vba+for+dummies Then
MsgBox "This One."
ElseIf VBAforDummies = http://www.amazon.com/VBA-Dummies-John-Paul-Mueller/dp/0470046503/ref=sr_1_2?ie=UTF8&qid=1429022801&sr=8-2&keywords=vba+for+dummies Then
MsgBox "No, this one."
Else
MsgBox "None of the above."
End If
I personally used John Walkenbach's books on VBA to learn over 10 years ago. They were tremendously helpful and good for the intermediate to advance VBA programmer so I'd recommend his VBA books (he also writes general books on advanced Excel techniques but for purposes of this discussion, I'd opt for his books that relate to solely VBA).
Knowing SQL also helps when pulling raw data from databases for use in custom reports and models. I used this to help me out with SQL, http://www.amazon.com/Learning-SQL-Alan-Beaulieu/dp/0596520832/ref=sr_1_3?s=books&ie=UTF8&qid=1426696057&sr=1-3&keywords=SQL
Hope this helps.
For your own work, I suggest Code Complete.
As for getting your co-worker to change, don't bother wasting your time, as life is too valuable to deal with stuff like that.
Just do your own work to the best of your abilities and let that speak for you.
This is good Implementing Models of Financial Derivatives: Object Oriented Applications with VBA but maybe a little too "quantitative".
Do you have any basic programming background? If not, then you might really want to start off with Excel first. I'm a big fan of Bill Jelen, and you should definately start with this book
For Excel, I started with this book (technically, the '97' version but the same author) : http://www.amazon.com/Sams-Teach-Yourself-Excel-Programming/dp/0672315432
I used a similar book to this for Access: http://www.amazon.com/Sams-Teach-Yourself-Microsoft-Access/dp/0672321033/ref=sr_1_2?s=books&ie=UTF8&qid=1342728350&sr=1-2&keywords=access+programming+21+days
Not too long after that I started programming MS Office for a living. 15 years later, I now program .NET, SQL, and WEB for a living, all from starting with Excel VBA.
Best of luck.