« first day (2045 days earlier)      last day (2886 days later) » 
00:00 - 19:0019:00 - 23:00

12:26 AM
Hey Guys, why I saw @ before a string variable sometime?
Like that:
oMailItem.Attachments.Add(@billede1[i], Microsoft.Office.Interop.Outlook.OlAttachmentType.olByValue, body.Length, Type.Missing); // for billede1
or:
string banner = string.Format(@"cid:{0}", contentID); // for "cid:{0}"
 
12:51 AM
@Jean-philippeEmond The @ makes a string literal a "verbatim string literal", which allows things like backslashes and newlines without escaping msdn.microsoft.com/en-us/library/362314fe.aspx
In variable names, it lets you use reserved keywords. stackoverflow.com/a/429534/251011
In your examples, the @s are superfluous since billede1 isn't a keyword and "cid:{0}" doesn't need any escaping.
 
user47589
2:17 AM
are you bored
 
@Amy not since i have a rift :)
 
 
2 hours later…
user6096770
4:34 AM
sup fam
 
6:30 AM
morning familia
 
Brothers and sisters of mine, when are we going to dine?
 
in hell?
 
In hell I want to dine not for last time there was too hot.
 
6:51 AM
I hate dining in hell. The parking is awful and the service is slow.
 
sounds like hell
(sounds like 206 :^))
 
Morning everyone!
Man it was a quick fight last night (if anyone watched the meek vs palharis matchup)
 
What a terrible name for a boxer
 
@misha130 Haven't eaten there in years. :)
@JanDvorak Still, inheriting the earth can make up for it.
 
God couldn't care less for how you call yourself.
 
6:56 AM
What are you on about?
 
Which of us?
 
about the irish I guess?
 
Jan.
@misha130: Irish?
 
Today's topic: Confuse the hell out of @scheien.
 
Irish? I love irish music.
 
6:57 AM
mission accomplished
 
^ indeed
 
#embraceChaos #cthuluFTW
 
room topic changed to C#: A Safe Space for Panini | Home of JicamaJS! Confused? Good! | csharpchat.com | gist.github.com - For Easy Code Pasting [.net] [asp.net] [asp.net-mvc] [c#] [coreclr] [entity-framework] [java-hate] [jicama] [linq] [panini] [visual-studio] [wcf] [wpf]
 
#alllowercasehashtagsjusttobeannoyingtoread
 
#needmorehashtags
anyway
 
6:59 AM
@JanDvorak I had a "Cthulhu for President - Why Settle For The Lesser Evil?" bumper sticker, way way back.
 
Wait, there was chat drama over the weekend again?
 
#again #questionmark
#isuckathashtags
 
There was some drama a few months ago, I forget exactly.
 
This drama went over the top
 
7:02 AM
The hell froze over, if you are willing to call this place hell.
 
I wasn't here either but they complained about profanity
 
Right, then. I'll now pointedly avoid reading the transcript and pretend it never went down.
 
well meh, no one cares mate really
 
@AvnerShahar-Kashtan it even has a meta post related.
 
Where? Meta.SE or Meta.SO?
 
7:06 AM
meta.se now, migrated from meta.so
 
just load up a lil bit you'll see it
 
yeah, it's linked earlier, not too far up
 
The question's had -47 votes when I voted on it
 
wow.
 
7:08 AM
Are we that bad/vulgar/inappropriate?
 
Well, C++ is worse, but mods know better than touch that filth
 
its an hour ban, its not the nazi regime
mike got over it 50 times by now probably
 
@scheien We get there occasionally. Then people cool down and it's back to business. *shrug*.
 
JS has its hours as well, but they're outside mods' hours.
Maybe C++ has a pass because they actually moderate their tag on main?
 
All in all, the JS room feels a lot more hostile, even if not vulgar.
 
7:11 AM
Even if you ignore the black friday thing?
... and mr. "I'd rather have you out than change my avatar"
... and that not once but twice there was an exile of people forming spin-off rooms over a dispute of room politics
 
