Mark Daly's Q&A profile
Visual Studio 2008 (Pre-release) OperationContextFlow
Hi, I am passing some additional data for a call using MessageHeaders: Client side: Guid g = Guid .NewGuid(); MessageHeader < Guid > mhg = new MessageHeader < Guid >(g); MessageHeader untyped = mhg.GetUntypedHeader( "session" , "ns" ); using ( OperationContextScope scope = new OperationContextScope (...)) { OperationContext .Current.OutgoingMessageHeaders.Add(untyped); call the service method ...Show All
Visual C# Convert
I'm very new to c#, and want to be able to take a string from a textbox, convert it to int, do some calculations with it, then convert it back to string. Presuming A is the string value and b is the int value, what piece of code would perform the conversion, and then back again. thanks string a = Textbox.Text; int b = int.Parse(a); b = b * 2 + 7; Textbox.Text = b.ToString(); Cheers, Greg ...Show All
Visual Studio 2008 (Pre-release) ServiceHost OnApplyconfiguration
ServiceHost host = CreateServiceHost(); host.Open(); The problem is the ServiceHost Constructor calls the protected OnApplyConfiguration method. Doesn't h aving a constructor reading from the app.config is BAD practice via my blog: http://devauthority.com/blogs/samuelson/archive/2006/02/08/717.aspx Best Regards, Ido Samuelson Greetings, The ServiceHost constructor does two main task ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Some questions about Vista & Direct3D 10
Hello! Greetings from Ukraine! I am still programming under WinXP and DX9. But I'm going to port my code into Vista platform and cannot find some information I am interested in. According to numerous articles and documentations porting is to be painful:) So, I have some questions listed below: 1. When will (approximately) the nVidia or ATI accelerators support Shader Model 4 2. How shall I use SIMD advantages on the C ...Show All
.NET Development Nested queries to populate a DataSet using OdbcDataAdapter
The class listed below uses a CSV file and OdbcDataAdapter object to populate a DataSet using a nested query BUT I keep getting an Access Violation exception when I call OdbcDataAdapter.Fill(). The message is: "Attempted to read or write protected memory. This is often an indication that other memory is corrupt." This is written in VS 2005 (.NET Framework 2.0). Are nested queries in the SelectCommand() method of the OdbcDataAdapter object not ...Show All
.NET Development DataReader vs. DataAdapter
hello, I have a problem to understand the DataReader. There is a temp table in a database, I search some values and I have to insert the values in a other ( permanent ) table. Now I read the values with the Datareader from the temp table like this thx for form your fast answer, I will try it with a dataadapter. I try this code SqlDataAdapter sql_select3 = new SqlDataAdapter ( "SELECT WeKdnr FROM dbo.tbl_temp_a WHERE Amount ...Show All
SQL Server Message Retieval
Hello again, A. This time I would like to get your input on two ways of getting a message off a queue. Both are samples, but I would like to know more about the implications. This first example (BOL) goes directly to the queue: WAITFOR ( RECEIVE TOP(1) @messageTypeName = message_type_name, @messageBody = message_body, @conversationHandle = conversation_handle FROM ExpenseQueu ...Show All
Visual Basic Is at website...
I was wondering how to Check if my webbrowser control is at a cirtain page... My problem is that that page includes a "sessionID" which means a simple IF page.url = needed_page then wont work... Does anyone know the answer do you mean that your url includes sessionID in the queryString why don't you check the beginning of the url : If page.url.BeginsWith(needed_page) Then ...Show All
Visual Studio Express Editions How to get the E-Book
Hi. I just registered the VB Express 2005, but I don't see where to download the accompanying e-book. Is there a special link that I'm missing Thanks hi, you can check this https://connect.microsoft.com/downloads/downloads.aspx SiteID=40 may be it will not allow you to download in the same day that you have registered your copy so give it a day or two if it didn't open hope this helps ...Show All
Windows Forms GUI Alignment
Hi, I've designed and developed my VB.NET apps in windows XP desktop. Now i have to deploy it into a laptop running on windows xp. the problem is , GUI alignment has been changed when i execute the apps in laptop. The resolution of the development system is 1024 by 768 pixels. ,, ,, deployment system is 1400 by 1050 pixels. i hope this one is changing the GUI alignment. so, i changed the deployment systems resolution to 1024 by ...Show All
Visual Basic Splash Screen
Vb .net if I create a spash screen and load a new form - when I dispose of the splash screen it kills the entire application. Any ideas or better methods to doing this rich I added it to the form closing event and it worked awesome! Thanks for your help... rich ...Show All
.NET Development Serializing a custom struct
I build the follow type: public struct UID { string _uid; bool _initialized; public static readonly UID Empty; public UID(string uid) { _uid = uid; _initialized = true; } public override string ToString() { return _uid; } } When i try to serialize this type using XmlSerializer, the value contained in my type is not serialized like the type System.DateTime of .NET Framework. I want that my type behave like the Sys ...Show All
Visual C# using System.Management
I have just downloaded 2005 Beta 2 and I am trying to do some simple programs to master the new enviroment. I am unable to use System.Management. When I type using Sytem.Management in my code I don't see Management as a possible extension to System and I receive the following message when I try to compile: error CS0234: The type or namespace name 'Management' does not exist in the namespace 'System' Any help would be greatly ...Show All
Visual Studio 2008 (Pre-release) WCF and SOAP with Attachments
Hi all, today I'm investigate the standard implemented in WCF. I've seen that the attachments can be send o received only in MTOM format. It is right In my project I must implement the SOAP 1.1 with Attachments standard specification. It is possible with WCF I must write a specific message encoder (as MtomMessageEncoder) Thanks in advance, Fabio Greetings, Yes, this should be possible. To do this, you should implement a custom Message ...Show All
Windows Forms Set rotating/animated Hourglass
i would like to set rotating/animated hour glass during a lengthy db call .. Any ideas how to do that Cursor currentCursor = Cursor.Current; try { Cursor.Current = Cursors.WaitCursor; // Do your DB call here } finally { Cursor.Current = currentCursor; } ...Show All
