« first day (1437 days earlier)      last day (3527 days later) » 

12:00 PM
Holiday means "I decide what I code", right?
 
Hell no! I intend to not touch code at all. I probably will, but I try to limit it!
 
That strange feeling when you are 20 and you see the biggest highschool class mate weirdo on candidate list to local municipal council..
 
@gurun yep
 
I suddently feel sad.
 
@Marek sonds about right
 
12:02 PM
Hmm, ok. So I guess it then it doesn't mean "my boss won't tell me to stop unit testing because it takes too much time out of production coding" either...
 
@Marek Why would you feel sad?
Haha Unit Tests, that's so 2013.
 
@RoelvanUden what series? ^^ I'm going to Budapest for 5 days :3
 
in Lounge<C++>, 9 mins ago, by Polymorphic Potato
Can i choose to be gay because i want to have sex with men? I want to be gay so i can have sex with men and stuff. So how do ibecome gay?
What...
 
LOL
 
@RoelvanUden It is not good to know alot about candidates :D
 
12:04 PM
@Shaun Hm, a ton of them! Watched Adnaoh.Zero yesterday, started Rail Wars and will continue tonight, and then ~18 more series. I would be amazing if I remembered all the names, but pretty much everything that's ending this week (1 cour of this season, 2 cour of last season) :P
 
@RoelvanUden Is Rail Wars about trains? ^^
 
@Shaun Jup!
 
I'd like it then 8D
I started watching Hell On Wheels at the weekend on Netflix, it's gr8
 
@Shaun It's about a bunch of train-geeks that started training to work at the government-run train agency (yeah, that's not real, but who cares). They are on the security detail hehe.
 
@RoelvanUden gahaha if I ever try to get people I work with to watch anime, that's what I'll reccomend ;p
the pleasures of making software for train companies \o/
 
12:11 PM
@Shaun It's not really a beginner-level anime (obscure Japanese jokes and fanservice anyone?), but yeah, train geeks might like it nonetheless.
The best thing of this season, so far, was Aldnoah Zero for sure. I was hooked from the beginning to the end and watched non-stop ~_~
 
Is looking at anime and coding as close related as listening to Britney Spears and coding?
 
@gurun Nah. If you like one, you probably like the other. Seems to work that way as far as I've seen. Anyone serious enough about either seems to have an interest in the other (or the potential to get totally hooked on it) :-P
 
Damn, my post was too long :-(
 
Only anime/manga I've really thorougly watched is all the pokemon (still do) one piece and dbz
 
15 years ago I used Britney Spears first albums as noise reduction for 6 months non stop. I mean, I had it in my headphones as noise cancellation for he office noise.
2
I always use music that is non intrusive to my thought process, basically music I really don't listen to. Like Britney.
And now, 15 years later, I figured out that I still know every single track from that album, every line in every test, Inside out.
It is like I've been through the ultra program. My biggest fear is that someone will put on a track from that album in the office, and I'm unconsciously programmed to perform a striptease!! Please help!
(I hate ipad corrections)
 
12:27 PM
An iPad is not allowed in the C# room. We don't support it. :-P
Also, you're scary now.
 
He=the
Test=text
That striptease thing wasn't a threat. It was a promise!
But could easily be confused, I admit..
 
hi all
I have one problem while reading file from csv
"\"40224761735578\""
I'm getting like this from csv
want to get result like "40224761735578"
is there any specific datatype change or something to concern?
 
@Justcode
103
Q: Can I convert a C# string value to an escaped string literal

HallgrimIn C#, can I convert a string value to a string literal, the way I would see it in code? I would like to replace tabs, newlines, etc. with their escape sequences. If this code: Console.WriteLine(someString); produces: Hello World! I want this code: Console.WriteLine(ToLiteral(someString))...

Might help
 
Or, instead of asking that question, give us "just code" ;-)
 
badum chh
 
12:39 PM
@RoelvanUden yah nothing is there just reading file and passing it into a string but string is giving that result
@OMGtechy let me take a look O_o
 
Probably because the file has it in it? ;-)
Why not use a CSV parser instead? ^_^
 
@RoelvanUden haha nah, its getting result diff then I expect
 
You read a file into a string; the string has the file contents. What did you expect?
 
@RoelvanUden nope, actually I read the file split it then binding to list and then I check the values
 
Robot Jesus
 
12:43 PM
@OMGtechy W..w...what?
 
It needs no explanation.
 
@omgthecy, I feel the same
 
user image
2
 
@justcode can't you just add the " back on both sides of the string?
 
@gurun that's not a good idea I think
 