What black friday thing?
 
@AvnerShahar-Kashtan Can't say it is that bad. Might be a culture / internet experience thing though.
 
And yes, there is unwarranted hostility here occasionally (which is different than vulgarity, which this incident is about). But the JS room, when I hung out in there, felt always hostile.
 
This rebecca black thing: youtube.com/watch?v=kfVsfOSbJY0
You have been warned
 
oh, that's frequently spammed here as well
 
7:14 AM
the spin off rooms are a part of all communities
 
@JanDvorak Yes, I'm familiar with that variation of rickrolling. I have have a script that marks it automatically. :)
I think rickrolling is silly and occasionally annoying, but not really hostile.
 
noted
 
Rickrolling was much fun, mostly because the window popped around and one couldn't close it easily.
 
@scheien Different internet places have different standards. Over in RPG.SE there were several incidents over the years where people who were used to the (frankly, toxic) standards of many RPG forums got into conflicts with the much stricter "Be nice" policy on RPG.SE.
 
yep, you're right
I went to the c# game room the other day, and then there was a guy (from rpg.se) that totally went for the "be nice" policy.
 
7:17 AM
in C# Chat Gaming on The Stack Exchange Network Chat, yesterday, by SevenSidedDie
Public Service Announcement: RPG.se takes the Be Nice policy seriously. While guests of RPG.se, adhere to it in chat as if you were on the main site. Thanks!
 
I, personally, prefer RPG.SE's standards. And I also have no problem with SE's vulgarity policy.
I have no problem with vulgarity. I'll use it with my friends. But I won't use it at work or at the doctor's office, because context matters. And I have no problem with SE chat being one of those vulgarity-light contexts.
 
I dont mind either. I have a thick skin after a couple of decades on the net.
 
I'm just wondering how Lounge managed to stay alive until now
 
@scheien Yeah, SSD's been involved in a lot of the frictions we had in the past.
 
SSD's?
 
7:21 AM
@scheien Oh, I thought you were the one who posted the RPG.SE link, not @misha130. SevenSidedDie, the guy who posted that.
 
The nice thing about the Internet is that you can always walk away. Except, well, when duty calls.
 
And also BESW, who's the RPG.SE chat room owner.
And takes the Be Nice policy very seriously indeed.
 
@JanDvorak hehehe, I love that xkcd
yeah, they were pretty clear about that.
I'm out. Going to play with some Lego. Requested by my minions.
Star wars vs friends, epic battle incoming.
 
The force awakens?
SWVIII: The force stretches and yawns
 
@JanDvorak SWIX: The force goes to the bathroom and then back to bed.
SWX: The Force Finally Turns Off The Snooze Alarm and Gets Up, Grumbling, to Make Itself Coffee.
 
7:31 AM
How to turn an epic trilogy of trilogies into something worse than a soap opera.
 
Now, is this a morning for black coffee, or do we put milk in it? Light side or Dark?
 
Have a split cup and sip both halves at once
 
blasphemy
 
Au contraire. I totally want a yin-yang cup. Totally willing to model it and pay for the 3d-print.
Though, given the current costs of 3d-printing, it would probably have to be a teacup
or a shot cup
 
@JanDvorak Like those irish cream bottles that pour two liquids out at once?
 
7:37 AM
!!google those irish cream bottles that pour two liquids out at once
 
Let's see how Cap deals with it before I post the answer.
 
She won't
 
Sheridan's is a liqueur first introduced in 1994. It is produced in Dublin by Thomas Sheridan & Sons. The idea was originally conceived in the 1980s by Pat Rigby (director of Research and Development for Bailey), to add another product to the single branded company. Production started in 1989 and the new facilities were built for the production at the cost of 2 million (As of 1996). The company was not able to find an Irish company who could make the glass bottles, so the original bottles were made in Italy. Currently, bottles are made in France and England. It is uniquely bottled, consisting of...
 
