« first day (1752 days earlier)      last day (3186 days later) » 

3:02 PM
@ton.yeung yeah - thanks :D
@ton.yeung not at all :D
neither have a "combine" functionality. See the fiddle.
UriBuilder mainly concerns it's self with the protocol/domain/host. Uri constructors are poor at combining URIs as paths
the 2nd parameter in new Uri(baseUri, resource); replaces the resource at the end of the baseUri rather than appending it as an additional path part.
e.g. http://example.com/FOO plus "BAR"
becomes http://example.com/BAR
instead of http://example.com/FOO/BAR
which is technically correct when you talk about relative navigation, but not right when you're trying to build a URI path.
I'm creating a Uri.Combine() extension method
 
public static string Combine(string basePath, string relativePath)
{
    var segments = new List<string>();
    segments.AddRange(basePath.Split('/'));
    segments.AddRange(relativePath).Split('/'));
    return string.Join("/", segments);
}
try that
 
that's pretty much what I have written here :)
 
should probably mention that this allows characters that are forbidden in path segments
and also that it contains a syntax error
and that it doesn't normalize dot segments
I'm starting to see why MS couldn't be bothered with Uri.Combine() :D
 
heh
 
I deleted a lot of obsolete code today
feels good
 
3:18 PM
doesn't it?
During the Great Refactor, March-April 2015 I think i reduced the code base by about 10000 LOC.
glad we don't get paid by LOC metrics. I'd end up owing the company money.
 
LOC is a pretty useless metric :/
 
Just got my first aneurysm of the project!
Something so utterly stupid I couldn't help but almost die.
 
let me guess
a property setter that recursively sets itself instead of a field with the same name in lowercase
causing your background service to freeze with no logs being generated ever
hot or cold?
 
Cold
 
Does anyone have a oneplus2 invite they can send me?
 
3:34 PM
"I want to re-use this in a few places, but I don't want to make class/interface changes that affect other functionality, because I'm lazy. Better just copy and paste."
"Wow, look at this guy's LOC count!"
 
IsBrowserTypeInternetExplorerAndLessThanVersion9()
 
@Sippy what's wrong with that? It's descriptive!
 
Gonna replace the contents of that with Response.Write('fuck off dinosaur');
@Squiggle Hyperverbosity induced nasal bleeding.
 
Response.Redirect("http://rebecca.blackfriday");
 
@Sippy throw new YesBrowserTypeIsInternetExplorerAndLessThanVersion9Exception()
 
3:38 PM
lol
It used to be good practice to render HTML from the back end didn't it
With Web forms
Think this code is from 2009
 
^^ yes
 
No. Never good practice, but often done.
:P
 
Ah.
Then my predecessors were morons.
 
define "back end"
 
Code behind
From database I know is still done
By idiots.
 
3:39 PM
oh, then yeah.
 
!!google dicss github
 
have a few web forms with code behind at the top
 
hurr durr I store my markup in SQL server
 
I've maintained stored procedures that constructed Javascript. That was painful.
 
@CapricaSix DID YOU HEAR ME
 
3:40 PM
Lol
 
@Jeremy she is dead
 
@juanvan why?
 
relmon has her down
 
@juanvan cap6 is a strong woman that don't need no man
 
someone has to press her button
 
3:42 PM
@rlemon has decided she needs a holiday apparently :D
 
@Sippy (and @Squiggle) stop it you're giving me flashbacks
 
caprica!!
 
@Jeremy I'm looking at this shit right now lol
Hopefully when I'm done I can delete a shitload of redundant crap.
But first I must understand what the fuck the developer was trying to achieve.
So far he has achieved complete unmaintainability
 
But First... shitty code a-hoye
 
@Jeremy one time I saw code that parsed a 150KB XML document using hard-coded element indexes. In Javascript.
 
3:46 PM
Web app code behind
From database is still done
Always by idiots
 
@Squiggle EUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUGGGGGGGGGGGGGGHHHHHHHHHHHHHHHHHH‌​HHHHHHHHHHHHHHHHHH
 
Now is haiku
 
only it wasn't an XML document. It was XML loaded INTO the html DOM, hidden with CSS.
 
@Squiggle stop
I'm gonna have another aneurysm
 
@Squiggle "creative solutions"
 
3:46 PM
srsly. The developer claimed it was "RESPONSIVE AJAX!" and christened the technology "XML islands"
 
Creative solutions to problems that we shouldn't have.
@Squiggle What a thought-leader
 
 
@Jeremy you made me roffle at work :-/
love that gif
 
You guys are making me ill.
But xml islands sounds interesting
Did he develop that into something I can read nothing about?
 
@Sippy no. We made sure it didn't escape into the wild.
then the product was mothballed for being unmaintainable
 