12:47 PM
@gurun essentially the problem is how to read a string containing escaped double quotes
 
Like this: value.Concat(v => "\"" + v + "\"")
 
Na
what if you have a string like this:
\"asdasd\"dfsdf\"wdfsdf"\
 
Yeah I know, it was a bad joke.
 
And 1,3,4,"Hello, world",5,7 as CSV... consider the horror without a parser!
 
Very bad
tumbleweed
 
12:50 PM
So, if I would take that seriously, yes I did a lot of CSV parsing. And it always turns out into a serious excersice of special cases. So in the end there are some good (and bad) libraries for doing it that I always use.
 
Exactly. We have an in-house parser to deal with all that horrible crap. Don't ever trivialize parsing a "simple data format" :-D
 
Use regex trololololol
 
But if this specific case is the only special case, then some simple replace would work, wouldn't it?
 
@gurun until people assume it works perfectly and can't understand why everything breaks later
Never underestimate human stupidity.
 
Yeah, there is nothing trivial at all about "CSV".
 
12:54 PM
Especially since there are multiple forms of CSV, because let's call ; a comma!
(I'm looking at you excel)
 
The worst is when they load the crap in Excel and thing that "it won't hurt". And you end up with data in the most mysterious formats and ####### all over the place for no good reason.
 
Too much hash.
Do you ever look at a problem, know of a wonderful and idiomatic way to solve it, and just can't be bothered?
 
We once exported telephone numbers via CSV and our users were converting it to excel. However, telephone numbers sometimes have more numbers than excel can store as a floating point precision (Because +316xxxxx surely is 3.16xxxx...) and we would end up with missing/corrupt numbers. SO MUCH FUN IN CSV AND ASSUMPTIONS!
(Now we have excel exporters :P)
 
You were storing a phone number as a floating point number?
...wha...why...even...what?
 
No. But if you put it in a CSV, then Excel "guesses" it to be floating point.
Yay for excel.
 
12:57 PM
Well fuck you Excel
 
W have a SaaS solution that receive QC data from from medical devices. Used for centralize comparison of the devices analytical performance.
The upload can be both manually (of files) but is written to be automatic.
And when something is wrong, the first things our technicians do is open the crap CSV in excel. Press save and send the file to our service. Who barfs on it.
 
@RoelvanUden or anyone else, how can I check if a variable in C# is equal to a table from Oracle?

if (ORIG_LOC == "ORIG_LOC from the db")
                {
                    cmd.CommandText = "SELECT * FROM RESERVED_SEATS";
                }
that couldn't have formatted any worse
 
Looks like the GNU style with the extra indent that sometimes comes with posting code in the chat box
At least it's not Malbolge
 
@shaun what is ORIG_LOCK?
 
@OMGtechy yah me too every time I'm importing every time its give me results unexpected
 
1:03 PM
@gurun a string that has some values in it
then there's a table in my DB that's called ORIG_LOCK as well
need to compare tehm
loc even
 
@Shaun just so I don't misunderstand. Sounds kind of simple, but could be very advanced. I'll just state the obvious first. Get the value out of the column and compare the strings?
 
@gurun Nope, I'm just a nubcake ;p what's the command to get the value from an oracle db so you can declare it as a string?
 
@Shaun but in reality if you have code like that, it sounds like you maybe should revise the strategy and do it with SQL in the first place.
 
57
Q: Sort a list and write some English!

Nathan MerrillYour boss managed to read the secret hidden message. He didn't end up firing you, though, he just made you a secretary and forbade you from writing code. But you're a programmer. You need to write code. You must code. Therefore, your code needs to look as similar to English as possible, make se...

 
1:09 PM
@gurun D;
@gurun What would be the alternative?
 
My ISP just screwed up:
"Problems accessing the My TalkTalk app
Some customers may encounter problems accessing the 'My TalkTalk' smartphone app, It has been reported that some customers are seeing..."
 
Too much talk talk and too little action action.
 
"It has been reported that some customers are seeing..."
I should call them and tell them I'm having the same problem
 
1:25 PM
@OMGtechy be sure to look up whatever industry code of practice they claim to follow and remind them of it
for all you know there's a manual workaround they're doing for customers who really complain, if there is, you want it :)
 
If pissing people off is a practice, they're experts.
 
Oracle dll doesn't have AddWithValue included, will .Add do the same thing?
 
.Add is deprecated IIRC, but I think the 'obsolete' message references 'use AddWithValue instead'
from what I recall
 
Hey all,

Weird problem.

I'm applying an update to somebody elses hacked together project and have some voodoo going on I don't understand.

