[Solved] User Control Background Hides Children Controls

The Margin properties on the controls set themselves when dropped on the design surface. This feature may be needed if adjusting items on a Canvas but are mostly an annoyance when dealing with most Xaml control placement. Remove the Margin properties to see the controls in their correct location on the grid. solved User Control … Read more

[Solved] Print non repeating combinations [closed]

Interesting task. Try following code: List<string> list = Enumerable.Range(1, 6).Select(e => ((char)(‘A’ + e – 1)).ToString()).ToList(); List<string> temp = new List<string>(); int count = list.Count; int total = 1 << list.Count; for (int i = 0; i < total; i++) { int k = i; temp.Clear(); for (int j = 0; j < count; j++) … Read more

[Solved] Replacing the goto Statement

Please let me know if I missed something #include “stdafx.h” #include <iostream> using namespace std; void Print(int count, int countSub, int rolePerGroup, int userCount, int userPerGroup) { for(int roleCount = 1; roleCount<=rolePerGroup; roleCount ++) { if(userPerGroup == 0) { cout<<“Parent groups are: “<< count <<” | “<<“Sub group are : “<<countSub<<” | “<<“Role per Sub … Read more

[Solved] Parental control or web filter with c# [closed]

I’d say you’d probably be looking at setting up a proxy on your local network, pointing the machines you want parental control on to that proxy, and filtering the “allowed” traffic by either: Checking website address against a predefined blocklist, and/or Reading through the HTML looking for naughty words or phrases. How to create a … Read more

[Solved] Replacing the .ToString() Method C#

Converting an object to a string will always implicitly call the ToString method, you cannot choose a different method. Implement your ToString method to return “true” or “false”: class YourClass { public override string ToString() { return “true”; // or return “false”; depending on your needs. } } You can call another method explicitly though: … Read more

[Solved] both are char but i get, invalid conversion from `char’ to `char*’ [closed]

Not only are you confusing the order or parametres in strcpy (it’s destination, then source, so strcpy(xstring, animalsarray[j][0]); would have it’s parametres inverted), you’re confusing a char with a pointer-to-char. xstring is a char, and you’re trying to use it as a string. If you want to set all the elements of the array to … Read more

[Solved] Convert SQL into LINQ and Lambda

Maybe something like this: var result= ( from s in db.Stands join cp in db.ContractProducts on s.Id equals cp.StandId join p in db.Products on cp.ProductId equals p.Id where s.EventId == 1 group p by p.Description into g select new { Description=g.Key, TotalArea = g.Sum (x =>x.TotalArea) } ).ToList(); Where db is the linqdatacontext 1 solved … Read more