3:49 PM
"Now, users don't need to query the database, which is expensive and wastes time. We just load our entire data structure into the DOM and hey presto - instantly responsive AJAX!"
Something like that?
 
yarp
 
I did work under a lead dev who advocated 2000+ LOC in windows form classes.
 
Don't you wish it was legal to uppercut people with a sledgehammer for specific reasons which include moronic ideas?
 
'Because then you know where it is'
 
hurls
 
3:52 PM
@TomW "20000-line classes, because then you know where it is"
 
MiscUtils.QueryStringifyLastComponentOfLwItemPath(lwi, RelatedItemLink, section, "child", VideoMediaTypes);
I have no idea what that means.
vOvOvOvOvOv
 
is there a x version?
 
@Sippy QueryStringify
Wow, violate SRP much?
 
I worked on software that had a switch statement so long it had to be split across three different files, because VB6 had a 4000~ line limit to methods.
 
@Griffin, do you still need the invite? I can ask a friend
 
3:57 PM
@KalaJ I will but give me 2 hours. I am heading home for the second half of the day and want to get the smell of urine off of me.
 
okay sure
 
@juanvan sorry for the delay >_< why won't it work?
 
want to post the code you have, can compare it to the example used
 
yes
lol
trying to get to another partial view but on submit, the partial view reloads and the same is the page!! Recursion!
*page is the same
 
4:09 PM
@juanvan this is basically what I have
 
FatMan<Catz
 
Cats are always better.
 
@PaulinaD. do you have the [DllImport("myDell.dll")] in the c# code?
Lunch();
 
4:24 PM
The one thing that pisses me off more than anything
Is repetitive type checking
 
33
A: What is the median reputation level on Stack Overflow?

reneIt is 1 based on this SEDE query -- http://stackoverflow.com/a/7227860/578411 select avg(reputation) median from (select reputation, rnasc = row_number() over(order by reputation), rndesc = row_number() over(order by reputation desc) from [users] ) b where rnasc between rndesc - 1 and rndesc ...

 
It's bad enough we have switch(item.type) and then 200 cases for each type
 
repetitive type checking is a code smell
 
string M4aPath = item.TypeName == "MP4 Audio Clip" ? item.Path : string.Empty;
 
I have a question about structs in C# vs C
 
4:26 PM
The code has already checked for this type.
 
Twice.
And now there's ternary just to make sure.
 
In C, if I have a struct when it is initalized then its size of only the size of the largest datatype in it correct?
 
@juanvan Noup, because I'm not using a DLL. It's a project in C++ thaaat eventually calls functions from a LIB.
 
Is this the same case in C# or does a struct create enough memory for all data in it? What if I have a List<> in the struct?
 
4:29 PM
 
4:41 PM
today I was told to add an #ifdef to C# code. My Life Is Average.
 
@Pheonixblade9 I've seen it in WPF code that constantly needs to switch between desktop WPF and silverlight stuff
 
its common in xamaran code too
 
@Jeremy in this case, it's because the servers are in a different timezone than our local instances. So he said to add #ifdef debugging --offset datetime by 3 hours
 
@Pheonixblade9 o.o
Who told you to do that
Can you ignore their advice
 
why not just test in local time?
 
4:44 PM
the servers are in EST, we're in PDT
with the wonderful way EF works, you are forced to set a value for a column, you can't rely on the DB default
so the app server (my computer) sets DateTime.Now which is 3 hours earlier than what the DB server thinks it is. The app server then pulls the data and says WHOA, THIS IS IN THE FUTURE, THIS DATA IS BAD and throws an exception
 
@KDecker what you're describing in c sounds like a union type. Are all structs like that?
I'm pretty sure that's not the case in c#
I'd have to check though
 
@Jeremy the person that told me to do it is the other dev on the project
 
Huh.
 
@Pheonixblade9 hmm, I guess that makes sense. What other options do you have?
 
Just realised 3 people have been sending me emails, urgently trying to recruit staff for DCSL in Farnborough for about 6 months.
I've been deleting them as I got them
 
4:50 PM
@KyleTrauberman I'm planning on ignoring the problem until it goes away
 
the money is good, so I'm wondering a) how stringent their recruitment process is and b) how shitty it must be to work there that they can't get staff
 
always a valid option.
 
@Sippy nobody can get staff. Everybody is hiring. There are N SDEs and N+50000 jobs
 
@Sippy how much? I've never heard of them btw
Farnborough is rather erm...uninteresting
 
Lol
 
4:55 PM
He says, taking a job in Basingstoke
 
Either they're hiring hundreds of devs, hiring no devs, or people keep leaving.
Lol
I work in Swindon vOv
Not much going on here.
 
I mistakenly ended up in Swindon on Saturday
 