There's a textbox that changes it's .text property in a usercontrol magically.

Does anybody have an idea for how to get to the bottom of how it changes? I've tried the obvious of searching for all references to the textbox with no avail. I'm a bit at a loss and am pulling my hair out >.<
 
@PaulHutchinson what framework?
 
1:30 PM
vb.net
 
Framework. Windows forms, WPF, Silverlight...?
 
Maybe it is is subscribed to some sort of oroperty change event?
 
Does this make sense? I'm getting the feeling this doesn't make sense

string origLocDB = null;
string PlanWrkOrigDepDB = null;

OracleCommand cmd2 = new OracleCommand();
cmd2.Connection = conn;
cmd2.CommandText = "SELECT * FROM RESERVED_SEATS";
cmd2.Parameters.Add(new OracleParameter(origLocDB, "ORIG_LOC"));
cmd2.Parameters.Add(new OracleParameter(PlanWrkOrigDepDB, "PLAN_WRK_ORIG_DEP"));
 
@TomW sorry, web forms app
It's doing it on load, somewhen
 
What is the type name of the text box?
Is it a standard?
 
1:33 PM
no, it's something named an nscapetextbox.. a custom control
I need that project don't I
thanks gurun, I've been staring at this for hours. I think it's sent me crazy
 
If you search, do you find any assignments of the text property in the code?
 
there are some, but it's none of them
 
What about ... jQuery stuff and similar?
 
not jquery, this is before the js libraries have loaded
it must be in this custom dll somewhere, you've given me somewhere I haven't looked.
I hate this person, no idea why it's there
just to feck with me.
 
Hehe
When it changes, does it completely replace the text or just change it somehow?
 
1:38 PM
it replaces it
they're using it as a values for a really awfully written multi selection box
which I'm trying to replace with something sensible
 
You could subscribe to the text change event (if there is one) and debug. Then see if you can back-step in the debugger.
 
that might be a great idea
 
Or, simply subscribe and change the value if the value is always a fixed string that you know.
 
I'm not sure how to backstep, I'll google - thanks.
 
(I mean, as a workaround)
"Back step" was a bad word. I mean, check the call-stack. You might be able to discover the origin of the event.
 
1:40 PM
ah yes
apparently in the Ultimate versions of Visual Studio you can use Inellitrace to go back in the execution
good to know
 
But you could also get a decompiler and simply check the code. If it is a .net component.
Jetbrains have a free one I believe.
 
I'm pretty sure I understand what's happening now. He's stored the data table and field in the textbox, and is updating it in there.
 
lol, a guy announced he was quitting last week, and this week he announced he's not anymore
 
because he's a expletive
... you can "unquit"?
 
Expletive? What the heck does that word mean?
 
1:43 PM
@PaulHutchinson apparently so
 
@gurun "wanker"
 
Haha
Fancy insults :-P
 
surprised they let him stay
 
maybe he was hoping for a pay rise
it's not a bad way of finding out how much you're actually worth to your company, tell them you're leaving for more money
 
@PaulHutchinson indeed, but I don't think that was the motivation here
 
1:50 PM
as far as you know... he's crying in the toilets now over how much you don't need him enough to offer a pay rise.
 
who abused the kick-mute while i was gone?!
 
@NETscape ?
 
> Don't kick-mute unless absolutely necessary. Seriously.
did someone kick-mute someone?
and what is pragma short for?
 
pragmatic
 
are nested DataReaders acceptable/possible?
 
1:58 PM
@NETscape No fucking clue. Does it matter?
 
In computer programming, a directive pragma (from "pragmatic") is a language construct that specifies how a compiler (or assembler or interpreter) should process its input. Directives are not part of the language proper – they are not part of the grammar, and may vary from compiler to compiler – but instead function either as an in-band form of a command-line option, specifying compiler behavior, or are processed by a preprocessor. In some cases directives specify global behavior, while in other cases they only affect a local section, such as a block of programming code. In some cases, such as...
 
@KendallFrey forget your Midol today
?
 
@NETscape you can click the timestamp and it'll give you context of the message
 
wut?
i was asking kendall if he took his menstrual meds today, his cramps seem to be getting to him
 
waahahahaha
 
2:05 PM
~shrug~
 
2:16 PM
@gurun ++ # pointing me in the right direction. Issue I've been staring at all morning now solved. Thanks!
 
@Paul great :-)
 
who the smeg sticks a data layer for a custom control in a usercontrol in an external dll. arrrg
 