I mean, something with an open surface, that forms a proper yin-yang pattern (complete with circles) when both halves are filled
Fancy a render once I'm done designing it?
 
@JanDvorak Yeah, I got it, but this is the closest actually existing thing that came to mind. :)
 
 
3 hours later…
10:42 AM
@JanDvorak aye
 
11:23 AM
Morning
 
Morning
 
Today is a day for coffee and gaming like it's 1995 on a Windows 98 VM
Or maybe gaming like it's 1998.
What OS was Droidworks released for?
Ah, 98.
I'd love to be 5 again.
 
@MikeAsdf, thanks for the explaination :-)
 
Thats weierd ...Im currently trying to add lan multiplayer to my game. The host puts all the entitys into a list. This list is sended to the server. When a new player joins the server sends the list to the client which connects. Then i update the entitys position every 60 ms. The problem is, that the non host client render some entitys double O.o These one which are rendered double dont move ... Does anyone know why this happens ?
 
Without seeing your code how is anyone supposed to know what's causing that bug
!!sscce
 
11:31 AM
@Sippy Please provide a short, self contained, compilable example: sscce.org
 
11:49 AM
I think i found the error now ... Used the Hasmap wrong :/
 
In my backgroundWorker_DoWork, the thread exits with code 0 after Thread.Sleep(10000), what's up with that? I want background worker to run forever, constantly doing something every 10 seconds
 
That's not how you do that.
66
Q: Why is Thread.Sleep so harmful

BurimiI often see it mentioned that Thread.Sleep(); should not be used, but I can't understand why this is so. If Thread.Sleep(); can cause trouble, are there any alternative solutions with the same result that would be safe? eg. while(true) { doSomework(); i++; Thread.Sleep(5000); } an...

 
12:08 PM
@Sippy Say, where's all the C# Slack channels at?
 
You want an invite?
 
@Sippy Yup.
 
One sec
Send an email to coctothorpecastle@gmail.com with 'slack' or something as the subject and I'll add you :)
 
Done.
@Amivit I'd recommend using Timers for that. A timer will sleep, not using up any resources, until its interval elapses. Then it will grab a free Threadpool thread, do its thing and shut down again.
 
@AvnerShahar-Kashtan Invite sent :)
 
12:13 PM
Alright thanks, I'll try reading up about timers @AvnerShahar-Kashtan, and thanks for the links @Sippy
 
You're welcome
 
12:52 PM
hi
any one present?
 
Present
 
hie @betarunex
 
@arun hey there
 
i am developing windows universal apps i have problem in it
can you help
 
depends on what kind of problem and my abilities
 
12:58 PM
@betarunex ok! i need to access a html file from appdata folder of app.It has a index file which send xmlhttp request for a pdf I am not able download pdf
@betarunex i need how to enable xmlhttp request for file urls/cross origin request
 
@arun sorry. I haven't gotten to that stage yet
 
@betarunex ok nop thank you
 
 
2 hours later…
3:14 PM
Hello all
How can I set the display to center the header table in the project ASP.Net MVC?
I tried this:
<th style="text-align:left">
but it's not working
 
could you put it in a table <td> to center it?
 
Oh, sorry, it works - I'm just not there looked
hmm, can I specify multiple headers for the table?
here is set one header for row and one for column:
But I want to add one more... "Week" for columns and "Time" for rows
 
3:52 PM
let me show the screenshot what I mean:
I want to display "i" in the center row
 
4:12 PM
Hello Friends
 
hello
 
@FoggyFinder when you say I in the center row you want it in the 2 row in all Columns?
 
yes
I think it's impossible the way I want
 
4:34 PM
@FoggyFinder is it possible with css maybe?
 
you would put the I in the <td> of that <tr>
 
@FoggyFinder hi, you can use the two-dimensional array to achieve .to calculate the center of the grid.
with aspose.word or aspose.excel
 
