- Strength to Increase Rep
- +4
- Strength to Decrease Rep
- -1
- Upvotes Received
- 12
- Posts with Upvotes
- 9
- Upvoting Members
- 9
- Downvotes Received
- 1
- Posts with Downvotes
- 1
- Downvoting Members
- 1
Re: There's many ways to handle such a situation. Probably when a user log in you connect to the database to check his/her data. In that moment you can just add to the combobox his/her first name, last name and remember in variable his/her UserID (so the field which uniquely identify … | |
Re: Can you be a little bit more specific? What kind of system have you created? Where the database is located (f. ex. on a remote server or you simply have the file with the database)? etc. | |
Hi, As most of you are IT profs probably some of you have access to ISO norms... I'm looking for one particular definition which should be contained in ISO 8000-102:2009 it is definition of data quality... As I need only that one info for my master thesis I'm not willing … | |
Re: [QUOTE]Hey guys[/QUOTE] and girls... ;-P if you want to do that inside of your program the easiest way is probably to use DocumentText property... in that case you get the code of the current page (in string which is convenient in that case; to get html code use Document property) … | |
Re: as InterestedCompany is a class in the student class you have to create the instance of it... preferably create constructor for student class: [CODE] public Student() { this.x = new InterestedCompany(); } [/CODE] or create an instance like that: [CODE] InterestedCompany x = new InterestedCompany(); [/CODE] inside of Student class... … | |
Re: well... I've recently created a bot too but as I needed some fancy features I've created my own class and for proxy support used WebProxy class... there's also other classes to accomplish that (like GlobalProxySelection)... if it comes to webBrowser control as far as I know it does not nativaly … | |
Re: well... I'm not good in that but: 1. create query more or less like that: [CODE] string query = "update tableName set money=" + textbox1.Text.Trim() + "where id=2"; [/CODE] 2. construct connection string... if you do not know how to do that use wizard... to do that select from main … | |
Re: to copy the lines from richtextbox or textbox (with multiline set to true) you can use Lines property: [CODE] string[] lines = textBox1.Lines; foreach (string line in lines) { if (line.Contains("")) rtbResults.Text += line; } [/CODE] if you need some more sophisticated checks on lines probably you will have to … | |
Re: well... to find all the files you can use Directory class and GetFiles(), GetDirectories() method... below I've pasted the code snippet showing how it can be used... it seems to work but I did that in the hurry so you can find there some mistakes... btw I added the comboBox … | |
Re: 1. If you want to do any operations on array of values it does must have some values so fill array with values: [CODE] int[] value = new int[5] { 5, 1, 2, 4, 3 }; [/CODE] you can also give the user the possibility to specify the values: [CODE] … | |
Re: TextBox class has the property ReadOnly... set it to true... you can do that in the properties window or in the code... | |
Re: I've got no time to give you more elaborate example but the following code should give you the idea what to do: [CODE] private void button1_Click(object sender, EventArgs e) { string[] textFromRTB1 = richTextBox1.Lines; string[] textFromRTB2 = richTextBox2.Lines; richTextBox1.Clear(); richTextBox2.Clear(); int linesCount = 0; if (textFromRTB1.Length != textFromRTB2.Length) { linesCount … | |
Re: The exact solution (means an effective one) depends on what you want to do with the data. Sample code: [CODE] private void button4_Click(object sender, EventArgs e) { LinkedList<string> list = new LinkedList<string>(); // path to your file... in my example I placed the file in program directory string path = … | |
Re: You do not know the proper definition of that operator. The syntax: [COLOR="Red"][I]boolean_expression ? expression1 : expression2[/I][/COLOR] Expression is any operation which returns a value. Void is not a value. Void specifies that no value is returned. If your get this message, at least one of your methods, must return … | |
Re: Please, give some more details... What kind of app have you created, how have you created the installer, some information about the machine on which you created the app and about the machines on which you try to run the installer... Also if some messages pop up, what is their … | |
Re: ListBox class does not support editing items in runtime (at least I do not know anything about it ;-P). So you have to handle yourself... As you want to give the user opportunity to change data after double clicking use DoubleClick event of the ListBox class and add in there … | |
Re: Well I would do that in completely different way... probably using regular expressions... but here's the way to count spaces in the provided text: [CODE] static public int spaces(string text) { char[] delimiters = { ' ' }; text = text.Trim(); string[] words = text.Split(delimiters); return words.Length - 1; } … | |
Re: Read() method reads the next (only 1 character) from the standard input so you get ASCII codes of the number... Try that instead: [CODE] nr1 = Convert.ToInt32(Console.ReadLine()); [/CODE] But put it into "try catch"... btw make the fields private... and move temp declaration to InternGhange() function... Sample code after little … | |
Re: It may be a little bit vague but hope it will help you... Firstly you created an instance of the Elephant class: [CODE] Elephant lloyd = new Elephant() { Name = "Lloyd", EarSize = 40 }; [/CODE] so the variable lloyd is now containing the reference to that object. Then … | |
Re: Well I don't know the class TSQLBeginTransactionBlock_Ext so I guess that's your own class. To make a deep copy of the Object in C# you should use Clone method from IClonable. You can also add a constructor to TSQLBeginTransactionBlock_Ext which takes as a parameter a variable of the same type … | |
Re: Sample code: [CODE] StreamReader sr = null; FileStream file = null; string fileData = String.Empty; try { file = new FileStream("test.txt", FileMode.Open, FileAccess.Read); sr = new StreamReader(file, Encoding.UTF8); string outputData = String.Empty; while (true) { string temp = String.Empty; temp = sr.ReadLine(); if (temp != null) { temp = temp.Replace("the", … | |
Hi, I've created a lexer using flex. Now I want this lexer to be used in my C# application. I've tried to do this with code below: [CODE] private void btParse_Click(object sender, EventArgs e) { Process lex = new Process(); StreamWriter sIn = null; StreamReader sOut = null; StreamReader fileReader … | |
Hi, I've got a lexer created with flex (under cygwin). Normally I compile it to an .exe file. For the newest project I need a lexer to use in a bigger C# program running on Windows XP. Of course I can execute a file using System.Diagnostics.Process. But it is not … |