4,588 Topics

Member Avatar for
Member Avatar for Realitiez

i'm trying to create a program that calculates Body mass index in a for loop with 5kg gaps. BMI formula is: weight(kg)/height(meters squared) = BMI. How would this work? this is the code i got so far: Console.Write("Write your height in meters: "); double t1 = double.Parse(Console.ReadLine()); Console.Clear(); Console.Write("Write starting …

Member Avatar for Rawand_2
0
2K
Member Avatar for complete

This is using C# coded using Microsoft Visual Studio 2019 Professional I have an XML file used as a configuration in my program that I am coding. The executable reads and writes to the XML file. So I would naturally like to have an automatic process where the XML file …

Member Avatar for pritaeas
0
49
Member Avatar for complete

How do I set a system-wide _ifdef? This is using Microsoft Visual Stuedio version 2019 with C#. If I want to add specialized code to a project shared by multiple software developers that is designed for my selfish tests and evaluation, how do I manage a # definition inside the …

Member Avatar for rproffitt
0
48
Member Avatar for Clif40RD

Hi I have a `.Net Core Blazor` server project and I'm making use of the Repository pattern for data access. Initially, I had registered the repository as a scoped service. While testing I noticed that if I quickly switched pages for e.g. by clicking on the navigation menu, while the …

Member Avatar for rproffitt
0
204
Member Avatar for complete

In a C# solution, how do I add an .EXE project to a solution of DLL project's? This is using Microsoft Visual Studio Professional. I have been handed a solution file which contains three projects. But all three projects generate DLL files. It is kind of unique because I have …

Member Avatar for tinstaafl
0
168
Member Avatar for kim_boto

I have a Datagridview with two columns. First one is Marks of the student and second one is grade. When I enter marks in Datagridview I want the grade column to automatically fill the respective grading system value. Greater than 80 - A Greater than 60 - B Less than …

Member Avatar for rproffitt
0
107
Member Avatar for complete

I am starting a new coding job with a new client. The problem I am having is that a lot of issues with namespaces that can not be found or maybe missing directives or an assembly reference. This, I think, is a common thing. So I am wondering where I …

Member Avatar for rproffitt
0
59
Member Avatar for Adm666

