« first day (1626 days earlier)      last day (3328 days later) » 

2:03 PM
I would say that bcrypt is excellent, larger versions of SHA are good, smaller versions of SHA are fair, and MD5 is poor.
 
Good Morning!
 
However, there is no verified bcrypt implementation for .NET
 
Is there any way to write all exception into output window while debugging?
Automatically
 
AppDomain.FirstChanceException and Debug.WriteLine
> You must not use BCrypt in .NET. You must use PBKDF2 as is with the built in .NET framework implementation. It is the only freely available cryptographically verified implementation in .NET along with being the algorithm recommended by NIST.
worth thinking about
 
hey does anyone have any insight on this stackoverflow.com/questions/29347709/…
in rails its pretty simple using response.body i feel like it should be the same but i am doing something wrong
 
2:13 PM
I like this picture
 
@BobSinclar does the documents say to use [] in the method params?
 
@Teomanshipahi what do you mean "all exception"? Have you considered using a logger, like log4net or NLog?
 
Hi there
I am right to assume that a C# foreach used on a list actually use a copy of said list ? (Since it's a reference type, I mean a copy of the reference)
 
@LukeMarlin no
It's kind of complicated
 
Really ?
 
2:16 PM
look up "GetEnumerator"
that's what foreach uses internally
 
I tried this simple test on LinQ:
List<string> list = new List<string>(){"a", "b", "c"};

foreach(var a in list)
{
list = new List<string>(){"d","e","f"};
Console.WriteLine(a);
}
 
it returns an object that enumerates over the list
@LukeMarlin It's using the object, not the variable
 
@juanvan " does the documents say to use [] in the method params?" I am not sure what you mean
 
Ok so in fact the IEnumerator itself possesses the initial reference of the list provided to the foreach loop
 
the variable can change, but it will still be enumerating the same list
@LukeMarlin yes indeed
 
2:18 PM
@KendallFrey wat
 
@KendallFrey Got it, thanks for the precision
 
[FromBody]String you are casting it?
 
O wait I get it
 
yeah, which is why you get errors if you try to modify the list inside a foreach loop.
 
Same behavior as I expected but not for the same underlying reasons. Nice to know.
 
2:19 PM
@Squiggle I mean, with no external logging, just I want to set up a kind of setting in app.config file and if Exception thrown (even if it is catched) it will be logged into log window
 
@Teomanshipahi you need a logging system. It's not something that .Net provides out-of-the-box.
 
@jua
 
@Sippy google image search "wat", so much gold
 
@Teomanshipahi because any unhandled exception that would be thrown will exit the process, unless you try/catch and log.
 
2:20 PM
@juanvan no I am not casting it. What should i cast it to? it comes in as what an object and then i need to cast it to a string?
 
@KendallFrey I don't feel safe doing that at work
Someone already tricked me into clicking "dicksinthemail" or something today
 
@Squiggle I see.. Because, for example I can log all httpWebRequest/response calls with app.config setting, so I do no need to log externally these calls
I was hoping something like that
 
@BobSinclar what are you looking to do? remove [FromBody] and see if you get a value?
 
@juanvan I want to take the data from the body of the post and do something with it in that method.
but i cant seem to access it
 
2:22 PM
 
   public string Put(int id, [FromBody]string value)
        {
            System.Diagnostics.Debug.WriteLine("Put !");
            System.Diagnostics.Debug.WriteLine((string)value);
            return "gerd"+value;

        }
 
etc. etc. etc.
 
@KendallFrey lol
 
the 2nd writeline is always blank
 
ok - so you want the post data - and what app is it in web forms mvc?
 
2:23 PM
@BobSinclair Format your code - hit Ctrl+K before sending and see the faq
 
its a ASP.net webAPI
@CapricaSix thank you wasnt aware of control K
so i inherit from APIController
 
Ok so its in a MVC style app - you have a RouteConfig in App_Start Folder
 
yes it is
public static void RegisterRoutes(RouteCollection routes)
        {
            routes.IgnoreRoute("{resource}.axd/{*pathInfo}");

            routes.MapRoute(
                name: "Default",
                url: "{controller}/{action}/{id}",
                defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional }
            );
        }
 
ya the default
 
