Bill Reiss's Q&A profile
.NET Development I am facing "Item has already been added"
I have an appliction created in .Net 2003 using SortedList. And it is working fine with .Net framework 1.1 Now we are analysing the impact of migrating the application to 2005. There we are facing this problem SortedList mySL = new SortedList (); mySL.Add( "First" , "Hello" ); mySL.Add( "Second". , "World" ); mySL.Add( "First" , "!" ); Error message: Item has already been added. Key in dictionary: 'First' Key being added: 'First' IS it only because of Duplicate entry Please any one kindly clarify this. Thanks Moi Hi, Yes, it is because "First" already exists as a key, the sortedlist object can not accept duplicate k ...Show All
Visual J# Getting a file MD5 checksum
How do I get the MD5 checksum of a file using J# I know about the "import System.Security.Cryptography.*;" and how to create the MD5 object but I cant seem to get it to work. Thanks for any help. You can create MessageDigest object for MD5 using the following code. MessageDigest md5 = MessageDigest.getInstance("MD5"); ...Show All
SQL Server ASPNET account can't connect to MSSQLSERVER
When I try to access my PasswordRecovery.aspx page I get an error. I've also added the Event Warning and the Failure Audit. I've tried deleting the ASPNET user account and recreating it using aspnet_regiis.exe. I still get the same error message. Should I add the ASPNET account to the Administrators group Currently it is with the Users group. Login failed for user 'PC325862970629\ASPNET'. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Data.SqlClient.SqlException: Login failed for user 'PC325862970629\ASPNET'. Source Error: An unhandled ex ...Show All
Visual Studio 2008 (Pre-release) DLINQ SubmitChanges() failure on SQL 2000
I have a sample application which works with our SQL 2005 server but not with the SQL 2000 server. When the data is bound to the grid the save button works just as expected with the SQL 2005 database, but fails when I use the SQL 2000 database (which is on the same server). I modified the DTC configuration on the client and server after referencing this article http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=230390&SiteID=1 , but still get the error "The transaction has already been implicitly or explicitly committed or aborted (Exception from HRESULT: 0x8004D00E)". Sample Code: public partial class Form1 : Form { DataGridView _grid = new DataGridView (); BadgerDataContext _dataContextSQL ...Show All
Visual Studio Tools for Office Determine the location of the template
Hi, I have started to create an add-in that will interact with a SharePoint list when the a new document is created from a SharePoint document library. The add-in is created and reacts on the NewDocument event, but I can not find any property on the Word application object (or in ActiveDocument) that tells me from which location the template was loaded/started. What I want to know is: Which document library have the user used for creating this new document Regards, // Henrik Hi Henrik Note that most people here have no experience or special knowledge concerning SharePoint. You may need to ask in a SharePoint newsgroup if the information I give you isn't appropriate to your scena ...Show All
Visual Studio Express Editions about library In C++
Hi evryone... while I using VC.NET 2005 To programing project I want to insert(add) some library to my project. what I doing to do that where can I find [component and controls] in VC.NET comment:( I founded thy library but I can add it ) and thanx early.. Take a look at http://msdn2.microsoft.com/en-us/library/ba1z7822.aspx that describes how to link other libraries to your project. Thanks, Ayman Shoukry VC++ Team ...Show All
SQL Server XML Datatype Nodes() Method
Dear ppl, I want to shred the following XML so that i can get all the Warranty (s) with id and text. Required Output id WarrantyText 1 1 year parts and labor 2 2 year parts and labor XML declare @myDoc xml set @myDoc = '<ProductDescription ProductID="1" ProductName="Road Bike"> <Features > <Warranty id="1">1 year parts and labor</Warranty> <Warranty id="2">2 year parts and labor</Warranty> <Maintenance>3 year parts and labor extended maintenance is available</Maintenance> </Features> </ProductDescription>' I am using the following query but it doesn't seem to work select ...Show All
.NET Development can't insert data into database
I just got a problem about my web page(.aspx). I set my web page with VB.Net, the page try to get data and insert or delete data from a database. The database is Access file (.mdb),which was located in the directory of ~/www/App_Data/. Now, the page can get the data, but there was an server error when it was inserting a new row data or delete a row in the table in database. However everything is fine when I test the page in my computer with localhost. I just think the error was caused by the directory App_Data without the right for write, but I am not sure it.Could I get suggestion please post: code you are using to insert data the specific errors you are getting when inserting data Visual Basic 2005 or 2003 (shouldnt real ...Show All
.NET Development Interop COM
Hi! I'm developing a class libray in .NET and I would like to know how do I do my DLL to run in another languages, like vb6, delphi, java (JNI), or another one that works with COM. Thanks. http://msdn2.microsoft.com/en-us/library/zsfww439.aspx ...Show All
Visual Studio Team System Load Testing - .Net Windows App
Hi All, How do I load test a .Net windows based application We have a Desktop application that works with 2 databases. A local MS access and central Oracle DB. Most of the time the application interacts with the local DB. But after the data entry is complete, the application sends data to the central Oracle DB. We would like to know what happens when, say 15,000 users send data to the Oracle DB at the same time. Please let me know the test strategy (should it be a Database load testing or Windows app load testing ). I see that using Team system we can't record and play a scenario of a Windows based app. Kindly help. Regards, Con ...Show All
Visual Studio Team System Batch file to start a web test
I’ve attempted to create a batch file that, with Windows Scheduler, would automatically kick off a test. In the MSDN library is an article How to: Schedule Tests Runs. The directions on creating the batch file will not work for me. The use of the MSTest commands results in an invalid command comment. Here’s the file content. Any suggestions :: VSTS.bat @ECHO OFF ::opening the application c: CD\"Program FIles\Microsoft Visual Studio 8\Common 7\IDE" start devenv.exe ::This 20 second delay is due to the app frequently reloading upon opening. ping -n 21 127.0.0.1 ::Trying to get the path right CD\"Visual Studio 2005\Projects\XNet Production ::Supposedly opening the meta ...Show All
SQL Server Compatiblity of SQLDMO and SQLSMO with respect to scripting via COM
Hi all, I need your help: Context : I have developed since long an installation with InstallShield's InstallScript language. This installation "talks" to SQLServer2000 in order to install, upgrade, backup and restore the application's database. All this is done in the InstallScript code using SQLDMO currently, using the COM interface as if using VB script. Problem : Now as we are preparing to support installation on SQL2005, I am investigating the usage of SQLSMO, as SQLDMO cannot be excepted on all target systems (SQLExpress must be supported, too). I looked in the SMO namespace and recognized, that the contained classes are registered as COM objects, too. Due to this I have no problem creating a Microsoft.SqlServer. ...Show All
Visual Studio Team System Can not add counters in load test
Hello. I've add record of remote computer to "counter sets mappings". Select there "ASP.NET", ".NET Application" and "IIS" categories. After I've add Custom Counter Set in Counter Sets named "Custom1". In Custom1 I call popup menu and select "Add Counters..." there. In displayed window I select name of remote computer. But after some time I receive a messagebox "Cant read performance categories for computer [ computer's_name ]". Remote computer has no installed VS. Also it not in same domain with my machine and there is no my user's acaunt. Please tell me, should I install VS (or some it's part) to remote computer Should both machines be in same damain Is it necess ...Show All
Visual C# Accessing COM DLL From C#
I have a COM based DLL. I need to use the Class defined in that DLL. What is the way to do that from C# Hi, Using tlbimp.exe tool; generate RCW (runtime callable wrapper) from your COM dll and add that generated dll using "add reference" in solution explorer - or you can use Add reference -> COM wizard to use it directly in your .Net project. tlbimp.exe will be found at: 1. For .Net 1.1: "<Microsoft Visual Studio .NET 2003 Installation path>\SDK\v1.1\Bin" 2. For .Net 2.0: "<Microsoft Visual Studio 8 Installation path>\SDK\v2.0\Bin" For more information about tlbimp.exe, you can visit: http://msdn2.microsoft.com/en-us/tt0cf3sx(VS.80).aspx For Using COM dll in C#, you ca ...Show All
SQL Server Assign text to Variables
I have a simple Execute DTS task which uses ADO.NET connection to update variable........and get the following error. Variable: @msg string Query: Select @msg = 'Invalid Process Dates' [Execute SQL Task] Error: Executing the query "Select @msg = 'Invalid Process Dates'" failed with the following error: "The incoming tabular data stream (TDS) remote procedure call (RPC) protocol stream is incorrect. Parameter 3 ("@msg "): Data type 0xE7 has an invalid data length or metadata length.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly. Any one has clue how to fix it I could u ...Show All
