473,775 Members | 2,362 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

C# / C Sharp Forum

1
2,606
thread by: Jon Slaughter | last post Apr 3 '08 by: Ben Voigt [C++ MVP]
Say I have two nested foreach loops, is there any simple way of continuing out of the outter most loop depending on what happens in the inner most? e.g., foreach(int i in I) { foreach(int j in J) if (j == 3) break.continue;
2
4,003
thread by: =?Utf-8?B?RGF2aWQ=?= | last post Apr 3 '08 by: =?Utf-8?B?RGF2aWQ=?=
Is there a C# equivalent to getsockname? Or, what is the C# way of getting the port a socket is bound to if you allow windows to pick the port for you? -- Best Regards "Failure is the opportunity to begin again more intelligently" – Henry Ford
0
2,493
thread by: Peted | last post Apr 3 '08 by: Peted
Hello, Ive got a datagridview, on a splitcontainer, in a system.windows.forms.usercontrol. The datagrid view by default shows 3 colums of data and fills exactly the size of the user control form. This control is then called from another c# solution, and it displays fine when called and shown.
2
1,245
thread by: Ramesh | last post Apr 3 '08 by: Ramesh
hi friends, I am ramesh from chennai, INDIA. working as s/w eng(ASP.NET) also new to this group. happy to join with group members. Now i want to know what are the latest versions of the followings 1. Visual Studio .NET 2.Net Framework 3.C#
0
913
thread by: Ryan Liu | last post Apr 3 '08 by: Ryan Liu
I have an application runs fine on .NET 1.1 and throws exception in .NET 2.0 IList dataSrc = (IList)dataGrid.DataSource.GetList(); int t = dataSrc.Count; for (int i = 0; i < t; i++) { bool isSelect = this.dataGrid.IsSelected(i); //this line throws
0
1,948
thread by: Fre | last post Apr 2 '08 by: Fre
Hi all, On a Windows Form I have a TabControl and a ContextMenuStrip. Now I'm trying to get the ContextMenuStrip only to be shown when right clicked on the HEADER of the current TabPage (the TAB as I call it). Any ideas (detecting the right clicking is not the problem of course, but my context menu shows up on every location of the TabPage,...
10
2,966
thread by: parez | last post Apr 2 '08 by: Ben Voigt [C++ MVP]
Hi, I have implemented a static event. Is there anything special that i have do? Is thread safety an issue?
0
2,803
thread by: =?Utf-8?B?Q2xhdWRl?= | last post Apr 2 '08 by: =?Utf-8?B?Q2xhdWRl?=
It is possible to capture the "AddingNew" event to create our own object before it is append to the BindingList (using e.NewObject = new ...) When the user press delete on a row to remove a row from the DataGridView, I need to do some stuff before it actualy modify the content of the BindingList. Is it possible ? I tried to capture...
5
14,782
thread by: TheSteph | last post Apr 2 '08 by: Ignacio Machin ( .NET/ C# MVP )
Using : MS-SQL 2005 / .NET 2.0 / VS2005 I have two server with the same database def but different data. I would like to import data from Server2.TableA to Server1.TableA. If a row doesn't exists on Server1.TableA, it should be added; if the data already exists it should be updated. I have to write a C# application do this operation on...
1
292
thread by: =?Utf-8?B?Q2hyaXN0aWFuIEhhdmVs?= | last post Apr 2 '08 by: sloan
Hi, if in a client-server application the server has to deal with about 1.000 clients is .NET Remoting (RPC) the right choice of the communication or is a message oriented communication (e.g. MSMQ) the better choice? Christian
4
337
thread by: AMP | last post Apr 2 '08 by: =?Utf-8?B?S0g=?=
Hello, I have a Regex: Regex regex = new Regex(@"22 22 22 22 22 22 22 22 22 22(? <centervalue>.+)33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33 33"); Sometimes my data has 10 sets of "22"'s , sometimes 12, 14 ,ect. I want the centervalue to start after ALL of the "22"'s but this is...
5
1,142
thread by: =?Utf-8?B?cmF1bGF2aQ==?= | last post Apr 2 '08 by: =?Utf-8?B?cmF1bGF2aQ==?=
hi all: any one can give me a link where to post questions about the vs 2005 ide? thanks I got one of my panels "Pending Checkins" under view toolbar not to open when I start my IDE, all the others are openning fine, (we use co-op for version control)
1
1,301
thread by: thomasnguyencom | last post Apr 2 '08 by: =?Utf-8?B?UGV0ZXIgQnJvbWJlcmcgW0MjIE1WUF0=?=
What's the best way to handle this situation securely? I'm currently manually converting the string to a SecureString, but for some reason it looks ugly. public SecureString ConvertToSecureString (string str) { SecureString secureString = new SecureString(); foreach (char c in str) {
0
987
thread by: Ryan Liu | last post Apr 2 '08 by: Ryan Liu
Hi, For NetworkStream, what is difference between ReadByte() return -1 indicates "end of stream" and DataAvailable = false? Thanks a lot!
1
1,622
thread by: Steve | last post Apr 2 '08 by: sloan
If I have the following code, what do I have to change to make it return more than one value? public string Records { get { return textBoxName.Text; } //return textBoxAddress.Text; //return textBoxNotes.Text; }
2
3,932
thread by: =?Utf-8?B?RmVybmFuZG8gUmlvcw==?= | last post Apr 2 '08 by: Ignacio Machin ( .NET/ C# MVP )
Hi, I'm a rookie about C# and im starting developing some Basic Console Aplications, but i was just wondering if there's a way to center a message when using the "Console.WriteLine("");" command, lets say i want the message to appear centered when running the program. Thank you so much! ;)
5
4,991
thread by: =?Utf-8?B?UGVy?= | last post Apr 2 '08 by: CSharper
I want to change the current path in the OpenFileDialog in runtime. When the user presses OK-button I'm checking the selected path if it's valid for my application. If it's not valid I want to set the path to a valid one in the FileOk-event and set the e.Cancel = true.
2
1,203
thread by: CSharper | last post Apr 2 '08 by: CSharper
I am trying to find a first element from an xml file using the following code XElement t = xml.Descendants("Element").First(); This works fine, but when there is no result set ofcourse the first method call bombs. I can always split the statement into two and check if there are any elements available before I pick the first element. Is it...
5
2,544
thread by: =?Utf-8?B?cm9kY2hhcg==?= | last post Apr 2 '08 by: =?Utf-8?B?cm9kY2hhcg==?=
hey all, i've added a dropdownlist object into tableCell td in my code further down the code i inspect the td.Controls and i can see the the dropdownlist bright as day. however, when i try to do td.FindControl('id') it returns null? any ideas off the top why this may be?
0
958
thread by: izurewakaru | last post Apr 2 '08 by: izurewakaru
For only fetish maniacs. Here is a free sample movie from musha-burui.com http://rapidshare.com/files/102726682/Lactating05.rar http://rapidshare.com/files/102101127/lactating003.rar by
1
2,779
thread by: jitendrapatil2006 | last post Apr 2 '08 by: Marc Gravell
hey friends i am new to C# lang. can anybody tell me how to add arrays to Ilist and how to get the values from the list( means) how to traverse the list plz help me...
6
1,539
thread by: Piero | last post Apr 2 '08 by: Marc Gravell
Hi, i have a string array, how can i convert it to a string?
4
1,607
thread by: =?Utf-8?B?U2hhcm9u?= | last post Apr 2 '08 by: =?Utf-8?B?U2hhcm9u?=
How can I read the version of an existing file? The file I checking is a COM dll file. ------- Thanks Sharon
5
1,699
thread by: Jon Slaughter | last post Apr 2 '08 by: Marc Gravell
Is there a way to collectively get the internal data for primitive types? So for Int32, SByte, etc, I want to be able to get the byte stream used for the data. The reason is that I want a byte stream of the values but I don't want to convert each one by hand(I started but its getting messy). For, since double is a 64-bit type I'd like to...
1
1,296
thread by: Claire | last post Apr 2 '08 by: Claire
Hi, either I'm going mad or is params not working anymore in VS 2005? I have function as follows public tableEquipment ReadEquipment(bool ReadImages, params Int64 RecIDs) { } if I call "tableEquipment equipment = myDatabase.ReadEquipment(false, RecID);"

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.