// PUT api/activate/5
        public string Put(int id, [FromBody]string value)
        {
            System.Diagnostics.Debug.WriteLine("Put !");
            string trythis = (string)value;
            System.Diagnostics.Debug.WriteLine(value);
            System.Diagnostics.Debug.WriteLine(trythis);

            return "gerd"+value;

        }
the problem is those last two writelines are always blank
meaning I cant seem to get my hands on the body of the Put
 
2:27 PM
what is the name of the value in the query string?
 
same thing with post
 
url.com/?value=StringData
 
oh.....
i was doing it wrong
 
and remove [FromBody]
 
@juanvan THANK YOU sooooooo much!
I was using Postman wrong trying to send it in the body
 
2:33 PM
@KendallFrey I'll have to check that out, do they have a specific example?
 
sending it through the url is way easier
 
@KendallFrey I know that the BCrypt Library was ported to .Net.
 
Yes very!
 
@Greg read the whole question: stackoverflow.com/questions/481160/…
@Greg it's not verified though
 
@KendallFrey Didn't see the question.
 
2:34 PM
there are several really good answers
 
@BobSinclar Part pass data done ;-)
 
@juanvan do you know how to send multiple data params?
that works for 1
http://localhost:53676/api/activate/2/?value="jordan"
localhost:53676/api/activate/2/?value="jordan"/…;
the second one is off do you know the format for multiple ones?
 
uh, the normal one?
 
^ average qString- activate/2/?value=jordan&foo=apple
you don't need the "" items in the q string are passed as string all the time
 
SCRUM question: Is it a bad idea to estimate to fractional points?
 
2:38 PM
thanks again @juanvan
 
@KendallFrey Yes.
 
@KendallFrey I would say so, I know a group that does so in hours and it seems terriblew
their estimates are # of hours to complete , I take it you use work days?
 
We tend to go to the half-unit when there are some above and some below
@BobSinclar "units", which are half a day
 
yeah I think going to that level is kind of silly
 
We think we use scrum, but we don't anymore
 
2:40 PM
because lets say you say 2 hours
and you have 8 hours of points
an all hands meeting
 
@Squiggle I was listening to a software development podcast where they talked about how they were perplexed by coworkers approaches to cooking
 
a kaizen or retro anything can throw off your velocity
when your measuring that fine grained
 
Certain kinds of people with little cooking knowledge are comfortable substituting one cup of milk with one cup of butter...
 
so your estimates are rough and you will spend more time trying to estimate is it a 1.5 or a 2? and the debate ensues
 
Morning
I was hoping one of you guys could point me in the right direction for a scripting language to use with C#. The requirements are to be able to compile at runtime some script, and have it act on some parameters it receives, as well at return a value. It would be best if that language had support for .NET types like Dictionary and whatnot
 
2:52 PM
@MarkW C# isn't suited to the job? Aside from that it isn't a scripting language.
 
vbs :)
 
Well it may be, I have no experience with compiling C# code at runtime
 
@Jeremy :-/
@MarkW what stack does it need to use?
 
I don't understand the question Squiggle
Basically, im going to have a string with values like "SOMELITERALHERE SomeObject.SomeProperty: SOMEOTHERLITERAL SomeObject.SomeOtherProperty" and so on
 
@MarkW does it have to be script or compiled?
 
2:57 PM
I would like to be able to pass a Dictionary<String, String> to a script along with that string
and have it perform some replacement and stuff to the string, then return the value
pretty much we want to script out doing replacements for the zebra printer scripts
 
are you using a DB or no? Stack is the Technology that makes a solution
 
yes
 
ooh Zebra printers! Fun times :-/
 
the idea is that when a customer changes what they want on a label, we can modify this VBScript / JavaScript / whateverscript
 
FUN like being the midget in a midget tossing contest?
 
2:58 PM
instead of having to build new plugins/ whatever
 
@MarkW sounds like more of a templating solution to me, surely? Wouldn't Razor work?
or some other templating solution
you can do loops, complex objects etc
 
@Squiggle maybe... I'll look into it
 
When I did Zebra prints we just created a fluent interface to a clever string builder
 
"Razor is a simple programming syntax for embedding server code in web pages. " lookin at the page
how will this help me?
this is not a webpage
its a stand alone applicatoin
 
You compile a string command to send to the printer, right?
 
3:01 PM
Believe it or not I have seen Razor used on the server
 
yeah
 
in a custom mail generating service
 