@KyleTrauberman @Pheonixblade9 DateTimeOffset? Store everything in UTC time?
 
A_V
Hi, I'm doing a C# MVC web application and I'm trying to integrate a file uploading feature. Can someone tell me about a good plugin to integrate ?
 
(.UTCnow?)
 
4:56 PM
@TomW Big mistake!
Don't you live near Oxford?
You're commuting to Basingstoke?
 
Got on the wrong train, sailed straight through my intended destination at high speed
 
@A_V dropzone is pretty nice for that.
 
@Jeremy I just made that suggestion and he said "please do not change the DateTime format. Using the #ifdef is a minimal change that will only affect the service when we debug"
 
@Sippy hopefully not often. Few times a week, wfh the rest
 
@TomW Ahaha that feeling tho
 
A_V
4:57 PM
@Sippy Does that use jquery ?
 
@A_V No
 
A_V
I'll just go and look wait a minute
 
@Pheonixblade9 We have some crufty code that stores stuff in local time. We made a push a while ago (before I came) to add timezones to all that stuff - keeps it minimally invasive.
 
Still stuck in the office doing a deployment. All my friends are at the pub.
FML.
 
5:02 PM
@Squiggle :D
sad lyf
 
@Sippy so yeah, it would be a sod of a commute. About an hour in favourable traffic. They pay well though. I've made it clear my preference is wfh
 
@Griffin, just thought of a cheap tech gift. Get a Cardboard!
Has anyone here given a talk at a conference or small tech event?
 
5:20 PM
@TomW Sweet
I wanna swap jobs again lol
This one is starting to grind on me already, 2 months of web forms is enough.
Could probably get 30k out of moving ..
 
Maybe not quite as well as I thought
oh yeah, contractor hey?
Capita will want a replacement for me soon enough. They don't seem to mind spending ludicrous sums on contractors. It's not a bad project to work on but...it's getting samey, and I can earn a lot more by moving
 
"samey"
what a word for my life
 
@PaulinaD. think the DLL is the only way to call unsecure code, like that example shows. a c#/C++ are not in the same project, same solution.
 
@TomW I dunno how Capita have so much money
We charge them almost as much as they cost in fees because they fuck everything up.
Didn't realise you work for Capita, that makes you the enemy
I stab u now.
@TomW Also, only slightly, I'm bouncing between two cooperating companies on fixed term contracts and so far they are just paying me more and more.
vOv
If I stayed here my whole life I could do well haha
I'd rather live past 40 though :/
 
@Sippy I'm sure we've mentioned that before, n/m
Yeah, I do, not for much longer though
 
5:35 PM
:D
I might have complained about Capita before, but didn't know you worked for em
The people are lovely to be fair.
I have one person that I strongly dislike, but it's mostly the processes lol
"Can I have access to this database so I can take a copy of it for development work please?"
"No."
"Okay, can you send me the web.config for the web application that runs on it?"
"Sure!"
 
posted on August 03, 2015 by Visual Studio Blog

Recently, Visual Studio 2015 was released with support for Python. Python Tools for Visual Studio (PTVS) are available to help throughout Visual Studio in all the places you’d expect, from editing and IntelliSense, to debugging, profiling, and publishing to Azure. You can find all the details and some video walkthroughs, documentation, and other resources on visualstudio.com, and the post

 
@Feeds Actually, I should try this.
 
Hello, can someone please help me?
http://stackoverflow.com/questions/31790302/how-to-apply-google-material-design-to-asp-net-controls-i-e-checkbox-button-a
 
YUUUUUUUUUUUUUS
I added my own bullshit to this class and switched the methods out and it didn't break anything
fuk yeeeee
So now I have one method, shorter than the others, which can replace them all.
rip.
 
@Sippy wow such code ninja
 
5:49 PM
I thought this would take days
I still don't know how the rest of it works but I don't care.
vOv
On that note it's time for beer.
o/
 
o/
ya git
 
6:03 PM
@KevinMaxwell does it matter that in your HTML example the input is nested within the label but it is not nested in the ASP.NET example? What you're doing should work as long as the elements rendered by the asp controls are the same as the HTML ones. You can use the DOM Explorer in your browser's console to see what is being generated.
 
@TomW - Just got your ping. When you got in, were you aiming for the day high? :P The markets got absolutely stomped today so it was probably not the best time to get in. Always have a look at futures and other markets when you buy for future notice. That said, your position only looks like it is down 0.3% which doesn't seem terrible. I think the stock still has upward momentum, give it some time.
@TomW - The overall market will play a roll, here are some US upcoming metrics to consider: marketwatch.com/economy-politics/calendars/economic
 
6:18 PM
@TravisJ you bastard, you've ruined me! I'm finished! Finished!
:P
 
