root85's Q&A profile
Connected Services Framework Any way to retrieve original SOAP action?
When a message gets processed by the Session Engine, the original SAOP action gets lost. For example, consider the following route (borrowed from the Intercept example) <Route> <Criteria>(ACTION EQ 'http://www.contoso.com/intercept/AddResponse')</Criteria> <Destination>UIParticipant[http://www.contoso.com/SampleServices/RouteResponse]</Destination> </Route> In the resulting SOAP call to the UIParticipant, the original action (AddResponse) is never mentioned. Is there a way to retrieve this original action and why isn't this provided Almost all other information (OriginalFrom, OriginalMessagId) is provided in the wsa:From > wsa:ReferenceProperties xml element... ...Show All
Visual C# Background compilation in Visual C#
Hello, I've noticed that Visual C# builds the project in the background when some important event occurs, for instance when a class or a reference is added. I have customized the build process and there is a task I would like to perform only when compilation is explicitly required, because it is very expensive. The question is: how can I detect (from my MSBuild .targets file) that I am in a 'background' compilation and not in a 'normal' one The post-compile step is PostSharp . Thank you. Gael This costed me one night, but here is the answer. Visual Studio effectively does do some background compilations even when it is not demanded by the user. To see this, just override the AfterCompile target and use the task that write ssomething ...Show All
Windows Forms MTAThread and AutoComplete
I need to use the WaitHandle.WaitAll and TextBox.AutoCompleteMode. The problem is that the first requires MTA and the latter STA . Is there any way around this rich Thanks for the info. The STA Marshalling issue can be significant when creating a rich UI control with multiple background threads. With COM InProcess components we can cheat. We can create several STA apartments and communicate directly across threads if we implement our own synchronization or we can play it safe and marshal the interface. The first is much faster when communicating with the object every few milliseconds. Ideally, all the components would be in the MTA but this allows us to host STA components is situations where ...Show All
Software Development for Windows Vista Accessing workflow instance members from WorkflowInstance (runtime event handlers)
Hi All, Is there a way to retrieve a strongly typed reference to the actual running workflow from a WorkflowInstance instance More details: I have a runtime event handler (loaded, idled) that receives a WorkflowEventArgs parameter. In that method I would like to access some of the instance properties (DependencyProperties) of my own workflow class. The only object I have in that method is a WorkflowInstance with an InstanceId. So the question is, how can I get a MyWorkflowClass instance if I have an InstanceId Thanks in advance. Shelly, I'm also concerned about lack of access to the workflow instance. I understand why the workflow passivation feature requires that you hide the workflow instance ...Show All
Software Development for Windows Vista A new outlook on Windows Vista
Hi! I am fascinated by the way in which Microsoft plans to change the nature of operating systems radically. Vista promises a better future -- lots of new data exchange solutions, better information organization and an easier GUI. It looks very exciting to me. However, there is still some doubt whether Vista will really be able to define the new wave of technology. I've been a user of Windows for the past 9 years, and have been accustomed to it (one reason I'll accept Vista quickly). I'd like to point out a few things that Microsoft should improve in order to gain more popularity (and market share ). Of course, I'm not a Microsoft employee so I don't know what's really going on. Just keep in mind that these are my personal opinions a ...Show All
Visual C++ Running problem with a C++ executable (Debug build)
Hi, I produced a debug build C++ executable program using MFC in VS 2005. The program runs perfectly with the computer in which it was created, but it can't run with other computers that don't have similar development environments but are equiped with all necessary dlls. An error message saying configuration is incorrect appears whenever the program is launched. MFC is set to be used in a shared dll in the program. To locate the reason that causes the problem, I blocked each possibly relevant environmental component in the system, such as .NET, Visual Studio, and directories containing libraries that were linked into the program. Despite these, the program runs normally in the computer where it was created. Should anybody have any ideas ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Strange effect when using translation
I have a strange problem when I'm trying to move one model around. When the model is in the center of the camera it look okay ( http://www.marmalad.com/milan/sample1.jpg ) but when I place it away from the center (let's say to the right) the model seems to be rotating as well ( http://www.marmalad.com/milan/sample2.jpg ). I would like to ask why is this happening Why is the model rotating when I'm just using translation Thx in advance. I'm absolutely sure that it was because of the culling machanism and XNA actually uses right-handed coordinate system by default. Proof (MSDN XNA FAQ page): What coordinate system does the XNA Framework use The XNA Framework uses a right-handed coordinate system ...Show All
Windows Forms Combo Box - Select One Value Return Another
Thanks in advance I have a combo box that I fill using: combo.valuemember = "Investor_id" combo.displaymember = "Investor_sht_name" combo.datasource = Dataset_2.tables(0).defaultview I want the Investor_sht_name field to give the value to the user for selection but what to get the Investor_id value to be added to an INSERT statement. I am getting the Investor_sht_name value returned. Any ideas Thanks Andrej I created a variable equal to combo.selectedvalue and it now returns the correct value. Thanks ...Show All
.NET Development Help!My program sometimes can't exit normally
when click X or other exit entry, OS asks user to report error to MS, I can't find any error, when use windbg, it report: Unknown exception - code c0020001 (first chance) Does anybody have the same problem and solve this problem If you application is a .NET 2.0 application and you are running it on a machine with .NET 2.0 installed, then the Watson report might be of interest. When prompted for "Send this error report to Microsoft", there is a special link to see what does the report contain. Click it If your OS is windows XP/2003, you will see a dialog . At the top of the dialog , you will see a box titled error signature. What is the value in the P9 bucket, It should generally be Managed exception of some kind. On Vista, y ...Show All
.NET Development Problem of encryption and decryption
I am doing a encryption and decryption of a text file. I would also need the words in encrypted.txt to remain the same. Button 1 is encyrption and button 2 is decryption. When i press the decrytion button, an error pops up. The code can also be found in vb 2005 right click and insert snippet - security Button1 Codes Dim fStream As FileStream = File.Open( "encrypted.txt" , FileMode.OpenOrCreate) Dim RijndaelAlg As Rijndael = Rijndael.Create Dim cStream As New CryptoStream(fStream, _ RijndaelAlg.CreateEncryptor(RijndaelAlg.Key, RijndaelAlg.IV), _ CryptoStreamMode.Write) Dim sWriter As New StreamWriter(cStream) sWriter.WriteLine( "Text to encrypt" ) sWriter.Close() cStre ...Show All
Visual C# Overloaded constructors
Can someone please explain why this doesn't work using System; public class MyClass { public MyClass () { MyClass ( 0 , string .Empty); //error here } public MyClass ( int i) { MyClass (i, string .Empty); //error here } public MyClass ( int i, string b) //full constructor { } public static void Main() { MyClass c = new MyClass ( 0 ); } The error is: 'MyClass' denotes a 'class' which is not valid in the given context I mean this error highlited on every line where I call my full constructor. P.S. I know how to make it work but the question ...Show All
Visual Studio Team System Removing project files from source control ?
Can i remove project files from source control By this i mean files like app.config, that are particular for each computer - it's really bothering when you get the latest version of an entire project and the above mentioned file gets overwritten. 10x I've tried deleting the file, but the file also gets unloaded from the project, so it's no good. I'll try with the custom check-in policy ! 10x a lot ! ...Show All
SQL Server TargetQueue get disabled automatically ?
I have a weird problem going on : my SB configuration involves 3 servers. Server A sends a message to Server B. there's a stored proc on Server B that is being activated (using Activation), does some processing and sends the message to server C. on C there's another SP that is activated and it's supposed to insert a record into a table. My problem is that on Server C, the record doesn't get inserted when activation is set to ON. when activation is off on C and I run the proc manually, everything works fine, but when activation is on, the record doesn't get inserted. after this happened I tried to fire the proc manually and I got the following error : Msg 9617, Level 16, State 1, Procedure spMSG_ReceiveMessagesOnSubscriber, Line ...Show All
SQL Server Multiple ADOQuery on same connection, performances go down because of serverside cursors...
Hi everyone, I am coding under Delphi a software which will be using a SQL Server 2000. I am using ADO components and have the latest MDAC: 2.8 SP1. The software is using a lot of TADOQuery objects which are connected to the same TADOConnection. The TADOQuery having for options : - cursorlocation : useclient - cursortype : static - locktype : optimistic On the first use of a TADOQuery in order to execute any type of request, the processing is fast. If I am using this same object for others requests, everything is fine and as fast as the first request. But as soon as I am using another TADOQuery, performances are going down. In order to give some numbers, some requests can take as much as 17 seconds to be executed. The same requ ...Show All
Visual Studio Express Editions Can't connect to database when trying to create report
I am trying to create a report for a program I wrote in VB Express using a SQL Express database. I go into Visual Studio and Create New project. I give the project a name. I go to Project, Add New Item, and select Data Source. I select the current computer as server. I use Windows Authentication and I try to attach the database. When I test the connection string I get the error "An Error has occured while establishing a connection to the Server. When connection to SQL Server 2005 , this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, Error 40-Could not open a connection to SQL Server)" I can connect in Visual Basic and SQL Server Man ...Show All