@TomW that's how I use it right now, too
 
is Razor something you can just chuck in a txt file and execute?
 
new zplLabel().Title(product.Name).Barcode(product.GetBarcode()).Price(product.Price‌​).ToZplString();
 
3:02 PM
cept... we need to be more flexible than that
our customers have really really diverse printing requirements
we really need a solution that can take in arbitrary data of virtually any type, and do replacements on the string
like even complex objects
like say... they want some UDF
I have an object that has UDFs on it, and in the template put in SomeComplexObject.UDF1
the script needs to be able to do that mapping
 
aha OK
 
There is a stylesheet language called XSL-FO (FO for Formatting Objects) that is intended to be a comprehensive standard for document layout. I have never seen it used by anyone and it looks hella complicated
 
lol thanks Tom
 
But if you could write something that emits FO, then I think you could satisfy more or less any requirement
 
hehehe
 
3:04 PM
XSL-FO is complex. I'd go with a Javascript-based templating engine, but then again I'm a web guy.
 
@Squiggle what I hate is that enough people ask this question to warrant producing that site
 
Ive used JavaScript with the Rhino engine in Java
it was killer, but I don't know if JavaScript can use .NET types
 
Has anyone used the VS2013 installers?
 
in Java -> JS all of the types worked out fine
brb
 
@Sippy just installed 13
 
3:07 PM
Fucking thing .. I build the project with release config, drag it to desktop, try to install the web service and for some fucking stupid reason it installs to the local source control folder!?
GET IN INETPUB NOW
 
@Sippy do you mean publish web?
 
No
Web Installer
 
wat
 
It's a VS2013 installer project for click-once installers
 
ya but not for websites
 
3:07 PM
And you can build one that installs web services to IIS servers
Yea
 
is that in the vanilla version?
 
Yes
Watch
 
Btw fscking hell you respond quickly
I've barely read my own message before your response appears
 
man knows what he wants to say
 
@TomW :P
Helps that I type at 125wpm
 
3:10 PM
whaat
I think I measured at 55wpm once, accounting for correcting the many, many typos
 
It's an extension but it was part of earlier versions of VS
They just added it again cos people were crying trying to use InstallShield
@TomW Lol
 
yawns
is it career suicide to work for a company that uses a TINY fragment of .Net 2 and web forms with no plans to upgrade?
 
Yep.
That company sucks
 
@MarkW which sector are you developing for?
 
thats why I LOVE freelance
 
3:14 PM
its warehouse automation
 
you get to do it your way a lot more
and use newer tech more
is it all companies or just small ones that fail to provide a decent workflow and tech?
 
I loved doing warehouse stuff. The challenges were so easy to visualise.
 
^ 100% agree
 
really practical solutions, too
 
Ca someone tell me how I can get the following date in C#? Monday the 30th of March 2015 16:17 PM
 
3:17 PM
Now it's all finance and liquidity spreads and composite risk analysis on hedge fund derivative blah blah blah
WHAT DOES THAT EVEN MEAN
 
@MarkW I'm in "healthcare", and we play around with Zebra printers a lot, too.
 
lol I went crosseyed
 
Anyone?
 
@LiamHardy DateTime
you will probably have to overload ToString though, to get that exact format. Doesnt look fimilar to me
 
@JABFreeware Don't do that.
;)
 
3:21 PM
maybe, I should just do a plugin approach... Code to an interface, that accepts the top level objects, load the plugin assembly at startup, and invoke the contracted method when a print request is made
 
@LiamHardy look at this for the formats codeproject.com/Articles/14743/…
 
not as flexible as a script that you can just modify on the fly
hum
 
@MarkW I don't think C# is a particularly good language for really really dynamic stuff, personally
Requiring compilation and all. There's scriptable C#, but that's not first-class.
 
Why does not TabItem cannot set focus dynamically when it is nested inside Grid? TabControlMain.SelectedIndex = 0;
 
@TomW I hear you
 
3:23 PM
well they wont change their printing label requirements all that often, but two different implementations can have very diverse requirements
 
Please fix my installer guys
I hate it
 
Will this work?
String MyString;
MyString = DateTime.Now.ToString();

DateTime MyDateTime;
MyDateTime = new DateTime();
MyDateTime = DateTime.ParseExact(MyString, @"l jS \of F Y h:i:s A", null);
 
