Answer Questions
HVE How to call an .exe from a webservice\ASP.NET?
Hello folks, How do I call an executable from c# webservice, ideally with parameters The webservice is running on IIS and I want to call an executable on the local drive, e.g. notepad.exe Here is my code: ProcessStartInfo psi = new ProcessStartInfo (); psi.FileName = @"notepad.exe" ; psi.UseShellExecute = false ; psi.LoadUserProfile = true ; psi.UserName = "SYSTEM" ; Process .Start( "N ...Show All
Andreas Brosten Parsing a string
Hello guys, i'm searching for an advice of how to parse a string. here is an example: --bla345"cool"but no-- And I need only the text double closed by ", which is 'cool'. My second question is about parsing multyline comments /* */. So if i have --bla bla /*nice thing */ alabala-- my target is get the 'nice thing' string away of the "sentence". Hope someone will find time to help me :) ...Show All
Paulus Lau Opening CD tray from C#
I know it sounds bizar, but a friends teacher asked them to do that for a programming job, no no calculators, or a simple text editor, he wants a program that opens a CD tray... Now, I'm not asking for source code, I'll come up with that myself, but the question is... Is this even possible If you need to specify the drive then you can use DeviceIOControl. This sends messages straight to ATAPI devices using scsi pass through, and co ...Show All
Mitchell Baldwin C# Boxing & Unboxing
Hello, and first of anything please forgive me if my question is very basic, i'm new to the c# programming, and to programming also, and i'm reading inside c# book, but i dont understand: what is the objective of the boxing and unboxing methods, and what are the differences between have a value type and a reference type i mean what can i do whit boxing, that i can't do whit out it. thanks. Randolf Rincon Bucaramanga, Colombia. ...Show All
DanielEmerson Question: C# interoperate with an unmanaged COM with union data type
Hi, Help please. I use .net 2005 IDE to "Add reference" to a COM (named MyCom.dll). The COM has union data type looks like: typedef [switch_type(_DataType)] union _Union_data { [case(D1)] signed char v8; [case(D2)] signed short v16; } When I view Interop.MyComLib.dll( created by .net IDE) in Object Browser, the above union structure _Union_data become empty. Theref ...Show All
Phil Cowan Creating a C# project programmatically
I know how to create a C# solution and implement classes and save the solution and build it etc. I am looking for a method of doing all these steps in a program. Is there a way I can create a solution/project, add source files to it, save it and build it within another program, which could be a C# program. Something like this: CSharpSolution mySolution = new VisualStudio.CSharpSolution(); mySolution.CreateProject("myCSharpProj"); mySol ...Show All
MatthewDavid Finally! Some additionaly code snippets for C#.
Welcome to the future! I just had to share it with someone. http://msdn.microsoft.com/vstudio/downloads/codesnippets/default.aspx Q: Why can't I have a snippet for any functionality I want Q: To what extent can I view these as "best practices" Q: Why can't all new functionality added to a product (say SQL Server 2006) that can be invoked by way of .NET (say a custom aggregate) have snippets (in the language most s ...Show All
Nick Roberts C# Tutorials and books
Hi, As I am confused by searching the net for books and tutorials about C# I ask it here Can somebody give me advice about the following subjects. C# Database Programming C# GDI+ Programming C# Custom Controls C# Generel books are also welcome Greetz go to www.wrox.com . wrox publishes one of the greatest books for .net, sQL server. for GDI+, prefer to look at 'Graphics Programming with GDI+'. check out those books at www.ebooksclub.or ...Show All
shawnd_06 Shorten NameSpace question
I have a large enum structure like this: public enum MyEnum { Value1 = 100, Value2 = 200, .................. } Then I have a switch statement for all the enum members: switch (somevalue) { case MyEnum.Value1: Dosomething; break; case .......... } Since I have a lot of these I would like to shorten the case statements, avoiding the 'MyEnum' type definition. Many programming languages (like JScript or Delphi) ...Show All
bubbafett Fields that I have set as public static go back to just public
This is just started today. What is going on This is driving me crazy!!! You're typing 'public static' and the static part is disappearing When ...Show All
RAB36 i need help with basic things
Im new to visual C, but i know the fundimentals of prgramming, and i cant figure out how to make a form pop up or how to change the start screen to another form, any help What i meant by the first question, was how to change screens, like when you click a button it takes you to a different form. And does - myForm frm = new myForm(); - go in the button click event or somwhere else ...Show All
vbtricks How do I return a string from a csv file?
Hi, I am trying to search a csv file until it hits a null value. The csv file is set up in such a way that I can search line by line until the first cell is blank (MB/Code). At the moment I just want to find this null cell and get the program to return the value, and then I can find the Res-Code and do some further calculations. Below is an example of the file I am searchi ...Show All
JJoergensen How do I launch my default mail recipent programmatically from my C# application?
Hey howzit, When you right click a file and click Sent To>Mail Recipient, it opens a new instance of your default mail recipient e.g. Outlook. How do I achieve this level of functionality from my C# application Hey Chris, Thanks that works. Is there anyway I can specify which files to include as attachments You can use the mailto specification's listed in this page. Don't ignore the html talk. In that document you can see ...Show All
jeffandmarc C# Template for IFilters
Is there a c# template for building IFilters Hi AIM48. Actually, it is not recommended to create a C# IFilter since once you get into multiple CLR versions running on the system. This means the performance of the system will suffer greatly when each IFilter needs to be loaded and unloaded. It is recommended to use non-managed code for IFilters for the time being until a go ...Show All
NewKiwi hi
hi , when i use datagrid and double click event how can i choose data from the datagrid that i want thx There are certain values passed when the user double click on a DataGrid (WinForm) private void dataGridView1_CellContentClick_1(object sender, DataGridViewCellEventArgs e) { this.dataGridView1[e.ColumnIndex, e.RowIndex].Value = "ALI"; // By the help of Row/Column ...Show All
