Nikola Kasev's Q&A profile
.NET Development Install service via Installer
Hi all, I have a Windows Service project, and an Installer project to create a .MSI for it. I'd like for the MSI to install the service after it is done installing the project. I think I need to do this with a Commit Custom Action, but cannot figure out how. Seems like this should be easy, and common, right Thanks for any input. Cheers, Chris not sure if you still need this but i eventually worked it out. add an install package project to your solution. add to this the the primary output from yourt service. right-click the setup package project, choose View --> Custom Actions add the Primary Output from the s ...Show All
Visual Studio Team System Premature aborting of WebTest - How scalable is WebTest?
I currently have a webtest that is approximately 10MB with about 5000 requests. Now, when I try to run this webtest, it prematurely aborts without giving any indication as to why it aborted. I get to about 40% of the requests, then webtest simply stops. I am currently running RC1, with 1.5G of RAM, Pentium 4. Also, while it did not complete all of the requests in this webtest, it did generate a results file (TRX), which is approximately 200MB, which takes a while to open in Visual Studio. Now, that means that if I run this test 5 times, that would take about 1G of harddisk space... Specific Question. Is there any way to te ...Show All
SQL Server Insufficient Log Data
The mirror database, "UOP_PIMB", has insufficient transaction log data to preserve the log backup chain of the principal database. This may happen if a log backup from the principal database has not been taken or has not been restored on the mirror database. (Microsoft SQL Server, Error: 1478) I've taken a backup while the database is online and applied it to my "other" server. What do I need to do to have both in sync to get mirroring to work. My way around this is to restore the backup to my primary. thanks. Even though the BOL don't mention this, I have always had to appl ...Show All
Visual Studio Change a connector's from and to endpoints at runtime
Is it possible to change a connector's from and to end points at runtime I've tried creating a partial class for my connector and setting the FromEndPoint and ToEndPoint properties during the OnShapeInserted event however after committing the transaction they revert back to thier original settings. I notice there are Move and MoveByRepositioning methods but I don't know what parameters to give them. Hi Russell, Yes, it's possible to set the From/ToEndPoints. You were on the right track by setting the FromEndPoint and ToEndPoint properties. However, end points also have a fixed flag. By default, the Fixed ...Show All
Visual Basic question on unhandled exception error
I have an app with ~40 win forms that runs fine on my development box, but when I deploy it on another box, 3 of the forms give me the following error: ************** Exception Text ************** System.IO.FileLoadException: Could not load file or assembly 'Microsoft.VisualBasic.Compatibility, Version=7.0.5000.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040) File name: 'Microsoft.VisualBasic.Compatibility, Version=7.0.5000.0, Culture=neutral, PublicKeyToken=b03f5f7f1 ...Show All
Windows Forms Uninstalling old version while upgrading to new version(Installer class)
v2.0 of my application needs to use some data files of v1.0; I am not using InstallShield but am using normal Windows Installer built from VS.NET2003; Now the solution that I visualise is that the v2.0 installer will be in upgrade mode, "RemovePreviousVersions=False", and using the Installer class copy required data files in the BeforeInstall event, and finally uninstall the previous v1.0; Now the problem is that uninstallation is not being permitted from any before/after install events in Installer class. Is there any alternative or is there something that am missing. Thanks. Have you tried withR ...Show All
Visual Studio Team System How to set test run order?
Hi, I developed some test methods, put my tests in a test list by using the Test Manager. I have to questions: 1- The first test in the list take a little bit logger to execute. The first test method take 0.5 sec more to execute. Is it normal and if yes... why 2- How can I manage the run order of my test method in my test list They don't always run in a predictable order... Thanks Alain Martineau Publishing Business System There's actually a property you can use to change whether or not an ordered test stops when a test fails. In the ordered test edito ...Show All
.NET Development "Cannot initialize SSPI" error on web page
I have a web page which I created and we are in the process of moving the server out of the domain and connecting through impersonation to the SQLServer in the domain. I have the impersonation tag in the web.config file set to true and the user set in IIS to a valid user. This all works fine and dandy, but after running for about 30 min or so I get the "Cannot initialize SSPI" error and have to restart IIS to get it working again. I have gone through this article: http://support.microsoft.com/ id=811889 and made sure everything there was in check. But I have not been able to find a solution. Please help if you have any ideas. Like I said it ...Show All
Visual Basic Moving things in a listbox
ok, i have a menu and a listbox, in the form1_load i have: For Each toolStripmenuItem As ToolStripMenuItem In ToolStripSplitButton1.DropDownItems Me .ListBox1.Items.Add(toolStripmenuItem.Text) Next In my menu i have: box1 box2 box3 The listbox displays all of these, i then want to be able to select box1 in the listbox and move it around, say under box3, i also want the changes to appear in the menu, how would i go about this OK...sorry for the wait. Here's a example... It's works, but it's not drawing splitter lines and such. You'll have to make that code. To run my exmaple, start a new app ...Show All
Visual Studio Can't implement VSProject interface
Can’t implement VSProject Hello, I trying to create some mock objects for unit tests that implement the VSProject interface. I created a class and implemented the interface, everything compiles but one I try to instantiate my mock class (new MockVSProject()) I get: System.TypeLoadException: Method 'get_DTE' in type 'MyLibrary.MockVSProject' from assembly ' MyLibrary.Mocks, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' does not have an implementation.. Any idea of what the problem could be Thanks Gabo It seems like it, ho ...Show All
Visual Studio Team System How to get a variable's System Data Type.
How to get a variable's System Data Type. I need to find all the variables that are of type, System.IO.StreamReader, using fxcop. How do i achieve this. If not possible do let me know the reason. It would be helpful if some sample code would be available. regards venkateshaperumal Hi Venkatesaperumal Depends what variable you're talking about. For fields on classes, you can do the following: TypeNode m_streamReader; public override void BeforeAnalysis() { m_streamReader = FrameworkAssemblies.Mscorlib.GetType(Identifier.For("System.IO", Identifier.For("StreamReader")); } pu ...Show All
SQL Server Determining the most appropriate conversion for a string
Hi, Is there some kind of code snippet to determine (a) the precise data type (and precision if appropriate) of a given table.columnname in the database, and (b) the most suitable conversion for a varchar that is being made to hold various types of data. Presumably based on the above one could have some sort of CASE WHEN to cast the data to different types accordingly. Thanks for any help on this. Just briefly, this is definitely still erroring. The problem seems to consist in going from varchar to money (in order to carry out a valid calculation) and then going back to varchar. I will post on this in more d ...Show All
SQL Server Validate Subscriptions, turn it off
I added Validate Subscriptions to my publication using the procedure outlined in BOL. Procedure is listed below. I want to stop the validation for this publication. I do not want to validate any longer. How can I stop this process To validate transactional data using SQL Server Enterprise Manager At the Distributor, expand Replication Monitor , expand Publishers , and then expand a specific Publisher. Right-click a transactional publication, and then click Validate subscriptions . Choose whether you want to validate all subscriptions or just specific subscriptions, and if you want to validate specific subscriptions, select t ...Show All
Windows Forms Can't find CollectionEditor
I'm new 2 .Net so B patient with me :) I'm getting the error !! type 'System.ComponentModel.Design.CollectionEditor' not defined With intellisense i do not see the class as wel Any clous Regards Remco Tnx that's it I feel pretty stupid right now :) Remco ...Show All
Visual C++ Creating pointer causes illigal memory access
Hello I need to wrap some functions from the Insigth Toolkit in my own DLL. This is generally no problem. I create a class whith some methods that uses the toolkits functions. Then I create some functions that will interact with the objets of my class; and only this few functions I export with dllexport. (Some kind of wrapping...) This all works fine. But I need some pointer to use in every method. So my idea was following: Are you using a debugger Let the debugger take you to the point of the exception, and then deduce backward what the cause is. Other ideas (your code seems convoluted): Instead of ReaderType::Pointer reader; h ...Show All