4:58 PM
Hello all
 
Whats up
 
I got a chatty kind of discussion I'd like to have about why everyone seems to hate "state" now
 
What's up
 
also not a whole lot
 
4:59 PM
Human governments all suck
 
@JanDvorak HA! no. I meant program state.
 
Stateless is easier to test
 
like...every program HAS a state, but there seems to be a lot of people who want to prentend that's not true
That's true. But say I'm making an oldschool RPG. Each character in a battle has a sate. I'm confused about how you'd make something like that stateless.
 
You wouldn't
But you can detach the concept of a character class from the state a character is in
might reduce memory overhead a bit if you're lucky
 
I'm not sure I'd understand how you'd do that. How do you have the concept of a character without a name?
do you mean separating the manipulation of the character state from the state?
going back to a more imperitive style where you'd have a state and functions that operate on that state?
 
5:07 PM
Pretty much
 
so...just removing one of the core ideas of OO.
Huh.
 
{x:1024, y:312, state: 0, prototype: <an object that can actually modify the former>}
 
I seem to have an unreasonably bad reaction to that
 
unit[i].model.ai.tick()
 
I don't know what that means :|
 
5:10 PM
The benefit is that you can store the model as a run-time instance.
Here, unit[i] stores the state and a reference to a model. The model is an object that knows how to manipulate the unit state.
Just an idea. I'm not sure if people actually do that in this case.
 
that seems unnecisarily complicated.
and doesn't seem to get you a ton of benifit
 
Good evening all
 
good morning!
 
could save memory. You don't have to store the model for every unit
 
but if you're working in C#, it doesn't matter. You're storing a reference either way
 
5:13 PM
@FoggyFinder You would do that using CSS. Do not use inline styles.
 
unless you're doing something weird and attaching manipulation methods to a struct
 
@ginkner Not really. I'd rather store a reference to a model than hold each parameter of the model as a separate value.
 
@JanDvorak but you're not storing each parameter. var store=unit[i] will take up exactly as much memory as var store=unit[i].model
unless one of them is a struct
or you explicitly clone one of them
 
@ginkner the point is that the size of each unit shrinks, which matters if you have thousands of units
 
but...we're talking about Model having only methods, right?
no state
or...rather whatever state is in unit[i]
...I think I confused myself
 
5:18 PM
var DarkKnight = new AIClass({alignment: "evil", preferredWeapon: "sword", mount: deadHorse, mood: Mood.Agressive}); var SauronsArmy = new Array<AIUnit>(10_000_000, i => new AIUnit(DarkKnight))
 
right. got a bunch of orcs.
 
I want the headless horseman's mount!
 
lol
I want to mount the headless horsman
much more intimidating
 
Indeed
:)
 
@JanDvorak but now AIUnit has a state. It's just a state that's shared between all the other AIUnits
which is cool
definately
 
5:21 PM
Here I have a parametrized model that is quite a bit larger than eight bytes. I don't want to store each parameter with each AIUnit, so I collect them into an AIClass (which is sort of a class instantiated at runtime), then separate out things that differ for each dark knight.
You could argue that the AIClass is stateless because its properties are immutable and set at start
 
oooh they're immutable properties
ok
that makes more sense
as long as you don't include a ChangeState method
I get it
ish
 
If you could modify the mood of each knight separately, then it belongs to AIUnit, not AIClass. Otherwise each knight would kinda have to get mad at the same time.
Which is hard to justify
 
yeah, I noticed that, though I caught on "mount" being changed.
"SUDDENLY EVERYONE HAS DRAGONS!"
But if you could do that, you couldn't call AIUnit stateless anymore
because it absolutely has a state
 
That's even hard to justify :-)
 
I still think it's a little hard to justify calling it stateless at all. It just has an unmodifiable state.
 
5:26 PM
semantics
 