I'm trying to authenticate to Sharepoint site i've made (it has a list with 2 items in it), i need to print its title to the console - really simple approach. with OfficeDevPnp.Core Nuget installed i tried the AppOnly following code: public static void AppOnlyAuthCall() { using (var clientContext = …

Member Avatar for pritaeas
0
69
Member Avatar for TimTheCoder

Am trying to implement face detection using the PCA algorithm in C#,I have a button on my windows forms that is supposed to intitiate the learning process once it is clicked. It should use the images in a folder called training to compute the eigen values and eigen vectors so …

Member Avatar for rproffitt
0
83
Member Avatar for imso

The alarm clock application works by setting a certain time and then it perform a certain task eg:sound an alarm, display a messagebox test message. But the problem comes where i need to snooze(delay) the alarm clock for a certain time period like 10 second... Then it will re-initialise the …

Member Avatar for Konevlad21
-1
1K
Member Avatar for Adm666

i made a little crm app that has the Entities : Contact, Campus, Sub Campus, the contact has lookup fields for campus and sub campus. (each sub campus is related to only one campus) im supposed to make a plugin in C# that on contact creation it fills the campus …

Member Avatar for rproffitt
0
144
Member Avatar for nalb4242

Hello , mu website objective is to some kind of reposrts the problem when i retrive for example the people in my dtabase under specific age the grid view does not show me all of them i have googled this problem and i found that it can not retrive more …

Member Avatar for pritaeas
0
34
Member Avatar for nalb4242

Hello , i am creating new website using asp net and c# .. what i am basically doing is that i have somedata in my database and will let the user show them in report based on what he is gonna choose to display for example i have in my …

1
92
Member Avatar for kamilacbe

Hi, I'm trying to desirealise the json data from a external file where i want to read the key and fetch another dictionary value based on key please letme know if i can read dictionary inside dictionary , I have tried using DIctionary<string,object> where as am looking for Dictionary <string,Dictionary<string,string>> …

Member Avatar for pritaeas
0
110
Member Avatar for Onion13

Making a scrolling space shooting video game in C# where the player will fight one on one with their opponent. I was able to figure out how to make the missile go up if the opponent was above the player. But, I can't seem to make it work if the …

Member Avatar for tinstaafl
1
284
Member Avatar for Catharina

Hi. I have a question. So, I'm registering a user, but a table is created for me (empty), and I can't figure out how to save my data when registering in the database? I tried to write various functions, but I failed. Below I send the code: Users.cs: using Microsoft.AspNetCore.Mvc; …

Member Avatar for rproffitt
0
85
Member Avatar for Prudence_1

1.2 Convert the following classes to valid C# classes: SemiDiode + ForwardV {get; set; }: Double +ReverseV (get; set; }: Double +BreakdownV {get, set; }: Double + Semi Diode) + SemiDiode(forwardV: Double, reverseV: Double, breakdownV: Double) +ToString(): String Laser LED wavelength: Int32 -color: String +Wavelength {get; set; } : Int32 …

Member Avatar for Schol-R-LEA
0
995
Member Avatar for Catharina

How can I save the registration data after connecting to the database (an empty table is created for me)? I do this in Blazor (C #). User.cs: [Table("Users")] public class User { [Display(AutoGenerateField = false)] public int UserId { get; set; } [Display(Name = "UserName")] [Required(ErrorMessage = "UserName is required.")] …

0
86
Member Avatar for Onion13

I kind of figured out how to put a pause in my 2d game when the player shoots. The problem is that when the player shoots once, the game will continue to shoot continously, even after the player has stopped shooting. Can someone please help me? void Bullet()//draws the players …

Member Avatar for Onion13
0
200
Member Avatar for MagnusTheRed90

Hello, so I have a more complex class in another file, but I have duplicated my trouble on a simpler class which I will show to you. I am trying to base64 encode a path via cipher text, either a good idea or a bad idea. Anyway, I am noticing …

Member Avatar for JamesCherrill
0
85
Member Avatar for questionpond

Created a stored procedure as REST web service and return values as 1 and how to consume in Client applciation in c#. please help me how to send parameters through HTTP POST uisng HTTP client .

Member Avatar for rproffitt
0
49
Member Avatar for Onion13

Working on a game and I made a separate class to handle the players enemies (Its a scrolling type 90s game). I know if I use picturebox and put it on form1 I can say for example.... enemy1.Left > 90; My question is how would I do something like that …

Member Avatar for rproffitt
0
401
Member Avatar for nalb4242

Hello i have question i am new at using aspx and c# .. after i get my website from server using FTP i can access the aspx page only but i can not view the code of c# behind it .. i think they are saved in bin file but …

Member Avatar for Schol-R-LEA
0
72
Member Avatar for Onion13

Would someone explain to me how to use bitmap. I have a video game I am working on so I added images using resourcesrx and wanted to use bitmap to display where they will appear on form1. I saved the image as player.

Member Avatar for rproffitt
0
40
Member Avatar for Onion13

Made progress on my game and now I need to make the second boss bounce up and down. I figured out how to make the boss go down, but once it touches the lower wall, it stops and won't bounce (move up). void BossMove() { if((BOSS.Top + 10) <(this.Height - …

Member Avatar for rproffitt
0
59
Member Avatar for TimTheCoder

Am working on a decipher algorithm that is supposed to take a string input of en english sentence flipped backwards and contains numbers, spaces and delimiters. I got code that removes numbers and special characters but also removes spaces, Can you help me tell this code to not bully the …

Member Avatar for rproffitt
0
26
Member Avatar for Aldrich_2

I have a variable called **arrayForStudents**. it has 5 columns you can see how should it be applied from line 51 to line 63 code block but I am getting trouble how should I add the value as simple as interting values in the database. I need help using System; …

Member Avatar for rproffitt
0
90
Member Avatar for TheMightySpud

Hi all, I'm getting a strange error every time I try to send a score update using an rpc using Photon Unity Networking (And Unity3d). Here is the Error. RPC method 'RPC_SendScore(String, Single)' found 2x on object with PhotonView 1201. Only one component should implement it.Return type must be void …

Member Avatar for rproffitt
0
1K
Member Avatar for Johnny2x4

I need to know if there's a way (my intution tells me there isn't a fits-all solution) to accomplish this. I have in mind a Unity asset that I want to create. This asset requires that all of the developers scripts send and receive messages from my asset framework. Its …

Member Avatar for Dani
0
20
Member Avatar for Yumensh

The code: using Discord; using Discord.Commands; using Discord.WebSocket; using NadekoBot.Common.Attributes; using NadekoBot.Core.Services; using NadekoBot.Extensions; using NadekoBot.Modules.CustomReactions.Services; using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; namespace NadekoBot.Modules.CustomReactions { public class CustomReactions : NadekoTopLevelModule<CustomReactionsService> { private readonly IBotCredentials _creds; private readonly DbService _db; private readonly DiscordSocketClient _client; public CustomReactions(IBotCredentials creds, DbService db, DiscordSocketClient client) …

Member Avatar for rproffitt
0
80

The End.