Someone with not so solid experience perhaps.
Or maybe overly solid...
Really, design good controls is really different I think. Like doing good tests. Good tests doesn't always follow good coding principals like DRY, and control design doesn't always follow good layering design.
 
@PaulHutchinson you talkin WPF?
 
I maintain a good user control can be maintained without a decompiler
@NETscape a shitty web forms app
 
2:30 PM
well if the data layer exists in a different library, maybe they did it so they can easily replace the custom control with another custom control?
a custom control in a user control is confusing... or normal.
 
the data layer for one control, the rest of the app it's all in a class.. in a folder called "data"
 
Hehe we pity the people still stick in web forms, don't we :-)
 
hahahaha, best event handler ever
I found an event handler that does one thing: unsubscribes from the event.
 
what does dat even look like?
 
A mountain lion's penis
 
2:42 PM
I'm ok with penis, as long as I am the biggest lion.
 
@KendallFrey I can conceive of one plausible use case
 
You two... seriously... people are at work here.
 
One-shot event handler meant to handle an event once and then detach. IIRC you can concat (anonymous?) delegates so they run one after another
 
does anybody know if the Windows 7 Start Menu is just another ordinary Program/Application that pops up when you click the Start button?
 
@TomW But... how is that a use case?
 
2:46 PM
or is everything kinda of like... custom drawn when you click the start button?
 
Er, in that it's a case where you'd use it.
 
@TomW There needs to be a reason
 
@baeltazor It's part of explorer.exe that renders the entire task bar and start ui
 
Why would you use something useless?
 
Oh I dunno, game object representing a bomb that explodes on your next mouse click
 
2:47 PM
@RoelvanUden oh, so they custom draw it then? so it's not like it has its own process/app?
 
@TomW But that does something
That's a use case for something useful
 
@baeltazor It could very well be a full screen render with transparency for the desktop. :P I dont know the internals, but its easy to replicate
 
Yeah, so you compose the event handler. Create one that does something then concat the unsubscribe delegate onto it. That's why I mentioned concatenation
 
@RoelvanUden Would you mind telling me how you would replicate it? just briefly
 
@TomW I don't think you understand
The event handler doesn't do anything except remove itself.
 
2:50 PM
Oh crumbs, yes I see. Yeah, sounds useless.
Debugging instrument?
Placeholder?
 
@baeltazor Full screen application, border-less, transparent. Smack on a border docked fixed height component on the WPF renderer and fill it with names, states and icons of running applications with windows. Smack on a button that expands yet another component that toggles above the task bar. Hide the process view from ALT+TAB.
 
any zany IL-weaving in there that adds code to it after compilation?
 
I think it's a remnant of old code
Which is sad, because the product isn't even released yet.
 
@RoelvanUden That does sound easier than I imagined it would be. I'm not quite sure I get why a fullscreen, borderless & transparent app would be necessary though. Wouldn't a window of about 250x by 700y (for example) anchored to the bottom left of the screen do the job just as well?
 
@baeltazor Sure, that would work. I'm just used to using full screen renderering for overlays and whatnot. :P
 
2:54 PM
@RoelvanUden Ah :)
Well thanks for your advice :) I'm gonna go start planning.
 
@baeltazor Then again, full screen can enable you to render the chams :P
Like left-top flick down for running UI apps :P
@baeltazor What are you going to make? :-3
 
Started playing with WPF for the first time yesterday, I am a web dev so its all new to me. But I tried making an app with a textbox and a button, the button click should do a MessageBox.Show(textBox.text) but it looks like with WPF you have to bind the textbox text property to a variable?
I couldnt even figure out how to do it
 
@baeltazor hi, you remember :D?
 
@RoelvanUden Well I'm running Windows 8.1 atm, it's good but I miss the Start menu so... I might have a go at creating my own.
 
@baeltazor Oh haha, well have fun. Just so you know, there are plenty of start menus out there.
 
2:58 PM
Yah, I'm using Start8. I like it but I have some ideas and Start8 doesn't allow for the kind of customization I want so as usual I gotta roll my own :)
 
wonder where Sippy is
 
@VictorioBerra There's no "have to"
You can just use TextBox.Text
 
Thank you @juanvan :)
 
Classics Hell ;-)
 
@KendallFrey I gave the texbox an x:name or whatever through the properties pane, but still could not see it from the "code behind"
 
x:Name should create a field you can access in the code behind
 
@VictorioBerra did you create a new User Control or are you adding a Custom Control?
a custom control will give you a ResourceDictionary, and a Generic.xaml, and a .cs file in your project
which is probably what you don't want
 
