| Abstract classes and interfaces, what the difference? (4 replies) |
| microsoft.public.dotnet.languages.csharp |
| I cannot tell. Can someone tell me? TIA Tony |
|
| VersionInfo (2 replies) |
| microsoft.public.dotnet.languages.csharp |
| How can I translate this in C#? ffi is of tipe VS FIXEDFILEINFO. I want to get lpdwVersion if (lpbBuffer NULL) return FALSE; if (GetFileVersionInfo(lpszFileName, NULL, dwSize, lpbBuffer) FALSE) return FALSE; if (VerQueryValue(lpbBuffer, "\\", (LPVOID *) &ffi, (PUINT) &dwSize) FALSE) return FALSE; *lpdwVersion ((HIWORD(ffi dwProductVersionMS) & 0xFF) 24) | ((LOWORD(ffi dwProductVersionMS) & 0xFF) 1... |
|
| Access Array with Enumerators (2 replies) |
| microsoft.public.dotnet.languages.csharp |
| Howdy, I am trying to create a int array and access it's members via a simple enumeration. Code: private int[] FormSizing new int[3]; private enum SizePart {FormBottom, ButtonPanel, FormSide}; FormSizing[SizePart.FormBottom] ... Gives the error: Cannot implicitly convert type 'Acupro.frmReports.SizePart' to 'int' I know I can type cast into an int, like so: FormSizing[(int) SizePart.FormBottom] ..... |
|
| On Error Resume Next (8 replies) |
| microsoft.public.dotnet.languages.csharp |
| Is there something comparable in C#? Thanks, Brandon Brandon J. Gross Accenture C&HT(Communications and High Tech) IM: bjgross@yahoo.com Email: brandon.j.gross@accenture.com Email: v bgross@microsoft.com |
|
| SHDocVw - IE OLE - Web Browser (3 replies) |
| microsoft.public.dotnet.languages.csharp |
| How'dy! In VB I used SHDocVw, an Internet Explorer OCX, to put a web browser in my apps; and it worked great. But I'm having trouble now that I've moved to C#. Previously in VB I could simply call: webMain.Navigate "http://www.microsoft.com" But in C# it wants all the parameters: webMain.Navigate(string uRL, ref object flags, ref object targetFrameName, ref object postData, ref object headers); I ... |
|
| Is TcpClient is async or sync? (2 replies) |
| microsoft.public.dotnet.languages.csharp |
| Or can I set the flag?? |
|
| manually moving a variable value into field on d-grid (5 replies) |
| microsoft.public.dotnet.languages.csharp |
| Anyone know how to put a string into a datagrid 'textbox', or 'label' field for a particular row in a datagrid? The scenario would be, say, a user clicks a button. In that event, we do some function like this: myDatagrid.SelectedItem.FindControl("some field") "test"; Of course the above syntax doesn't work... Anyone with any script they can post? (I tried the asp ng for a couple days but nobody kn... |
|
| Hashtables (2 replies) |
| microsoft.public.dotnet.languages.csharp |
| G'dya, Would someone please be so kind as to tell me what it is about the following code (from the documentation, no less) that causes an error? Code: Hashtable myHT new Hashtable(); myHT.Add( "one", "The" ); myHT.Add( "two", "quick" ); myHT.Add( "three", "brown" ); myHT.Add( "four", "fox" ); Error: hash.cs(19,16): error CS1519: Invalid token '(' in class, struct, or interface member declaration .... |
|
| Critique wanted on string handling (8 replies) |
| microsoft.public.dotnet.languages.csharp |
| I thought String.Split() skipped leading and consecutive delimiters but it doesn't. I wrote a version which does so a la strtok() of string.h Comments: 1) Is this the most efficient way? Do methods which return result as an array of N elements usually build array first as an ArrayList then make Array from ArrayList so that Array.Length will have correct number of elements. I'm parsing text files a... |
|
| A Design Question (Situation) - Forms Instantiation (3 replies) |
| microsoft.public.dotnet.languages.csharp |
| It looks like I am up against a wall. I would like to write a Class that would have mostly static variables and methods and would track opened and closed forms using an ArrayList. I am thinking that this class would have a method to instantiate the form and another method to Show() the form. Then, when a module in the application needed to open a foum, it would call, for example, FormMgr.Init( str... |
|
| Create Class Instance from the Class Name (as a String)? (4 replies) |
| microsoft.public.dotnet.languages.csharp |
| This should be simple, but I am still stuck. Given a method that is passed a string containing a valid name of a Forms Class within the current Project, how can one create an instance of that Class? In other words, first obtain the Type of the class and then use the Type with CreateInstance( Type ) to instantiate the class. I have tried the following in an effort to obtain the Type, but with no su... |
|
| c# function to access a field when no row in grid is selected? (3 replies) |
| microsoft.public.dotnet.languages.csharp |
| I KNOW that I want row 3 in the datagrid to be populated with 'xyz' in columnA. I can't use SelectedItem because that assumes that you're in gridCmdHandler and know what the user clicked. But if I'm in a button event, how would I do it....! ie this fails. Anyone have any syntax that would work?: (TextBox)myDatagrid.SelectedItem.FindControl("columnA") "xyz"; Thanks in advance |
|
| Thread communications (6 replies) |
| microsoft.public.dotnet.languages.csharp |
| This is my source Socket t new Socket(.... LocalDataStoreSlot g Thread.AllocateNamedDataSlot("data"); Thread v new Thread(new ThreadStart(clientRoutine)); Thread.SetData(g,t); v.Start(); static void clientRoutine(){ LocalDataStoreSlot g Thread.GetNamedDataSlot("data"); TcpClient c (TcpClient)Thread.GetData(g); // returns NULL !!!!!!!!!!!! Thread.FreeNamedDataSlot("data"); .... } Am I doing somethi... |
|
| advantage of placeholder? (7 replies) |
| microsoft.public.dotnet.languages.csharp |
| hey guys and gals, I'm new to C# and am wondering what the advantage of using placeholders (represented in the following code by {0}) int age 25; Console.WriteLine("You age is {0}!", age); Thanks in advance. |
|
| C# equivalent (5 replies) |
| microsoft.public.dotnet.languages.csharp |
| can anybody tell me what is the C# equivalent to this vb6 statement Me.Left GetSetting(App.Title, "Settings", "MainLeft", 1000) |
|
| CreateObject (4 replies) |
| microsoft.public.dotnet.languages.csharp |
| I have following code that works in VB but not in C#. I am wondering if this has anything to do with Object declaration. Here is the Code: // Object oImgEdit Server.CreateObject ("ImgeditLibCtl.ImgEdit"); object oImgEdit Server.CreateObject ("Imaging.Application"); oImgEdit.ImagingToolBarVisible 0; But I Keep getting the error : " Compiler Error Message: CS0117: 'object' does not contain a definit... |
|
| Getting Server.Execute to work... (3 replies) |
| microsoft.public.dotnet.languages.csharp |
| Hi, I've written a c# ihttphandler, and it works fine when outputting text for test purposes. But now, I want to convert the test into a live application, and placed a context.server.execute command within ProcessRequest. This compiles, but produces an error at runtime; can somebody please tell me how to make this work? N.B. The file I am trying to server.execute contains only a Response.Write sta... |
|
| manifest file (4 replies) |
| microsoft.public.dotnet.languages.csharp |
| okay i have the following question... i have done some searching (far AND wide) on how to get my c# app (using VS.NET RC1 and XP RC1) to use comctl6 (to get those nifty winXP style controls... what i found was to create a "manifest" XML file (code segment 1) then add this line to the programs resource file CREATEPROCESS MANIFEST RESOURCE ID RT MANIFEST "Application.exe.manifest" which resource fil... |
|
| why not nesed Xml Serialization (2 replies) |
| microsoft.public.dotnet.languages.csharp |
| Hello All, Is it true that we can serialize an object in xml which has only simple data types like int, bool etc. what if I have an object that contains other objects ... can I / how do I serialize such an object in Xml. regards, Abhishek. |
|
| Convert function? (5 replies) |
| microsoft.public.dotnet.languages.csharp |
| I would like to convert integer value to binary value. For example... number 13 will be converted to 1101. I can't find how to convert into binary number in C#. |
|
| MDI Form (repeat) (6 replies) |
| microsoft.public.dotnet.languages.csharp |
| hello all and happy holidays I have a mdi form with three different child forms i.e frmMain (MDI parent) frmTree (child) frmTool (child) frmProp (child) each form has different controls . I would like to position (x,y coor) frmTool @ 0,0 frmTree @ 0,300 frmProp @ 0, 600 how can I do this ? thanks |
|
| Play WAV (7 replies) |
| microsoft.public.dotnet.languages.csharp |
| How do I access the multimedia layer and play a WAV file? Can WAV files be stored in a resource file (if so how and how do I access it)? Thanks! Noah Coad |
|
| How to use 'ArrayList.Sort(IComparer)' ? (4 replies) |
| microsoft.public.dotnet.languages.csharp |
| Hi Who has a simple sample which shows the use of 'ArrayList.Sort(IComparer)' ? How should the code of Sort(IComparer) be ? TIA p |
|
| How do I clear screen in - Console Window (5 replies) |
| microsoft.public.dotnet.languages.csharp |
| Does anyone know how to clear the screen, in a Console Window? |
|
| Substring Help! (9 replies) |
| microsoft.public.dotnet.languages.csharp |
| I have a method that uses substring in this manner: num.Substring((num.Length i) 1, num.Length 1) problem occurs when it hits this line of code it errors out with this An unhandled exception of type 'System.ArgumentOutOfRangeException' occurred in mscorlib.dll Additional information: Index and length must refer to a location within the string. this is in a for loop to loop through and get every ot... |
|