I don't think so. A sateless object would be one that literally has no state. Something like a strategy
"strategy"
or the Action class
THOSE are actually stateless. there's no state telling them how to do their job
they just do it
even then, you could argue that the parameters given to a method are a kind of "state"
that could be the key though, if people are calling any object with unmodifiable state stateless
 
OK... you define "state" and I tell you where the corresponding stateless objects could be useful.
 
but then there's a conflict with "Immutable"
 
How about "compile-time constant"?
 
State...I'm gonna pull this straight out of my butt...would be data that modifies the outcome of a given operation.
that would be more reasonable
and more correctly descriptive
 
5:31 PM
Then all of your code counts as state
 
so yeah, not a great definito
which is probably why I'm confused about the whole thing
 
maybe it helps to think of state and data as very different things?
 
what's your definition, then
 
My example above uses "state = mutable properties of an object". AIClass' properties are immutable and hence configuration, not state
 
@JohanLarsson Your input would be usefull as well. Please elaborate.
 
5:34 PM
@kush I don't know - only the second day I started to learn web programming
 
@JanDvorak ok. That makes sense given the.
..context
 
say you have a device that you can read values from, then each read would return immutable data.
But then you could have a class exposing CurrentValue, that would be state.
Not sure it is a good example.
 
@JohanLarsson It's a somewhat good example.
It feels..weird though
 
I think it is a good perspective to have, state is trouble :)
 
because a class Device{int CurrentValue{get;}} would be statefull, and Device{int GetValue();} would be stateless, even though they both provide the same functionality.
 
5:38 PM
State can be illegal, race conditions etc
@ginkner oh, that is not how I meant, the one with GetValue would still be stateful
 
@JohanLarsson yeah, race conditions are definatly an issue. I hate them.
@JohanLarsson then how would you actually get the data?
 
But the value, the int would be data.
 
ooh i see
 
Int is a poor example, maybe a price tick on a stock is better
 
Yeah, I can see it i think.
 
5:40 PM
once it has happened it is history and will never change
 
so you could say "The state of the ticker is {data}"
 
but the current price will be constantly changing
 
OK, I'm totally confused now. What the hell is a program state?
 
It's an interesting distinction
lol
I don't know!
that's why I was asking
ah.
I'm not sure? According to your own definitions, it would be the mutable properties on the Program class
 
Sounds like a decent definition, mutable values.
 
5:44 PM
though...one could extend that to every property in the herarchy of mutable objects pointed to by properties or fields on the program state.
and then you get into DI and who the hell knows
Anything Statefull in the container?
and then you get into MVVM and VM's are supposed to be stateless even though they explicityly provide methods for mutating the underlying model.
It's incredibly confusing
 
who says vms are supposed to be stateless?
 
A large number of tutorials
:/
 
View-models are stateless. They only hold an immutable reference to a mutable object.
 
link one?
 
Don't ask.
 
5:50 PM
@JanDvorak yeah, but then they provide commands that mutate that model.
 
That's semantically the same as providing an object (the model) that provides methods to mutate the model.
 
I don't see a difference between an object that reflects the state of a mutable object and provides methods for mutating it, and an object that simply stores the state and mutates it itself. The viewmodels properties are still ultimately mutable.
I can KIND of see your point, but it doesn't mesh with your definition of state.
 
28 mins ago, by Jan Dvorak
My example above uses "state = mutable properties of an object". AIClass' properties are immutable and hence configuration, not state
 
yes
Properties on a viewmodel are mutable
not directly
but they are mutable
otherwise NotifyOnPropertyChange wouldn't be a thing
 
What if I say there are two kinds of immutable?
 
6:04 PM
then I'd hate you forever and throw ice cream at you.
But not good icecream
like...goo flavored ice cream
 
What if I say that method is misnamed and should be notifyOnModelPropertyChange? :-)
 
Then I'd say you're trying to wiggle out of adding "Directly Mutable" to your definition.
and It shouldn't be, because models can implement it as well.
there's no garuntee that your model won't change.
 
