Just to add to the existing great answers here - building on the code in the accepted one, which uses a delegate void MyEventHandler(string foo)...
Because the compiler knows the delegate type of the SomethingHappened event, this:
myObj.SomethingHappened += HandleSomethingHappened;
Is totally...
@Vogel612 I'm frustrated beyond words with the darn Sage API... C# code was blowing up with a COMException without leaving a meaningful message in the API's session errors collection... So I went and kinda ported it to VBA.
@RubberDuck I see your 'over architected and under engineered distributed mess' and raise you three dozen web-services, and a VB.NET website with no code behind (all VB.NET code is in the .ASPX page).
Serious about seeing your bad web service too. I've got one that takes headers and a payload on post, and then embeds them in json as fields and a bag of raw bytes.
I literally consumed a web-service about three weeks ago that consumed an XML SOAP service with an embedded HTML document, an embedded XML document, and an embedded PDF.
And it's an async endpoint, which means I have to send a POST to it, then query it periodically over the next several minutes to see if a result generated.
Someone decided that all data needed to be written through the same endpoint. .... including the logs. So! What happens when the endpoint gets flooded?
So you have two fields: <subDoc1Type>html</subDoc1Type><subDoc1><...</subDoc1><subDoc2Type>xml</subDoc2Type><subDoc2><?xml...</subDoc2><subDoc3Type>document</subDoc3Type><subDoc3>PDFDATA</subDoc3>, where document == pdf.
One of the top devs of the company who sits next to me sent me a private Slack message and said it was sad that a senior dev didn't know that, and that he's worried about the team because a lot of them aren't that great.
@Hosch250 Sounds like an uphill battle... but one that will pay great dividends in time. I'm in that position now... my company has great engineers that can make a machine run, but programmers that understand OOP
I remember negotiating a salary. They asked me for a number. I gave them what I thought was a ludicrous number, and they said we can't pay that, we can pay you 5K less than that, and give you a 5K car allowance. I didn't know there was a car allowance, so I kind got what I asked for.
they presumably know/think you don't have anything else to go to. They'll never pay you what they really think you're worth unless they genuinely believe you might walk.
They bring breakfast in every Friday, they let me get off early on Friday once I've worked my 40 hours, they give everybody a turkey for Thanksgiving, and they give you 15 days of PTO plus sick days and travel benefits, and you get more PTO and gifts when you reach certain anniversaries.
@Hosch250 Well don't squander it. Sounds like a good opportunity, don't mess it up by doing something dumb (not that you will), but seriously, don't mess it up.
Or you'll end up like me, and work for less than you make now and slave away for months hoping for a half day off eventually, and let's face it, they just don't happen.
Let's face it, they'll come back to him at the end of the contract term and have a cordial sit-down, and say "look, we really want to keep you. How do you feel about $75,000 yearly and bonuses?"
@Hosch250 You don't, because you get more PTO than normal.
@EBrown I'd say yes to that, but you said to counter. What do I do?
I need to buy a house and car and adjust for inflation and I don't want to get squeeze out in 5 years like so many junior devs because I can't afford it anymore...
Assuming @Hosch250 works 49 weeks of the year, but then gets 3 weeks of PTO a year, then he gets paid for 52 total, which means he would multiply his hourly by 2080 (total work hours in a year), then divide by actual work hours to get his adjusted hourly rate.
@Hosch250 in many ways, you should almost take whatever they offer you. Your CV is still sparse when it comes to experience. 2-3 years from now, your CV will be great.
@RubberDuck Speaking of Columbus, I'm going to be traveling to her (female companion) grandparent's house in south-east Ohio one weekend this summer, we should meet up one day and grab a beer or something.
I think my problem is pretty simple for those with visual basic knowledge (vba); but I have searched and can not find the answer.
I am trying to create a button with (well one per row) in excel, that will auto check all check-boxes in that row. Unfortunately, I am not sure how to script it; I co...
I have the following 4 codes working perfectly on a Windows pc. The problem is, it is not working correctly when used on a Mac pc.
I have no experience coding vba on mac platform and no mac pc as well to debug the codes.
A little help converting or testing the following codes on a mac pc will b...
@Mat'sMug Agreed. With a BA under my belt my first (real job, not including factory work) was 35k. My current job (with an MFA, and coding experience) is 40k. I am essentially fighting for 60k. I would pretty much leave this job on the spot if I was offered 70k at a good company (even though I literally love my job).
And it definitely makes me wish I went for coding instead of English at times lol.
@BrandonBarney I messed up an offer to Study Maths at Oxford. I'm pretty sure if that'd worked out, there'd be an extra zero on the end of my salary right now.
That'd definitely hurt the career prospects I imagine!
I started coding the first time in High School, finished my Intro to Programming class early and my instructor wanted me to start Programming I so I could prepare for the Programming II AP test. She forgot to give me the project files, so after the end of three months just simply not understanding how to complete the problem set with what I had, I gave up. There are many times that I wonder what would have been different if I had just asked for help as soon as I couldnt solve the first task.
@RubberDuck Someone forgot to review his code again. Honest. :p
Yes, only I would recommend For Each cell In Range("B1:whatever1"). Sorry. I've not had time to properly review your code again. I will though. Honest. — RubberDuckFeb 11 '15 at 23:54
Stupid VBE question: I've got 2 classes open in their own windows then Window|Tile Horizontal so I can see them both. I need to open a 3rd class so I can see it as well. How do I get it to open that in a 3rd window without launching a debug session?