+ Reply to Thread
Results 1 to 13 of 13

Widening the VBA knowledge

  1. #1
    Valued Forum Contributor ImranBhatti's Avatar
    Join Date
    03-27-2014
    Location
    Rawalpindi,Pakistan
    MS-Off Ver
    Office 365
    Posts
    1,784

    Widening the VBA knowledge

    Hi

    What other branches of knowledge would widen the programming knowledge of a VBA Developer and how.
    Like if I am an accountant ,only the accounting is not sufficient math also, statistics as well and "Business communication and report writing will make an accountant perfect.

    What other skills will make a VBA Developer perfect?


    TIA to Gurus/Experts

    Thanks

    Note:Offtopic but needed.

    Best Regards
    Imran Bhatti
    Teach me Excel VBA

  2. #2
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Widening the VBA knowledge

    Hi Imran,

    Good question. VBA is used in Excel to automate repetitive tasks. Tasks that need to be done over and over again. Tasks that can be one in Excel or Word that repeat, so you write a VBA macro to go through the steps, so you save time and effort. Excel also is wonderful for sorting and filtering data on a single sheet, but what if it repeats? What if you need to combine multiple files, like 100 of them to get your needed answer? VBA can be written but there might be an easier way.

    Excel has written a newer tool called Power Query or Get & Transform (in 2016) that uses "M Language". This extension to excel and dealing with multiple workbooks or files might be your next step beyond VBA. If you are in a company that networks and Microsoft is the standard then Power BI (Business Intelligence) would be a good extension beyond VBA. DAX is an underlying language for Power BI. Microsoft is also offering Azure as a platform for businesses that might lead you away from VBA. It seems to me, now that the world is collecting more and more data that Excel's 1 million rows limit isn't big enough. This might be a good direction to extend your VBA into.
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  3. #3
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Widening the VBA knowledge

    VBA is "Frozen in time" and forgotten language.
    A while back I replied to a thread which the OP requested to scrape data (Links) from a website. I assumed the OP wants to scape about 100 lines. Each link will lead to further links. A single link could have up to 56k links.
    Boy! The code took 56 minutes to run. I have tried all the tricks in the books to speed up the code, but these will result in few minutes saving.

    I did not know what else I could offer. I heard some other tools despite I was not familiar with them, I suggested to him to try Python. The OP then asked the same questions in "Commercial section". Although, I do not get involve in Commercial section, I was curious and keeping an eye on the thread, I think after months, the OP gave up.
    I have started playing with Python for a month now. I have run the same code in Python. It took 7 minutes and 26 seconds. I am sure an experienced Pythonist will slash another 2-3 minutes from my code.
    Looking back, What insane person runs a code for 56 minutes. What is more, while running the code, excel crashes few times plus the annoying thing- the code is not responding (Freezing). This has not happened in Python-not freezing or crashing.
    So the moral of my thread is: My initial instinct was right. If you are serious about big data, forget excel and should look at other tools, like Python.

  4. #4
    Forum Guru xlnitwit's Avatar
    Join Date
    06-27-2016
    Location
    London
    MS-Off Ver
    Windows: 2010; Mac: 16.13 (O365)
    Posts
    7,085

    Re: Widening the VBA knowledge

    In my opinion, to be a good VBA developer, you need mostly to fully understand the program(s) that you are using VBA to automate- since that is probably 90% of VBA usage. Using VBA purely as a language, as opposed to interacting with an object model, is quite rare.
    Don
    Please remember to mark your thread 'Solved' when appropriate.

  5. #5
    Valued Forum Contributor ImranBhatti's Avatar
    Join Date
    03-27-2014
    Location
    Rawalpindi,Pakistan
    MS-Off Ver
    Office 365
    Posts
    1,784

    Re: Widening the VBA knowledge

    Once I was to modify a userform code.The task was to show tooltiptext on MouseMove(it was ok for enabled controls but tough for disable ones). Anyway I had to add a specific code for as many times as the number of controls, in the said Event of all the controls. But after sometimes I learnt that there may a class module be created , the code of which can be shower upon all the controls. I realized if I were aware of this , I would have adopted this easy and robust approach at the first place.

  6. #6
    Forum Guru xlnitwit's Avatar
    Join Date
    06-27-2016
    Location
    London
    MS-Off Ver
    Windows: 2010; Mac: 16.13 (O365)
    Posts
    7,085

    Re: Widening the VBA knowledge

    I thought your question was about other branches of knowledge? That is simply VBA knowledge.

  7. #7
    Forum Expert snb's Avatar
    Join Date
    05-09-2010
    Location
    VBA
    MS-Off Ver
    Redhat
    Posts
    5,649

    Re: Widening the VBA knowledge

    Quote Originally Posted by AB33
    The code took 56 minutes to run. I have tried all the tricks in the books to speed up the code, but these will result in few minutes saving.
    I could easily draw quite another conclusion instead of blaming VBA.....

    Generalising on n=1 doesn't make a sophisticated impression.



  8. #8
    Valued Forum Contributor ImranBhatti's Avatar
    Join Date
    03-27-2014
    Location
    Rawalpindi,Pakistan
    MS-Off Ver
    Office 365
    Posts
    1,784

    Re: Widening the VBA knowledge

    Sir MarvinP

    I tried to record a macro while playing with the Power Query and saw a different code generated as compared to what we normally see in VBA scripts. So this is another other door of VBA (for me at least)

  9. #9
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Widening the VBA knowledge

    Quote Originally Posted by snb View Post
    I could easily draw quite another conclusion instead of blaming VBA.....

    Generalising on n=1 doesn't make a sophisticated impression.
    I did not blame VBA but myself for not using the right tool.
    If the right tool is a hammer, but do not have or do not know how to use it, I use a "Screw" instead. I then blame the screw for screwing up my job.

  10. #10
    Valued Forum Contributor ImranBhatti's Avatar
    Join Date
    03-27-2014
    Location
    Rawalpindi,Pakistan
    MS-Off Ver
    Office 365
    Posts
    1,784

    Re: Widening the VBA knowledge

    Quote Originally Posted by xlnitwit View Post
    I thought your question was about other branches of knowledge? That is simply VBA knowledge.
    Yes . My question is certainly about the other branches .I just mentioned about the class moduls because I did not know it. I think if a good mathematician learns VBA .He would stunn the world with his tricks in VBA due to mathematical tricks.

  11. #11
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Widening the VBA knowledge

    Hi Imran,

    A few weeks ago I read the difference between a high level and low level language. A problem was given to each set and here was the answer.

    Low Level would take 7 weeks to write the code and it would run in .01 seconds
    High Level would take 1 week to write the code and it would run in 1 second.

    In searching for a better answer I found this site, where I liked the conclusion:
    https://www.educba.com/high-level-la...vel-languages/

    On the other hand; I'm thinking I should learn to do a web site and searching myself for the "best for me" software to develope my site. I'm thinking WordPress but see there is a .com vs .org version of it. It also requires a Host (of which there are many) and FTP that I'm not very used to. Which tool should I learn??

    On the other hand, my normal work (I work for free) involves showing others how to solve their problems (for my own ego or karma, I guess ) and wonder if a WebSite is the answer. Then I look at YouTube and see lots of training videos. If the writeing and reading world is shifting to the listening and viewing world; I should be learning to make Videos instead of websites. I have done some Camtasia videos and put them on YouTube already. SOO.. what is my answer. The correct choice will be to solve more of my future problems. Perhaps the time to learn more Video creation is the answer?

  12. #12
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Widening the VBA knowledge

    Hi Marvin,
    You still need some where to host your videos. Okay, YouTube could do for you and you might get a slice of Ad revenues from Google, depending on the number of views and some other factors.
    If you have your own website, you could use YouTube as ad platform to increase the traffic on your website.
    According to lots of surveys, 25% of websites are powered by WordPress, Jumula and others. WordPress is written in PHP and PHP has over 83% of the web market.

  13. #13
    Forum Expert JapanDave's Avatar
    Join Date
    06-10-2008
    Location
    The grid, I got in!
    MS-Off Ver
    Excel 2010/13
    Posts
    1,696

    Re: Widening the VBA knowledge

    Quote Originally Posted by AB33 View Post
    I did not blame VBA but myself for not using the right tool.
    If the right tool is a hammer, but do not have or do not know how to use it, I use a "Screw" instead. I then blame the screw for screwing up my job.
    In all honesty, VBA does not stand a chance against other more widely used Web languages. With things like HTMLAgilityPack for parsing html is now the goto tool for things like that. Even with the "Microsoft HTML object library" you could spend weeks just constructing complex Regex patterns to get the data you want.

    I just made a Web scrapper to get data from Amazon that is not included in the API, not only is Amazon's html a nightmare to work with , b/c the same item can have several different urls and when I say several, there can dozens of them. But , firstly you have to get around the issue of detection as a bot from Amazon itself, that in itself is a huge challenge with them, as they are getting increasingly good at detection, especially with ML AI these days. Anyway, I can get 50,000 pages of data and retrieve the data I need in about 15 min. But to do this , I needed to use multithreading with about 200-300 threads and unfortunately even with the hacks out there to make the VBA environment seem like it is multithreading, it is impossible, b/c VBA is single threaded.

    So, even if you were able to work out the Regex to get the data you wanted and get a semi-multithreaded environment working inside VBA, it would take so long to get the data some where in the magnitude of days, maybe even weeks to get the needed data. By that time, I suspect Excel will crash anyway.
    Last edited by JapanDave; 11-15-2017 at 03:06 AM.
    Be fore warned, I regularly post drunk. So don't take offence (too much) to what I say.
    I am the real 'Napster'
    The Grid. A digital frontier. I tried to picture clusters of information as they moved through the computer. What did they look like? Ships? motorcycles? Were the circuits like freeways? I kept dreaming of a world I thought I'd never see. And then, one day...

    If you receive help please give thanks. Click the * in the bottom left hand corner.

    snb's VBA Help Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Widening the bar [in a bar chart]
    By Memphismark in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 05-31-2016, 04:03 PM
  2. # in cells and after widening it still shows #
    By dmorgan617 in forum Excel - New Users/Basics
    Replies: 8
    Last Post: 05-20-2013, 03:22 AM
  3. Widening columns on a bar graph
    By mcutcliffe in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 12-15-2012, 07:54 AM
  4. Restrict column adding and widening
    By mattsgr1 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 03-07-2007, 07:31 AM
  5. Widening the names drop-down, revisited
    By Nile_Hef in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 06-21-2006, 08:30 AM
  6. Widening Validation Box
    By Alex Mackenzie in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-21-2005, 01:05 PM
  7. Widening Names Dropdown (Bob)
    By John in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-23-2005, 03:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1