« first day (1783 days earlier)      last day (3391 days later) » 

14:00
So far, I really like VS Code, better than webstorm
@Failsafe precisely like Ook.
vscode is the shit
i was at BUILD when they announced it
was instantly playing with it
@CharlieBrown I like it too, but, I must admit, I much prefer Atom over VS Code at the moment. VS Code has some features I miss in Atom, but the lack of TypeScript 1.6 awesomeness in VS Code is.. meh.
I've been using sublime or webstorm for the last 2 years, but VS is so much better as an IDE...but I like they way sublime handles folders (and not projects).... this is the best of both worlds
plus intellisense and git integration
is pretty nice
14:02
now that I think about it, i havent done full time c# in almost 2 years... yikes, im in the wrong room!
i was doing c#
now im maintaining vb
i despise vb
with a passion
12yrs of c#, now all i do is node/angular
when vb finally dies it'll be a good day
debugging in vs code... im in love, its over, it wins
            0 : 1
Charlie Brown : Visual Studio
14:12
Ice cream cake: 900
@CharlieBrown VS can do file-based projects too. With the right plugins. NodeJS tools is awesome for example :P
posted on September 03, 2015 by Nikolai Tillmann

This is a temporary post that was not deleted. Please delete this manually. (ab5e4ffa-2df1-475f-8aa8-cdbbdd0051ce - 3bfe001a-32de-4114-a6b4-4005b770f6d7)

4
@Feeds lol
lol
i love it when ppl post debug info on their website so i can debug it for them
14:26
Any RestSharp users here?
used in the past
found that it was in pretty bad shape and no longer maintained
maybe it's better now
which I doubt since the website still only mentions version 103.0.0
posted on September 03, 2015 by Nikolai Tillmann

We have some exciting new developments to share – an update on our open source development, our ongoing cross-platform work, and more. Going forward, we will post everything around MSBuild and build tools in general here on the .NET blog. You can still check out the many interesting tips and tricks that we earlier posted on the MSBuild Team blog. MSBuild is now open source, and it is go