3:28 PM
If DateTime.TryParse returns a false will it modify the DateTime out?
Not fully deciphering this:
 
Yes, that's required for an out parameter
 
Type: System.DateTime
When this method returns, contains the DateTime value equivalent to the date and time contained in s, if the conversion succeeded, or MinValue if the conversion failed. The conversion fails if the s parameter is null, is an empty string (""), or does not contain a valid string representation of a date and time. This parameter is passed uninitialized.
 
Basically, if TryParse returns false, don't use the out value
 
@KendallFrey Okay, so if it is false it doesn't touch the out.
 
Yes, that's how out works
 
3:30 PM
@KendallFrey Just wanted to clarify, thank you.
@KendallFrey The MSDN's description kind of was like... "what?"
 
Although variables passed as out arguments do not have to be initialized before being passed, the called method is required to assign a value before the method returns.
it might not "change" it from the DateTime you passed it though
 
> is required to assign a value before the method returns
it will
pinky swear
 
hence why I quoted change
DateTime temp = passedDateTime;
// failed to parse passedDateTime
passedDateTime = temp;
 
you're thinking of that inside the method?
 
different value, but not a different time
 
3:34 PM
no go
you can't pass a value to an out param
 
DateTime is a struct
 
Yes, yes it is.
 
i'm talking inside tryparse
 
Yeah, not gonna work
 
no?
 
3:37 PM
2 mins ago, by Kendall Frey
you can't pass a value to an out param
 
that's interesting
at least with value types
 
Note that doesn't mean you can't pass an initialized variable.
 
right
 
When I add a OnHolding event to the textblock, the text foreground color changes to white, but without the event, it remains black.
I have perhaps the most weird problem ever.
What the heck!
 
3:59 PM
Hi guys, I've got a zip file on server to which this asp.net web api application has rights to access the file. How can I send link to the browser so that I can use this link to create anchor element in UI? So, when this link is clicked, browser can download zip file. Or any better way to do this?
 
4:17 PM
Nope :)
 
I wish I did that...
 
I saw the same headline this morning and thought the same thing
 
But knowing the state of technology with the government in Sweden, it probably would have wrecked havoc with line like this:
10 GOTO LINE 10
(@me leaving the stage for plenty of old peek and poke jokes)
 
@ton.yeung Sorry I couldn't talk yesterday, tonight Fed Ex?
@ton.yeung Okay, I'm off about four-four thirty.
 
:)
I really want somebody to come in here and start screaming racial slurs so i can test out the kick-mute functionality, a few dozen times.
 
4:31 PM
@ton.yeung No.
Does this seem like an optimal solution?

                    connection.Open();
                    command.Parameters.Add("@Invoice", SqlDbType.NVarChar, 500).Value = invoice;
                    id = command.ExecuteScalar() as int?;
                    if (id != null)
                        DownloadPDF(Convert.ToInt32(id));
@ton.yeung I'll be available, just call.
@ton.yeung We shall try and take care of this tonight.
 
hello hello, I'm back
 
@Greg what if id is null?
 
@ton.yeung New Zealand for 2 weeks
 
why does outlook search suck so bad
 
haha, no box jellies in NZ
 
4:39 PM
@NETscape Returns a blank page with a simple Response.Write.
 
it was cool. I liked the mountain biking the best
 
SFW?
 
@Greg you shouldn't have to use Convert if the cast was successful
 
what do you think @Steve ? lol
 
@NETscape The method only takes a int not a int?.
 
4:41 PM
lol, wishful thinking :(
 
@NETscape Is that the best way to return a message to the user that it failed?
Otherwise it just downloads the file?
@NETscape Or should I use the RegisterStartupScript.
 
@Greg
connection.Open();
command.Parameters.Add("@Invoice", SqlDbType.NVarChar, 500).Value = invoice;
id = command.ExecuteScalar() as int?;
if (id.HasValue)
    DownloadPDF(id.Value);
 
@NETscape Oh, I didn't know that. Nifty, now I know for future.
 
you can also do something like
DownloadPDF( id ?? -1);
if your method handled invalid id's
getting rid of the if statement in its entirety
 
@NETscape I can't, user input :(
 
4:50 PM
@Greg what i'm saying is you could do it that way if DownloadPDF looked like:
private void DownloadPDF(int index)
{
    if(index < 0) { return; }

    //Operate as normal
}
 
It's sad that a video game has a better "mark-as-read" algorithm than MS Outlook.
relevant-ish
 
@NETscape Food for thought.
 
@NETscape why not just take a uint
 

« first day (1437 days earlier)      last day (3527 days later) »