Loop calculation issue
I`m trying to calculate the output X to do this i have the formula:A *( B / 100) = c C = A (because output x is the answer after loop this formula 5 times)(The formula calculates the Nettovalue of the...
View Articlefor loop to multithread
Hi how can i separate for loop to a specific number of threadprivate void button1_Click(object sender, EventArgs e){// in here separate the loop into multiple threadsThread t = new Thread(job);...
View ArticleExtracting text from html file using indexof and substring not working...
In the top of form1 i did:using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using...
View ArticleHow I can read the text of a div class?
Hello,I'm currently trying to read a div clas... example: <div class="hello">THIS COMES IN THE RICHTEXTBOX</div>How can I "write" this in to a richtextbox?Greetings, Max.
View ArticleHttpListener not kernel caching?
HiI'm trying to write a http proxy server using HttpListener, but it's not caching any results. Is there any setting I have to enable for the (kernel) cache in http.sys, or is this at all possible with...
View ArticleSystem.Threading.Timers callback is 10 seconds late
I have a window service using the following code:private System.Threading.Timer updateTimer; ... public Constructor() { ... this.updateTimer = new System.Threading.Timer(OnUpdateTimerElapsed, null,...
View ArticleDisplay and edit SQL database in Table
Hi!I need to ad a page to a website I am making that has a grid that displays sql data. The table needs to be able to have records added, edited, and deleted upon user request and I used Jtable...
View ArticleOverloading with identical parameters but different type results
The answer is probably no, but it can't hurt asking - is it possible to overload a method to accept same parameters, but return different type results? For example,string[] x =...
View ArticleHow to replace all occurrences of a string with a specified string from rich...
I have a rich text box and want to replace multiple occurrences of a string in a rich text box with a specified string. Currently i am playing with this but nothing is happening with this:...
View ArticleHow to redesign a Forms app to use two different MainForms
I am relatively new to Object Oriented programming. Last year I wrote a standard visual studio C# Windows form app that had a lot of functionality. All code was in the same class (Form1). It included...
View ArticleSame object, different namespace, calling the same function
Hello forum,I cant seem to figure out a more efficient way to do this. I have three classes, same objects, but different namespaces, and I need to map first two classes to the third class which will...
View ArticleWhat does this mean?
public class Man { public string Name; public bool LikesWater; public bool LikesHumans; public Man(){} public Man(string n) { Name = n;} } Man temp1 = new Man(); temp1.Name = "Bo"; temp1.LikesWater =...
View ArticleOpenGL in Microsoft Visual Studio Express 2012(C#)
Hi guys,I was told by my professor that i can write OpenGL codes in my C# program. So now i'm really confused here, cause i thought that OpenGL and C# are totally different.So my question is how do i...
View Articlewhen i pass a "Type", Console.write() prints System.Runtime?
hi friends, I have opened form counting methodint CountOpenedForms(Type f){ Console.Write(f.getType().ToString());}when I pass a Form type, assume my project has a form type called frmProducts,...
View ArticleData not show in gridview from the database
hiPlease Experts Check this programData does not showing in gridvew from database when i am selecting the date in the datetimepicker.Not Working string connstr = @"Server=.\SQLEXPRESS...
View ArticleHow to return the last element in a txt file C#
I have a text file that will basically be something like what is shown below. I would like to return just the last element if the first 2 element matches.$fruit#color#type#smell#qty...
View ArticleServiceContoller is sequential in its RPC calls from a multi-threaded client
Hi, I have a piece of code that makes remote calls to another host to retrieve the status of a number of windows services. Each remote server status check is done with a new ServiceController object on...
View ArticleSome basic questions of Webservices
Hello,This is my first post in MSDN forum and not sure where to post this question. If this is a wrong place, please move it to correct place.Recently, I have faced an Interview for C# developer...
View ArticleI can't get my Task to execute!
New to this so be kind. I have tried to write a Task<> that can be awaited: Task<bool> RenderAsync(string ReportName) { return new Task<bool>(() => { return Render(ReportName); }...
View ArticleNamePipeServerStream and MQL4
Hi everybody.I am trying to use PIPE server and client with 2 diffents language.The server is running ok: Listen("Pipe1")Private _pipeName As String Public Sub Listen(PipeName As String) Try...
View Article