2537 1
Error : Wrong number of indexes '2' inside [], expected '1' Compilation failed in C# 2-D array

Hi, I am trying to run the below C# code for martix, but getting error

...
Type
Question
2536 2
How to insert C# variable value in between string properly?

Hello, I am trying to pass this string from back-end C# to front end, and want to render it as HTML, when passing this string to the front-end, it doesn't look proper, here is my current C# code.

...
Type
Question
2366 0
Understanding Delegates in C# with examples (with Multicast delegate)
This article will help you explain what are the delegates in C# with the example, its advantages and when we should use delegates.
Type
Article
2339 0
Show elapsed time of item using C#, SQL & jQuery (Updating elapsed time of item dynamically using jQuery)
This article shows you, how you to get date difference from database in C# and update elapsed time dynamically using jQuery
Type
Article
2321 2
Compare System Time with database time only (not datetime)

I need to compare a time in a table with the current system time and need to pop up a notification. But how can I compare both? here is my code and DB:

...
Type
Question


2296 1
How to resolve Class, struct, or interface method must have a return type?

C# error, when trying to execute the code as below

...
Type
Question
2168 0
Transfer e-mails from one exchange server to another using EWS Api in C# .NET
Transfer e-mails from one exchange server to another using EWS Api in C# .net MVC
Type
Article
2136 2
Getting error "Sequence contains no elements"

Hello, I am using the below code to fetch some data from database and getting the error "Sequence contains no elements"

 public static IEnumerable<CompanyLicenseKey> GetCompanyLicenseKey()
{
            OPEntities onepassDB = new OPEntities();

            //Let's get the onepass User model first
            var user = onepassDB.UserAccounts.Where(x => x.Email == OnePassUserAccountEmail).First(); //error in this line

            var userLicenseList = from c in user.CompanyProfiles
                                  join l in onepassDB.CompanyLicenseKeys.Where(x => x.IsDisabled == false)
                                  .Select(x => new { x.CRMID, x.LicenseKey, x.FriendlyName, x.ProductName })
                                  on new { c.CRMID } equals new { l.CRMID }
                                  select new Models.OnePass.CompanyLicenseKey { LicenseKey = l.LicenseKey, FriendlyName = l.FriendlyName, ProductName = l.ProductName };

            if (ProductName == "")
                return userLicenseList.ToList().OrderBy(x => x.FriendlyName);
            else
                return userLicenseList.Where(x => x.ProductName == ProductName).ToList().OrderBy(x => x.FriendlyName);
        }

Error image

...

Type
Question
2092 0
MVC List box using jQuery getJSON and JSONResult
This article shows how you can populate MVC Listbox using jQuery and JSONResult.
Type
Article
2075 0
How to read and write in Console app using C#?
In this article, I have explained how to read and write in C# console applications using Console.ReadLine(), Console.WriteLine() methods in C# for basic, input and output using Console.
Type
Article

Page 10 of 16