Why the fuck u no install in inetpub u fuking guy
 
I prefer the plugin approach. Less chance of idiots screwing things up.
 
@Squiggle we do have an idiot problem....
lol
 
3:26 PM
@LiamHardy Sigh... why are you asking?
 
Mark W what do you know
@JABFreeware are you dumb or just stupid? I asked because I want to know lool
 
@LiamHardy I wasn't referring to you Liam, I mean it literally... we have idiots who work here
 
Seing as I don't fancy firing up my application that takes a good few minutes to compile
 
and I have to watch out for them doing idiotic things
 
@LiamHardy experiment. Read the MSDN documentation. See what works.
 
3:27 PM
@Mark W right okay.
 
@MarkW you probably have some good stories, aye?
 
well @LiamHardy you are the idiot. There is this little thing called COMPILING. And then once its compiled you can RUN the project. Or if you are smart enough DEBUG it. This will make things happen on the screen. If you can handle it, use both your eyes (assuming you have two) and see what the result is. More than likely judging from your stupidity you will get a compiler error, in which case ask your mom because she probably knows more about it.
 
@Squiggle lol definitely
 
to summarize dont ask stupid questions here that can be solved via google and TESTING yourself
 
@JABFreeware Fair, bur harsh. Ease up a bit.
 
3:29 PM
Easy. Chill out or I'll kick you both.
 
sorry
bit on the edge this morning
 
Calm down and drink your coffee :P
 
@JABFreeware How would I mum know more about it? I don't see my mum much, although I did see yours last night.
 
@Squiggle I showed up on site for a client install a few weeks ago to setup hardware but no one seemed to think it was important for the hardware to be shipped before I arrived on site
 
I want my boxers back..
 
3:29 PM
4 days on site, and all I could do was setup the hardware side
 
!!facepalm
 
err software*
 
@LiamHardy doesn't surprise me, enjoy the STDs
 
You calling your own mum a slut
 
3:30 PM
yeah it was.... bad
 
@LiamHardy yeah I don't care. She was abusive. Try a different family relation if you want. Might have better luck...and get kicked.
 
@JABFreeware @LiamHardy Out.
Right.
@MarkW so, those disorganised businesses hey.
 
lol yep
 
@JabFreeware can't even code C# I bet
 
anyone ever heard that Frank Zappa song 'Flakes'?
I'm suddenly reminded of it
 
3:33 PM
Yes
Your mum was playing it last night
 
on her flute?
lol
 
mhmmm
 
nice
 
keep going
 
Good time for me to come back.
 
3:34 PM
She is a very talented lady
 
Gone again.
 
we all have our talents right?
 
lol
 
some sex, some programming, and some trolling
disclaimer: not an exhaustive list
 
I can do all at the same time
:D
 
3:35 PM
@JABFreeware I threw him out first because he was the first to continue with the BS. Quit it, or you'll go with him
 
@MarkW thats tricky, man
@TomW wont be a problem and yeah I was a little harsh
 
I don't object to Your Mom jokes per se. I've made them, mainly at Kendall's expense.
 
Monday monday monday
 
so good to me?
 
Day off woo
 
3:38 PM
Pshhhh
 
@TomW I love em, in case you hadn't caught on
in JavaScript, 2 mins ago, by Kendall Frey
@Loktar like your mom
 
@TomW so what do you object to about me?
hi @KendallFrey sup
 
why TabControlMain.SelectedIndex = 0; does not focuses on TabItem? Any idea, please?
 
@JABFreeware it was the absence of civility between the two of you that I thought I should nip in the bud.
 
@Marek is that winforms?
 
3:40 PM
@JABFreeware WPF
 
@JABFreeware from where I'm sitting you were responding to provocation, which is understandable, but still to be discouraged, so I discouraged it
 
@TomW indeed. It was quite incivil
uhoh thats not a word
 
What could potentionally lock the selection? any idea?
 
@Marek never used a tab in wpf, sorry...
 
@Marek The guys in the WPF chat might know
they are usually pretty helpful
 
3:43 PM
The SelectionChanged event is raised.
 
cept for netScape .... hes evil
(j/k)
 
I am not too crazy about WPF tbh. Its better than winforms for sure but...kinda... un c# link imho
 
