microsoft.public.dotnet.languages.csharp Archive - February 2003
Post a message to this list
Messages
Page: 1234
best method for counting lines of a text file? (7 replies)
microsoft.public.dotnet.languages.csharp
What could be the best method for counting the lines ( the number of \r\n) in an ASCII text file? Reading the whole text file line by line would do it, but could we imagine any better (faster) solution with C# stream classes? Thx!
Returning   in a Response stream (2 replies)
microsoft.public.dotnet.languages.csharp
In an application that I am writing, I use the following code to post an XML string to a server for processing: WebClient myWebClient new WebClient(); string uriString strRedirect; myWebClient.Headers.Add("Content Type","application/x www form urlencoded"); byte[] byteArray Encoding.ASCII.GetBytes(strGoodXML); byte[] responseArray myWebClient.UploadData(uriString,"POST",byteArray); Response.Write ...
Novice question - Regular Expression (5 replies)
microsoft.public.dotnet.languages.csharp
Whats the regular expression for matching strings like " hello "," hey " Can any one help? Thanks in advance.
storing data for user control (2 replies)
microsoft.public.dotnet.languages.csharp
whats the best way to store data for a user control? I've added new properties which are not associated with a particular child control so what do I do.
Extended Float type (11 replies)
microsoft.public.dotnet.languages.csharp
There is an 10 byte float type in C# ? 3.6 x 10^ 4951 .. 1.1 x 10^4932 thanks Paps
"friend" designation planned for C#? (9 replies)
microsoft.public.dotnet.languages.csharp
I'm using "internal" to manage specific access, but it's a crude tool, and I often find myself wishing for a "friend" designation to give greater specificity to my code. I note that "friend" isn't a keyword, so I'm not hopeful here, but I'm also guessing I'm not alone in seeing the significant value of this. On a related note, it would be nice to be able to specify different levels of protection f...
"Single Document - Multi View"-Application in C# (2 replies)
microsoft.public.dotnet.languages.csharp
Hi, i've written a SDI application connected with multiple views in VC . For example a tree view class, a grid view class and a diagramm view class based on one document class. Now i want to convert this project to C# (VS.NET) and looking for the best solution. Is it a kind of adapted MDI application ? Is there a pattern in VS.NET ? Thanks for a hint.
xmlvalidatingreader (2 replies)
microsoft.public.dotnet.languages.csharp
Hi there, I try to validate a XML file with XMLValidatingReader but an error occurs every time that "The type or namespace name 'type/namespace' could not be found (are you missing a using directive or an assembly reference?)". But I have included system.xml and system.xml.schema and in the online help it is said that the xmlvalidatingreader belongs to the namespace system.xml. what am I doing wro...
Security Excpetion when I try to Abort a thread in a browser. right? (2 replies)
microsoft.public.dotnet.languages.csharp
I have a C# app that runs correctly in a desktop WinApp setup. It uses GCI and creates a "blinking star" based on events. When I want to "clear" the stars, I abort the appropriate threads. When I compile and run this as an object in a browser, I get a Security Exception. Is this correct??? I mean I would think I would be able to abort a thread the I created.! Is there a way to correct this or a wa...
Inter-process communication: Named Pipes in .NET (2 replies)
microsoft.public.dotnet.languages.csharp
Where can I find information about Named Pipes in .NET ? For example how to do a Pipe Server and Client Server ? (create Named Pipe, read from a pipe and write to a pipe) Samples, books, articles...and so on. Thanks in advance Monica
Which is the equivalent in C# for CreateProcess ? (2 replies)
microsoft.public.dotnet.languages.csharp
Is there any function/ method which does something like this ? Can I use the SDK in C# ? If yes, how ? Thank you in advance, Christina Androne .
'Property' property not avaialble in COM Interop (3 replies)
microsoft.public.dotnet.languages.csharp
Hi, Recently i was doing some COMInterop to the PKMCDO.dll (Microsoft Web folders for Sharepoint Portal Server). The dll has a property that goes by the name of 'Property'. In VB.NET the property appears in Intellisense, but not for csharp. I had to resort to using get property & set property. Any reason for this behaviour? is it because Property is a keyword in csharp? Regards Tariq
Does a file exist? (3 replies)
microsoft.public.dotnet.languages.csharp
What is the best way to check for the existence of a specific file or directory? Any help is greatly appreciated.
xml valdiation with schema (2 replies)
microsoft.public.dotnet.languages.csharp
Hi, Until now the only way i found to validate xml file with schema is using xml reader which is associated with xmlValidationReader and while reading the xml stream it raises event when the xml file is not valid. Is there a way to validate xml file with schema without using readers? I simply want to check wether some xml file is valid or not. Thanks, Yoni
Moving controls at runtime. (2 replies)
microsoft.public.dotnet.languages.csharp
Hello, I have a UserControl that I would like to drag around the form at runtime. The MouseMove does not seem to work because changing the position of the control inside the MouseMove event seems to throw off the top and left values in the object passed into the MouseMove. I thought about drag and drop but I want to see the control moving, not an icon. Does anybody know how to move a control aroun...
CreateGraphics (2 replies)
microsoft.public.dotnet.languages.csharp
Hi All The Following Code Dows Not Work MemoryStream MS new MemoryStream(BitmapBytes, false); m Bitmap (Bitmap) Image.FromStream(MS); if(m Bitmap! null) Point P new Point(AutoScrollPosition.X, AutoScrollPosition.Y); CreateGraphics().DrawImage (m Bitmap,P); Any help is welcome Thanks in advance RathnaRaj
Performance Question (2 replies)
microsoft.public.dotnet.languages.csharp
Simple Question for anyone who wishes to help I need to simply display records on a web form page and iterate through large amounts of records which obviously must be shown on multiple pages trying to decide what datasource to use (ie Dataset, DataReader,DataView) and how to display them (ie DataGrid,DataList,Repeater) the only functionality will be a redirect to a single record page or a redirect...
DataGrid Problem: Click a cell-> Select whole row, doubleClick a cell-> edit that cell (2 replies)
microsoft.public.dotnet.languages.csharp
How can i implement these? 1. If you clicked on a cell in the datagrid then the whole row should be selected. I done this using following code. private void BookdataGrid MouseUp(object sender, System.Windows.Forms.MouseEventArgs e) { System.Drawing.Point pt new Point(e.X, e.Y); DataGrid.HitTestInfo hti BookdataGrid.HitTest(pt); if(hti.Type DataGrid.HitTestType.Cell) { BookdataGrid.CurrentCell new ...
'System.Data.DataSet.Tables' denotes a 'property' where a 'method' was expected (2 replies)
microsoft.public.dotnet.languages.csharp
Hi, When I use this in C# I get an error DataRelation DR new DataRelation("rMemberRank",objDS.Tables("Member").Columns("MemberCountryID") ,objDS.Tables("Country").Columns("CountryID")); ...\Test\Form1.cs(100): 'System.Data.DataSet.Tables' denotes a 'property' where a 'method' was expected This seemed to work fine in VB.NET, what am I doing wrong ? Thnx.
DataGrid Column Order (2 replies)
microsoft.public.dotnet.languages.csharp
The dataset seems to place the columns from Access in alphabetical order thus placing columns titled like "Comments" to appear first in the DataGrid rather then appearing last in the datagrid. How do I change the order in which columns appear in the datagrid? //Am I on the right track? private void setDataGridColumnsOrder() { GridColumnStylesCollection g1 employeeSignInGrid.TableStyles[0].GridColu...
how to hide or delete image on form (2 replies)
microsoft.public.dotnet.languages.csharp
Hi: all I use e.Graphics.DrawImage(myImage, new Rectangle(0,0, 100, 100), 0, 0, myImage.Width, myImage.Height GraphicsUnit.Pixel, null ); draw a image, also I draw several lines using g.DrawPath (myPen,myPath) above the image. In some situations, I want to hide or delete myImage and those lines, replaced by another new image on that area, how can I do it? (I tried put myImage in a pictureBox, then...
Datagrid, scrolling and events... (3 replies)
microsoft.public.dotnet.languages.csharp
Firstly I'd like to ask someone why the Datagrid event 'Scroll' doesn't use the ScrollEventHandler, but the defualt EventHandler instead? Secondly I'd like to know how I can raise an event with the ScrollEventHandler. I have done the following class MyDataGrid : DataGrid { public event ScrollEventHandler MyScroll; protected virtual void OnMyScroll( ScrollEventArgs e ) { if ( MyScroll ! null ) { My...
n-tier, Data-tier: How to do it professional? (2 replies)
microsoft.public.dotnet.languages.csharp
Hi NG! This is not a normal "HowTo" Question. I know how to code what I need. But I can see many different approaches and would appreciate your comments on following: I'm working on a small GUI application. There are some datas to manage and also some user settings to save and read. Question: How does a professional data tier look like? Possible Solutions (please comment, thank you!) 1) "Dear VS N...
Usage of Application.Run() (2 replies)
microsoft.public.dotnet.languages.csharp
Hello, In what situation would I use the Application.Run() method? I.e. use the Run() method WITHOUT a form object passed to it. Can I use this mechanism to implement my own Message pump? Could anybody out there give me a small example how to do it? Once I invoke Application.Run(), the call blocks. After this, how do I send messages to this message pump and how do I process the messages? Thanks, D...
question about WindowsPrincipal (2 replies)
microsoft.public.dotnet.languages.csharp
why this is working: WindowsIdentity wi; wi WindowsIdentity.GetCurrent(); MessageBox.Show(wi.Name); but to make this working: WindowsPrincipal wp; wp (WindowsPrincipal) System.Threading.Thread.CurrentPrincipal; WindowsIdentity wi (WindowsIdentity) wp.Identity; MessageBox.Show(wi.Name); I need to add: AppDomain.CurrentDomain.SetPrincipalPolicy (PrincipalPolicy.WindowsPrincipal); Is there any differ...
Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
 
 Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us - Terms of Use - Privacy Policy - www.dotnet247.com