FYI version 103 was released in sept 2013
@ton.yeung Hm, better TypeScript support, better task support, cross-platform. Thats it.
in short: don't use restsharp
use System.Net.Http apis
14:30
@ton.yeung gulp/grunt/custom tasks
14:40
ok
thanks, I am finding it a bit lacking
i'll head over to the System.Net.Http apis as Steven suggested or just go back with javascript
Always bet on JavaScript.
real talk, javascript never fails
except when it does
I just wanted to use a different approach this time around
:D
Someone sell me on typescript. I dont get it
14:47
im not a fan of msi boards
had one where all the USB ports failed
except 1
never had a problem with MSI boards - have 4 running right now
i like asus a little
some gigabyte boards
i miss abit
like the g99x
i really want the asus sabertooth board
or whatever its called
@Shoe JavaScript with types! What's not to love?!
14:50
disgusting
@Shoe Seriously though, what don't you get?
I understand what it is
I just dont get why
Because working with many people on a single JS code-base is a recipe for disaster?
So because tool support?
But they aren't the same
@Shoe Pretty much. It's simpler. You can explore the source code with tools, use analysis functions, do advanced refactoring, etc. Also, when a library changes, and the definitions update, you get compile-time errors. Just like in C#. It's essentially a massive amount of automated tests right there for you.
Besides that, you can use new ES6 features, like class, lambdas, etc. Turn on the experimental stuff and you can even use async/await and generators.
15:01
Taking a dynamic language and adding types to it seems like adding pontoons to a car
@ton.yeung It means I aint got time to learn your $5 words.
@ton.yeung its lightweight and cross platform like sublime, but with the epic code editing/intellisense/debugging of VS
@ton.yeung pontoon (military) A flat-bottomed boat used as a support for a temporary bridge.
@Shoe But JavaScript has types. It just doesn't explicitly show them. And with TypeScript, they do, and actually do all kinds of neat validations and possibilities open up. It's honestly a lot better than making a completely new compile-to-JavaScript language that is COMPLETELY different, because it's opt-in, and all JavaScript is valid TypeScript ;-)
If your coming from c#, its easier to learn es6 I think than if you dont have experience with similar concepts
15:05
VS Code has full support for that AFAIK. Well. MVC6 at least. Not sure about 5.
MVC6 support. Its geared toward js though. And the debugging for js is as easy as c# debugging
@RoelvanUden What do you mean by it doesn't show them? JS only has a few primitive and special types. There are "no" reference types.
w00t. Our 4th internal Angular JS project has just been commissioned. From 2 Angular devs to 8 and counting now
Angular is even starting to phase out WPF here
@Squiggle nice
@Shoe Hm, but there are prototypes and you often build functions with prototypes that act to create instances of objects with the prototype set to that. Therefore, the regular classes, or types, if you will. There are of course, also the primitives, and also things you want as a contract in parameters, but you could not define previously. With TS you can. That's pure gold.
function iteratePeople(people) What does 'people' need to be?
You have to read the code to find out..
function iteratePeople(people: {age: number, name: string}[]): number
And suddenly you know exactly what it wants and returns just from the signature.
15:11
really, you get the good parts of a typed language but still can use the dynamic stuff that makes js so awesome
the only thing I dont like is the syntax, but thats more just getting used to it
And if the signature changes, code dependent on it fails, for obvious reasons. Which makes refractoring better. Additionally, as Charlie said, it's all opt-in. You can gradually type what you need and keep the dynamicness where you prefer that.
@RoelvanUden But duck typing is one of the strengths of JS
people could be an object, could be an id
Does something different for each of them
But did you ever intent for a string to be passed in? And how do I know you didn't account for that possibility?
function giveMeSomethingISupport(item)... ??
Could be, docs
function giveMeSomethingISupport(item: string|number)
Now I know you want either a string or a number..
So if you, in your lib, pull support for the string variant but require numbers now, how will I know?
Read all the docs again for changes? hahaha
15:15
And in a statically typed language it would require two methods
Sure, but it's still JavaScript, the one you know and love and does all that magic stuff you care about. Only you could see the types as defensive guards. :)
Contracts, if you will.
I guess I understand
Roadblocks, if you will
15:44
@RoelvanUden obviously because the library's authors strictly observe semver, you'll notice that a major version increment denotes breaking changes and then you'll read the release note.
Oh wait, you're serious. Let me laugh even harder
screw minor versioning
slap a new major version on it every time
CMS's are death to web developers, they just suck the life out of you
*at least, in the case of business applications. They may/may not be useful for marketing sites
Quick, how many files do you have open in VS?
15:53
33
1000000000000000000000000
Haha, I'm a noob. 2
1337
what if I have multiple instances of visual studio open?
do I win?
15:54
i literally have 7 VS open
i hate it
well I only have two
only if you have more files total
they are all different projects
some with hundreds of pages
I don't know how to count them all
15:55
Close All But Pinned is a lifesaver
@Failsafe different solutions, right?
yea
different sites
excuse me "applications"
what happens when you press float all?
*universe explodes
bad screens all over
oh god don't tempt me
15:55
Close all is great, Wish sql manager had it
I clicked float all
was very disappointed
i have a bunch of source that i dragged out of the main window
that are also seperate windows
so its like 7 applications plus 20 seperate code windows
Hey, since you're talking about VS...
Is there a way to make the autocomplete suggestion list longer? I'd like to see all members but it only shows 9 with a scrollbar.
there should be tabs at the bottom of that window
that say "Common"
and "All"
or DL resharper
its lunch im out
I'm talking about this kind of autocomplete. No tabs here.
16:00
dark theme
opinion disregarded
don't like the dark theme?
@Shoe Why the hate against monokai?
Anyway, lunch break it is
@Shoe Dark theme master race
@ton.yeung count 'em in the dropdown
Check this, I decided to throw down the RestSharp client library because when my WebApi service returns an error to it I have to do too much Deserializing to dig out the message t from the Content field
16:08
for once, I agree with @Sippy
But I just tried the .NET apis as suggested by Steven and the message doesn't even come back
:(
Only the status
I give up :( I am so going back to javascript
Is it so much to ask for a nice way of getting the error message that comes back from my WebApi server...darn
Getting it out
Ok, where do I start
16:15
1 line of code easy
reminds me, i should eat breakfast
eating is overrated
@ton.yeung I tried so many ways, my code is upsided down right now. Let me refine it in the simplest fashion...gimme a sec
so, been fighting this for far too long. Trying to get unobtrusive validation working on an ajax loaded form. jquery.validate.unobtrusive.js is loaded, all the form elements have the extra properties... but nothing is triggered on submit or on blur etc... any ideas?
@ton.yeung My client variable (_client) is already stuffed with my BaseUrl and all from the constructor
In the Add function, which takes a "CreateduserBindingModel" (this is the object to be created)
I have this
var request = new RestRequest("api/accounts/create", Method.POST) {RequestFormat = DataFormat.Json};
request.AddBody(objectToBeCreated);
var response = _client.Execute<CreateUserBindingModel>(request);
Now when this comes back, with the error message (Since I purposely made it fail), The status is BadRequest (as expected), but the error is in the Content
Which I have to do 3 to 4 different Deserializing operation to get to
Ridiculous!
16:35
RestRequest?
yup
I was making reference to the RestSharp
as it relates to the .NET apis, the message come back, only the status and code
For the .NET apis I did:
In the constructor:
client = new HttpClient {BaseAddress = new Uri(_url)};
client.DefaultRequestHeaders.Accept.Clear();
client.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
ok...
where?
if you use mvc you can just print out the stacktrace from _Error.cshtml
>.>
@ton.yeung FCC wants to ban the use of tomato and other OpenSource router fw
@ton.yeung hmm... so the error did come back with the httpClient, only it came back just as it did when using the RestSharp, which I had to deserialize much
It comes back like this:
t "{\"message\":\"The request is invalid.\",\"modelState\":{\"\":[\"Passwords must have at least one digit ('0'-'9').\",\"That's a really cool guy, but please don't use him in your password\"]}}"
3 Times!
the times tribune
16:50
var deserializedObject = JsonConvert.DeserializeObject<Dictionary<string, object>>(result.Content);
not enough
so...
var deserializedObjectNext = JsonConvert.DeserializeObject<Dictionary<string, object>>(deserializedObject["modelState"].ToString());
dynamic...
hmm...
will try that now
Yep - could use a Raspberry pie too
can add a wifi ap to it
Would
how would they know
If you are writing code and think "this sucks, its way more complex or difficult than it should be"... then your right, your probably doing it wrong
16:56
how would they know what firmware i had
i don't buy it
its not in the stack is it
as a header or something
not sure if you can from outside..
message too long
>.>
anyway i can post this quote
i dont really know the stack chat syntax all that well
is there any way i can post a block of text, in this case, a quote from an article, without the "message too long" info field appearing
that's the dumbest shit ive seen
"(FCC rules) require that the devices must ensure that under all circumstances they

comply with the rules. The majority of the devices have software that is used to control the functionality of the hardware for parameters which can be modified and in turn have an impact on the compliance of devices. Our rules do permit radios to be approved as Software Defined Radios (SDRs) where the compliance is ensured based on having secure software which cannot be modified. The (FCC's) position is that versions of this open source software can be used as long as they do not add the functionality to mo
more importantly
The (FCC's) position is that versions of this open source software can be used as long as they do not add the functionality to modify the underlying operating characteristics of the RF parameters.
they are leaving it up to the manufacturers to take steps
which they wont
guys if i for example have a Tcp server and client program and i send form the client to the server a small images
and somtimes i want to send some text
how would i be able to indetify when it's a text and should displayed in a textbox, and when it's just an image?
sending a header before would be a good idea?
what are you returning the "text" as
a request variable?
this is a byte array im sending over a socket
a string converted to byte array
@ton.yeung i dont know im just using tcp :)
17:09
public Image byteArrayToImage(byte[] byteArrayIn)
{
MemoryStream ms = new MemoryStream(byteArrayIn);
try{
Image returnImage = Image.FromStream(ms);
}
catch (Exception e){
isText = true;
}
return returnImage;
}
try catch around the image
Thanks for that extra useless whitespace, TFS
@Failsafe amm nice. didnt think about it
         wow
many hack cringe
   wow
                        very hack
so  cringe
17:17
@Squiggle 9gag.com/gag/apB1zw5 Since we were talking about it...
@Failsafe another question- if i have to send a very small data,between 10-14 characters, would i have to send first of all the message length? even it's maximum 14 tabs?
@Slashy what are you using to send?
@Failsafe a small text string
realy short
maximum length is 14
i mean like, what's limiting you from sending the string? are you using some api or function that needs 2 parameters, i.e. Length, and String?
@Failsafe it's a tcp protocol.. i would not be able to read the data in the receiver side
i need a certain length
17:23
substring your string
ok, so using the modelState instead of the message (Since that's where the actuals errors are): var msg = foo.modelState; //this gives {
"": [
"Passwords must have at least one digit ('0'-'9').",
"That's a really cool guy, but please don't use him in your password"
]
}
Guys can I change the name of the tab I have opened in chrome?
Like it should appear as something else
then what it is
lol i just saw google's new favicon, make me thought somebody is mim on me
Viewbag.Title
i'm stating the result of the actions I took
17:25
You can put RegEx on your model parameters you know
and then just do @Html.ValidationFor(x => x.YourThing, "*");
and it'll put your error message up there
I can live with this, it's easier than the previous method
Thanks!
<Display(Name:="Description Column")> _
<RegularExpression("^[A-Za-z0-9]{3}$", ErrorMessage:="Your Error Message")> _
<Required(ErrorMessage:="Description must not be empty.")> _
It's in VB but you can easily translate it to C#
oh goood that underscore
shhh
[Display(Name="Description Column")]
[RegularExpression("^[A-Za-z0-9]{3}$", ErrorMessage="Your Error Message")]
[Required(ErrorMessage="Description must not be empty.")>
there
17:31
Hey all, I'm currently doing some calculations with percentages. My simplified code is something like this:
requestMadeValue = 5
allRequestsCombinedValue = 5
howMuchIsThisRequestOfTheTotal = requestMadeValue / allRequestsMadeValue
which will always result in 1.

Except when a request has been made with 0 :). Does anyone know a smart way (without having to check wether the total requested is 0 to also obtain 1 when having 0 as total and requested)?
I could ofcourse do if (allRequestsCombinedValue == 0) { result = 1 }
But it feels so nasty
yea you should do that
It just feels strange that A / A = always 1 except when A = 0
How about math.max(stuff, 1)
yea
..
float also returns NaN
17:35
float x = 0.0f;
int returns divided by zero
Shoe, hmm, is NaN higher then 1, hmm let me check
which number is 0
Shoe, meh Math.Max(Nan, 1) also returns Nan
You didnt explain your problem well enough I think
NaN = Not a Number
17:37
Yeah I know :)
Is "pended" a word?
Can you use it in a sentence
@Devedse Or A = infinity :)
@Failsafe sure
> Check-in operation was stopped because after saving all your open files, the system pended changes to some additional files. Review your pending changes, make sure all related changes are selected, and then perform the check-in operation again.
yea i guess
pended

simple past tense and past participle of pend
pend is a word?
17:43
so i guess it makes sense
@ton.yeung pended simple past tense and past participle of pend
@ton.yeung pend (obsolete) To hang down. [15th-19th c.]
good
its ours now
hang down? as in your mom's breasts?
@KendallFrey y..yes
17:58
what's wrong with tabs?

« first day (1783 days earlier)      last day (3391 days later) »