0.3%!
It is at 1538.01
 
it's been dithering around all day; I should have got in when you first mentioned it but IT issues...
I'm kidding; not worried and still optimistic that it'll pick up.
As I've mentioned I consider this gambling, basically
 
@TomW - It will work out. Today was a bad day for the whole market and the stock still managed to hit a new high.
@TomW - If the dow can close at 17550 today you will see a bump when your stock opens tomorrow morning.
 
Aaaand home time.
 
I'm trying to clean up my xaml from using Margin everywhere to using a Grid with Panels. I have 2 columns in my grid, both of which take up half of the available space (great!). I have a ComboBox in both columns, but it only takes up the space it needs, and doesn't stretch to the whole width of my column (not so great :(). What am I doing wrong with this xaml? gist.github.com/anonymous/3b2cc4fa76f9dff93806
 
6:30 PM
@TomW - "A report on US factory orders will be in the spotlight on Tuesday [(tomorrow)], with analysts predicting an improvement in June". From the market indicators the reading should be +2.0% from a previous -1.0%. If that happens, tomorrow should be at least flat, hopefully better. It doesn't come out until 10am EST though. Hm, that might be after your hours close though :(
 
@KevinMaxwell CssClass vs Class elements on the page?
 
@juanvan ?
 
CssClass="c-white normal f-11 m-b-15"
should be class
 
@juanvan ASP.NET control runs by CssClass
 
humm never took notice
 
6:37 PM
@BenjaminDiele Hm. Well, at the least, it's a WrapPanel problem.
 
I actually changed to class, but nothing happened.
 
@Jeremy yeah, got rid of the WrapPanel (because only 1 child yeah)
 
@TravisJ tx. I'm sure it'll all work out in the end
 
and it worked. But what do I do when I have multiple children that I want to space out? Would a wrap panel work then?
 
@BenjaminDiele Well, you can set the minwidth of the combobox
 
6:41 PM
@CuddleBunny I can't see anything. Maybe I'm looking at the wrong section!
 
@BenjaminDiele And, if it contains any items, the combobox will try to expand to its necessary width
(dunno, that might be the right behavior)
 
@juanvan That's why I'm linking 2 projects, then i have this object in C++ being called from my C# one. So far, it has worked. The only roadblock I have is that 'out' modifier which I don't know why is coming up
 
@TomW - 17511, we may close near 17550
40 minutes left in the day
(no after hours for large indexes)
 
@TravisJ google is giving me 17,535.99
 
My socket timed out :P
Everything looks in order for tomorrow, barring something strange from China or something unfortunate out of Greece.
 
6:46 PM
I have 5x leverage on $50
my miniscule trades are the reason that 'normal' brokers aren't ideal for me
 
@TravisJ I'm still waiting for Shanghai's bottom, then I might get in for a little while
 
haha :) Well at least you are getting to learn a little. But also the risk of 'normal' brokers makes you be more precise
 
@PaulinaD. linking 2 projects links the dll to the one calling the other - or I totally do not understand how 2 projects in one solution works
 
@Jeremy - Keep waiting, that place is a time bomb. Just wait until they lift the freeze on large shareholder selling.
 
@TravisJ Yeah. I'm in no hurry - sitting on mostly S&P with some PRHSX - not the right time to sell either of those, anyway.
 
6:51 PM
@Jeremy and have you considered what Shanghai thinks of you telling people that? Show her some respect :P
@TravisJ aaah the motherfucker is backsliding
come on, you can make 17550
 
@TomW - Yup, definitely lost a little steam there
 
@juanvan Nop, there's a LIB I'm accessing through a RuntimeComponent project (in C++) and then, the C# one calls access methods in that RuntimeComponent project
 
@TomW - It actually has an hour and six minutes left. So it definitely has time to get there if there is enough strength in the market.
 
@KevinMaxwell what is the code you are using? found a nuget but those are there own controls.
 
@TomW - Especially if people consider how potentially awesome the factory orders number will be tomorrow.
 
6:55 PM
@juanvan I'm using ASP.NET Web Forms (C#) - .NET Framework 4.6
 
@PaulinaD. I never seen that
Yes @KevinMaxwell but a stylesheet? can find one
unless you really need 4.6 use 4.5
 
@juanvan is there any problem with 4.6?
 
check the stars to the right
 
I always avoid bleeding edge for that type of reason
 
@juanvan Lol it's like calling native code from Java but now, it's from C#
 
6:58 PM
never did that - always from a dll and ref the dll in the code
 
A_V
@Sippy Thanks a lot dropzone.js is awesome great idea
 
out is a c# term , adding it to a c++ function won't work
 
@juanvan it's good to see that. You think that's the problem?
 

« first day (1752 days earlier)      last day (3186 days later) »