|
I need to be able to get and parse a specific line from a richTextBox. I know you can get all the text from the box, or substrings if you know the start and end index, but I can not find a way to get just one line by using the line index. Does anyone know how to do this? I would appreciate any input you have. Thanks!
|
|
|
|
|
|
I am looking to find out how to add text from a file to a database. I am using the Split() method, and adding the text to a string array. How would I go about adding this text into a DB....into different columns?
|
|
|
|
|
May this help ? :
for(int i=0;i<myArray.Length;i++)<br />
{<br />
DataRow r = mydataSet.Tables[0].NewRow();<br />
r[Your index] = myArray[i];<br />
meDataSet.Tables[0].Rows.Add(r);<br />
}
.
|
|
|
|
|
Thanks for the reply! I am not sure what you are referencing on this line:
r[Your index]?
|
|
|
|
|
The index of the column you are tring to put this value in ,or just it's name just like :
r[3]
r["SplittedString"] .
|
|
|
|
|
I see exactly what you are saying. Let me give you some more detail though. I have created an app that will inventory computer information. It will write this info to a data file using a ; as a delimiter. This is where I get my SplitString. In this text file, one line will represent one computer, so I want to try and add the infomation of that one line into a DB row with Columns that have already been specified.
I am very close to figuring this out, but any help would be appreciated!
|
|
|
|
|
I just came from VB.NET to C# and in VB when ur in the programing window and you click the members box it displays all the events of a form or listbox ect.... it does not do this in C# though is there a way I can fix this?
thanks
|
|
|
|
|
|
Hi,
I've found the decimal code for the languages for a set of exe packages. All i need now is to from this code, i need to get the particular language. How am i to do this in C#?
|
|
|
|
|
|
yeah decimal code for eg if i supply 1033 means it should return English-UnitedStates similarly if i give any code sort of like that, it should return the language. how to do this ?
an elaborate way i did is by switch case. but i want a crisp way of doing this.
forget abt the exe packages.
|
|
|
|
|
A Hashtable (or Dictionary<int, string=""> if you're using 2.0 beta) is the way to go; put all the possible number codes in the dictionary as keys, with their corresponding language strings as values.
hashtable.Add(1033, "English-US");
That way, when you go to retrieve a language name based off the code for that language, you can use:
string languageName = (string)hashtable[1033];
Tech, life, family, faith: Give me a visit.
I'm currently blogging about: The Secular Left, the Religious Right, and Prejudice
Judah Himango
|
|
|
|
|
Guys.
I am a Java dev who is needing to jump into c# space for a while and I was wondering if someone could point me in the correct direction.
I am needing to write a small Pocket PC application which plays one track of music but will occasionally overlay another track ontop of it.
Can anyone out there point me to an example as I have not been able to find one.
Thanks for the help
Ant
|
|
|
|
|
First, what are your requirements? .wav files, mp3 files, wma files? You'll need some library that can play these. The current .NET framework library does not contain audio playing classes (although the .NET 2.0 beta does).
Once you know what kind of files you want to play, you'll need libraries that run on a PocketPC that can play those files.
Tech, life, family, faith: Give me a visit.
I'm currently blogging about: The Secular Left, the Religious Right, and Prejudice
Judah Himango
|
|
|
|
|
I'm developing a program to monitor labor efficiency within my company on different products that we build. The user is able to select the product in a drop down list and then I want them to be able to print the data to a chart (labor efficiency over time). I'm storing my data on a SQL database and have created individual tables for each product. I want to setup a single chart in Crystal Reports that I can take my efficiency column and date column from the product table selected by the user and display that data. I've attempted to create this chart (my first CR experience and my first C# project) through the reports wizard, but I had to select one specific table to pull the data from instead of having the choice of selecting all the tables, and I'm not sure how, or if, I can get around this. Am I going about this the easiest and most efficient way? And does CR have the ability to do this or do I have to build the chart dynamically to get the results I'm looking for? Thanks.
|
|
|
|
|
Hi,
Excuse me for my english please.
1.My class has a readOnly property wich could be initialized by the constructor. I have MyClassConverter to customize property of this type at design-time. Evrything works ok.
But when my class becomes a component all of it properties are not accessible at design-time they are readOnly.
2.My class has a delegate type property and I need to customize it at design time too. It is possible to do it using event. But I think that there sre some methods to init it directly as delegste.
I found a lot of articles here about runTime component readOnly properties customization but didn't find anything about design time.
|
|
|
|
|
Hi!
i have c sourcecode like this
int r = 125;
if (!r) {
...
}
in c# r is a integer and not a boolean value. would it be correct to replace
if (!r) {
}
by
if (r<1) {
...
}
|
|
|
|
|
|
Hi,
if r remains always greater than 1,then this may yield u a temporary solution.
if not the above mentioned case......then in C# ,,,the expression inside if ..must be a boolean value..
if( bool )
{
}
With regards
Vinayaka shenoy
|
|
|
|
|
I create a registry key when i run at the first time my application (not during the installation).
I would set some parameter to the unistallation process that allow to delete that key or another key created by another software.
How?
Tnx.
|
|
|
|
|
Hi,
I came across an open source site quite sometime ago that was developing a zip compression util for packaging your application in. The idea was to have all but one of your binary files in the zipped up package and the exe that started the application would unzip the package before starting the main app...
I've tried googling it and searching on some old stuff on the PC but ca't for the life of me remember who, where or what the system was called!
Has anyone heard of such a thing?
Cheers,
John'o
|
|
|
|
|
7zip?
InnoSetup is a good open source installer too.
|
|
|
|
|
Are the Xceed and Nevron charts for .NET the same thing?
|
|
|
|
|
Hi,
I have the following code,
Form MDIChild = new Form1();
mdiChild.MdiParent = this; not sure what this does
MDIChild.Show();
When i run the code with line 2 it gives me the error message "namespace mdichild can not be found"
However if i comment out line 2,it works fine. I am not sure what line 2 does. Please can someone explain,and also explain how i should fix this.
Thanks
|
|
|
|