« first day (2163 days earlier)      last day (2799 days later) » 

12:51 AM
Can anyone explain why i just get the System.Collection thing instead of the names in this code here
private Dictionary<string, List<string>> GetNameThatStartsWith(Dictionary<string, List<string>> names, string letter) {
Dictionary<string, List<string>> filteredNames = new Dictionary<string, List<string>>();

foreach(string name in names.Keys){
if (name.StartsWith(letter)) {
filteredNames.Add(letter, null);
}
}

return filteredNames;
}

private string ShuffleNames(Dictionary<string, List<string>> name)
{
for (int i = 0; i < name.Count; i++)
{
Dictionary<string, List<string>> tmp;
tmp = name;
name = name;
It doesn't let me format it . is it ctrl+k ?
 
 
6 hours later…
6:32 AM
@june1992 you're setting the content of the labels to name.Values.ToString();, Values is a ValueCollection
 
@TomW hi
do you have idea about sqldependency ?
@3imad
 
No and please don't ping people at random
 
ok
I wrote some code but it is triggering only once
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data.SqlClient;
using System.Data;
using System.ComponentModel;
using System.Security.Permissions;

namespace sampleconsoleService
{

    class Program
    {
        static void Main(string[] args)
        {

            string connectionString = @"Data Source=ARUN-PC\SQLEXPRESS;Initial Catalog=TestDb1;Integrated Security=True;Pooling=False;";

            SqlDependency.Stop(connectionString);
            System.Data.SqlClient.SqlDependency.Start(connectionString);
Any one please help onDataChange is triggering only once
 
7:16 AM
You are removing the event handler from the event on the first run
 
again i am calling RegisterNotification()
but in both cases it is not triggering second time after datachange
 
oh I see
Don't know what SqlDependency is so can't help you
 
ok
 
 
4 hours later…
11:09 AM
Hello!
I'm trying to use SQL Server Object Explorer.
I tried to add a "SQL Server"
In that, I am trying to add a MySQL Server.
I set the servername as: 127.0.01:3306
Authentication: Sql Server Authentication
Username: root
I set the password and hit connect.
It doesn't seem to connect. :/
 
 
3 hours later…
1:57 PM
hi guys, I'm dealing with Singleton design pattern and was just wondering whether im doing it ok:
        private static Service service;

        private static object locker = new object();

        static Service()
        {
            lock(locker)
            {
                service = new Service();
            }
        }

        public static Service GetServiceProvider()
        {
            return service;
        }
 
> dealing with singleton [...] wondering whether im doing it ok
no you're not
 
ok...
but why not
 
2:12 PM
 
2:27 PM
thank you
 
2:42 PM
pattern anti-pattern
:p
 
3:38 PM
 
Hi,
I need a guidance, I was asked to create C# tutorial videos, sth similar what Pluralsight offers, do you know how much tutors charge for 1 hour of video? I can't come up with reasonable price : P
I think it might be 20 or more hours long.
I need around 80 hours to finish a course with my student, so I think I can divide it by 3.
Because there is no interaction.
 
3:57 PM
you guys, I just wrote a hello world program in C# and it worked
Hello World!
Build succeeded
 
@kush good job :)
 
@milleniumbug still need to figure out how to actually do anything useful like maybe run unit tests but it is time for a happy dance :P
 
 
3 hours later…
6:46 PM
Hey, I'm looking for information about how to auto register with AutoFac. Most of my services have interfaces that just prefix themselves with I, so that UserService has an interface called IUserService and so on. I don't want to register them all by hand so I'm looking for a handy way to auto register them.
My initial attempt looked like this:

builder
.RegisterAssemblyTypes(assembly)
.AssignableTo<IService>()
.AsImplementedInterfaces()
.InstancePerRequest();

But that didn't work, the docs aren't making me much wiser atm.
 
you want to register the DI components automatically?
6
Q: Autofac register assembly types

Ivan-Mark DebonoIn Castle, I used to do the following to register types from a different assembly: Classes.FromAssemblyNamed("MyServer.DAL") .Where(type => type.Name.EndsWith("Repository")) .WithServiceAllInterfaces() .LifestylePerWebRequest(), In Autofac, I change the above code to this:...

Think the second line needs to be updated - if that answer is correct.
 
@milleniumbug it works! PrimeService.Tests Total: 11, Errors: 0, Failed: 0, Skipped: 0, Time: 0.309s
 
7:03 PM
@kush awesome
 
It is a little funny that the restore and test takes less than two seconds compared to about two minutes to set up the scene. but I think it is literally creating a new docker virtual machine each time in gitlab ci
 
 
2 hours later…
9:31 PM
hi huys
guys*
I was just wondering about having some nested classes inside of static class
 

« first day (2163 days earlier)      last day (2799 days later) »