So, let me just add "directly mutable" to the definition
 
unless the viewmodel does
Ok. that works for now
 
for now
 
6:07 PM
Untill I inevitably run into another situation that confuses the shit out of me and it breaks. :P
 
yep
Then I'll refine the definition again
 
still, it works for a lot of things, including F# and haskell
they're what really got me confused.
I love the shit out of haskell (When I can get it to compile) but god damn it's weird
 
In Haskell nothing is mutable outside of IO
 
yeah. It's freaking weird.
 
6:09 PM
lol
 
hence stateless data, hence referential transparency
 
Flamebait title :) but he's pretty much right
 
Yeah, I can see it
Though peices of it keep showing up in C#
 
Functional programming only seems weird because you're not used to it
 
they're considering adding pattern matching to C#, and that seems ripped right out of haskell
Oh sure. I get that. It's not bad by any strech
it IS weird though. Thinking of "4" as a series of function compositions rather than a literal is not natrual.
 
6:11 PM
@JanDvorak well one of the points of that article is that FP is unintuitive because the expression of a problem is not the way people think, most of the time
 
But as soon as you draw a parallel between tail recursion and iteration, you have something like mutation again
 
@TomW +1
 
@ginkner That's not functional programming. Those are church numerals.
 
However it might actually be more favourable to people like lawyers, who work very strongly in the area of definitions of things. << personal conjecture
 
Also, mathmen
 
6:13 PM
@JanDvorak yeah, but it's not quite the same. Recursion is also weird.
 
but even in math I often do "let us define X using the following algorithm: ..."
 
Yeah. What are those...Completions?
set...compositions?
some C word
 
Fix points are fun, too
 
@JanDvorak wat?
 
fix f = y where y = f y
fac = fix (\f x -> if x == 0 then 1 else x * f (x-1))
 
6:17 PM
dafuq?
 
repeat x = fix (x:)
 
I'm going to look that up when my brain feels better
 
fix is a function that calls another function with its result as its only argument, and returns that result
 
my brain asplode
 
user6096770
hello
 
6:18 PM
Hello!
 
user6096770
do you use mvc?
 
I do not personally, no.
 
The result of calling (1:) on something is a linked list with 1 as its head and that something as its tail. fix (1:) is the fixed point of iterating (1:). That is, a list with 1 as its head and itself as its tail.
 
@JanDvorak stooop. You're gonna get brain all over my wall.
 
Which is isomorphic to and an in-memory representation of an infinite list of 1's
 
user6096770
6:22 PM
have you guys used hackhands before?
 
You mean that chicken from that one movie who got turned into a chicken-axe?
 
Prelude Data.Function> fix ('.':)
".......................................................................................................................
........................................................................................................................
........................................................................................................................
........................................................................................................................
 
yes. Yes I see
 
And... what's the result of passing a function to itself? Yes, it's a function that can call itself.
 
woo
 
6:29 PM
The actual definition is fix f = let x = f x in x
 
that's weird
dude I just started with haskell. Give me a break :P
 
Which is the same as fix f = x where x = f x
 
fix fix
wait
fix fix f
 
Prelude Data.Function> :t fix fix

<interactive>:1:5:
    Occurs check: cannot construct the infinite type: a ~ a -> a
    Expected type: a -> a
      Actual type: (a -> a) -> a
    In the first argument of `fix', namely `fix'
    In the expression: fix fix
Prelude Data.Function>
 
lol
"Infinite type"
that's rediculus
 
6:34 PM
In other words, fix fix only operates on functions that map a (function from a function ... to a function ...) to a (function from a function ... to a function ...)
In other words, don't do that :-)
 
Time to try emacs.
Because apparently mice aren't cool enough
Aaand that didn't go well
You ever use one of these archaic linux text editors?
 
00:00 - 19:0019:00 - 23:00

« first day (2045 days earlier)      last day (2886 days later) »