my only issue with it is the MVVM pattern being somewhat... intrusive at times
most times it works out great relying on the framework and stuff....but sometimes, the MVVM approach (which you should follow) is orders of magnitude more work than just violating the pattern and using a more traditional approach
IE, dialogs
 
exactly
WPF demons will haunt you if you deviate from the pattern :P
 
lol yes
 
3:46 PM
And santa won't bring you any presents.
 
and Netscape and BradleyDOTNET will hound you without end until you see the error of your ways and follow MVVM
;)
 
Netscape... Ironic name considering... cough cough
nothing :P
 
lol Both really helpful guys though
 
WPF FTW
 
AngularJS 4 lyfe
 
3:51 PM
watches in the shadows
 
its ironic that this WEB reports viewer can't display HTML correctly. Either center OR bold. I guess you get both features if you upgrade from the Sucks version :P
 
after the ` SeletedItem` is called there are some load events to fill the comboboxes, can this be the issue?
 
@Netscape I see you lurking -.-
 
@NETscape Hi, Chrome here...
 
Can anyone help me get this to: Monday 30th of March 2015 08:17:18 AM
to the above format of a date/time

string lol = DateTime.Now.ToString(@"dddd MMMM yyyy hh':'mm':'ss tt");
MessageBox.Show(lol);
 
3:53 PM
Hey I just uninstalled Chrome last week... and now I don't have 10 separate chrome.exe processes consuming 30% of my quadcore CPU time constantly
:D
Best thing Chrome ever did for me was uninstall without asking to many questions
 
wow for real? I've never had that
guess you use firefox now?
 
@Marek binding to SelectedTab? Setting TabControl.IsEnabled = false.
 
half and half FF and IE
 
why would you use anything but chrome x.x
 
xx.x*
 
3:54 PM
unless you own a mac
 
multiprocess chrome ftw
 
Can anyone help me get this to: Monday 30th of March 2015 08:17:18 AM
to the above format of a date/time

string lol = DateTime.Now.ToString(@"dddd MMMM yyyy hh':'mm':'ss tt");
MessageBox.Show(lol);
 
@NETscape ur my hero
 
mac doesnt sit well with me
 
idk man, my pc was just being slow as hell for a few weeks. every time I opened up task man I would see a seemingly unending list of 'chrome.exe's in the list
 
3:54 PM
Windows 8.1 and Chrome all the way
 
removed it and now my PC runs smoothly
 
@LiamHardy why would you want an "of" in there? :S
 
@MarkW maybe you got a bunch of bad extensions?
 
I don't
 
I only had google talk on it
 
3:55 PM
I'm still using windows 7, is that a bad thing? I don't like win8.1 :3
 
:/
 
i just copied that from my PHP page
 
I think each extension runs in its own process not sure
 
lol PHP etc etc
 
@Meraj99 cant stand it, without classic shell
 
3:55 PM
I just need the '30th'
 
@LiamHardy welcome back.
 
@JABFreeware as well as each tab
 
classic shell? what...?
 
@JABFreeware Thanks Mate!
 
@NETscape thats why I love it. Then again i have an 8 core CPU so...
 
3:57 PM
I added 'dd' for the day of the week, but I can't get the st/th/nd on the end?
 
@Meraj99 yeah man, it makes the start menu Windows 7 like, and brings back aero themes. Its awesome
 
Im sportin an 3930k
its pretty badass 6 physical, 12 logical
cant even touch the thing
 
quite nice :)
 
definitely
with 32 gigs of ram, and a nice gfx card
thing cost me 3k to build
 
AMD here and not looking to get into an AMD vs Intel debate :P
 
3:58 PM
@NETscape I am able to switch the tabs now, but how can I bring the TabControl to state when it is Enabled? I tried to set TabSale.IsEnabled = true; after all the loads are completed, but the tab switching stopped to work :/
 
but its liquid cooled, and definitely wears sunglasses at night
 
what card, @Marek?
 
@LiamHardy It looks like the DateTime toString format doesn't support ordinal indicators. I suggest rolling your own little helper.
119
Q: Is there an easy way to create ordinals in C#?

GateKillerIs there an easy way in C# to create Ordinals for a number? For example: 1 returns 1st 2 returns 2nd 3 returns 3rd ...etc Can this be done through String.Format() or are there any functions available to do this?

 

« first day (1626 days earlier)      last day (3328 days later) »