VBwant2B's Q&A profile
SQL Server SqlHelper.cs for SQL Server Everywhere
Hi, my application work with the SQLHelper class. This works fine for the MSDE/SQL Server 2005 Express Edition. Now I want that my application work with the SQL Server Everywhere DB. Is there an SQLHelper class out there for SQL Server Everywhere Thanks Gunter Hubmann Hi Dan, thank you for your efforts. That looks realy great and is exactly that what I want. This will be a big help for me. Thanks Gunter Hubmann ...Show All
Visual Studio Team System Serialization Exception
When my unit test is completing, I get the following exception: Unit Test Adapter threw exception: System.Runtime.Serialization.SerializationException: Type 'System.Net.NetworkCredential' in Assembly 'System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' is not marked as serializable.. My code does instantiate a NetworkCredential class - if I remove that code, all is OK. I'd appreciate any thoughts on this one. Thanks, Scott. Hi Scott, Try adding the property [Serializable] to your class, that should make it. Thanks, David Gorena Elizondo [MSFT] VSTS ...Show All
.NET Development Authenticating client using SSLStream
I have seen the MSDN sample code for implementing SSL in a TCP client/server application (http://msdn2.microsoft.com/en-us/library/system.net.security.sslstream.aspx) I then wanted to add the 'optional' client authentication piece to this sample by changing the client to use: I Added: X509CertificateCollection X509Coll = new X509CertificateCollection(); I Added: X509Coll.Add(new X509Certificate(@"c:\Projects\SSLStreamClient.cer")); I Changed: sslStream.AuthenticateAsClient(serverName, X509Coll, SslProtocols.Tls, false); it originally was: s slStream.AuthenticateAsClient(serverName); I created SSLStreamClient.cer using makecert.exe and placed it in CurrentUser.Personal and in CurrentUser.Trusted Root Certi ...Show All
Visual Basic Debugging .NET code and VB6 code
I am hosting a .NET UserControl inside a VB6 MDI(as per article http://blogs.msdn.com/vbteam/archive/2006/11/02/interop-roadmap-usercontrols-mdi-and-data.aspx ) Could anyone suggest a good debugging strategy to trace code running in the .NET control while being hosted in the VB6 app Hi Eric, I just tried it out and it worked fine on my machine; are you sure you referenced both TLBs When you add the control to your VB6 Toolbox it'll automatically add a reference to <NameofYourLibrary>Ctl, but you also need to add a reference to <NameofYourLibrary>. The reason is the events fire through the first TLB, not the Ctl one that VB6 creates. Other than that though your code looks fine. Hope that helps, Jonath ...Show All
Visual Studio Team System Menu Item locations inconsistent
I am not sure if this is a Team Foundation issue or a Team System issue but we are finding the menu item locations not consistent and we don't know why. For example, on my system, "Pending Changes" can be found directly under the View menu. On my co-worker's system, "Pending Changes" is found in "Other Windows" under View. Would it be because of the different VS2005 sytem are in use (some of our developers are using VS2005 Professional, others Developers suite, others Team Suite, etc.) How does one make sure that menu item locations are consistent Thanks, Maggie Dear Maggie: The inconsistence is caused by the version of the VS2005 and sometimes affected by the order of ...Show All
Software Development for Windows Vista GetVersionEx weirdness on Vista. Please help
I am calling GetVersionEx to get the windows version. I am using code sample provided at http://www.codeproject.com/win32/osdetect.asp . On WindowsXP it correctly returns 5 as the major version. But on Windows Vista, it returns 5 again instead of 6. Has anyone see this issue or any ideas why GetVersionEx returns incorrect value on Vista So far I have tried compiling with different settings of _WIN32_WINNT, reinstalled Vista just to be sure, tried to run this on a different Vista system with the same incorrect result. I also tried GetVersion instead of GetVersionEx too without success. Should I check for some registry keys or something I am stuck on this for more than a day now. Appreciate any help. Thanks. ...Show All
Visual Studio Express Editions Join function with array of Objects
Help lists the declaration of the Join Function as Function Join( ByVal SourceArray () As { Object | String }, Optional ByVal Delimiter As String = " " ) As String It does not describe what happens if SourceArray is an array of objects rather than strings, but I assumed that it would use ToString to convert each Object to a String and then join them using Delimiter. However when I try to use Join to convert an array of IpAddress Objects to a string like this: Dim dnsAddresses() as IpAddress dnsAddresses = Dns.GetHostEntry("AComputerName").AddressList Dim Adrs As String = Join(dnsAddresses, ", ") the Join function gets an "Argument 'SourceArray' cannot be converted to type 'String'& ...Show All
Visual Studio Team System Migration, common code- Sync between VSS and TFS?
Are any new tools available that would help with the migration period from VSS to TFS. We want to move product teams over one at a time, but they rely on common code that spans teams. So we want have VSS changes sync'd with TFS so that the team migrating to TFS can work on TFS and teams still using VSS can continue to do that. Are there other ways people are dealing with common code during a migration Thanks The best estimate for the toolkit that I can give is later this spring. We are still in development, and as we near our release I will be blogging on the TFS Migration blog. Also, thanks for sharing your experiences with the CSConverter. -Matt ...Show All
Visual C++ How to measure memory consumption?
Hi, I have a very complex C++ object (with many class members and some of them are shared between different objects). What is the best way to measure how much memory this object takes I tried the following: before and after creating this object I call GetProcessMemoryInfo(hProcess, &pmc, sizeof(pmc)) and then use difference in pmc.WorkingSetSize between two calls. However it doesn't work well since WorkingSetSize increased in balks. So sometimes I get a big memory increase and other times it is zero. Is there any system function that allow to measure exactly how much memory was allocated between two calls Thanks in advance for help! PS. I develo ...Show All
Architecture Call Logging System
Hi, I am thinking about making a small call logging system to use on our Helpdesk. The Helpdesk system will be used to log client jobs. Work is then completed by Engineers, narrated (in the system), and then passed back to the helpdesk to follow up. Engineers will need access to this Helpdesk system from outside the company. Firstly, I am not really sure where I should start, so if you have, or know of, any online resources I could have a look at that would probably be good for a start. Secondly, I am not sure if I should be building a web application (Web Site) or windows application (Project). I know this is a very high level view of what I am trying to accomplish, but your advice/suggestions would be most welcome. Thanks, ...Show All
Visual Studio Problems with Dataset
Hi, I would like to know when to set the datasource of the crystal viewer from code I'm doing this : Private Sub CrystalReportViewer1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CrystalReportViewer1.Load ' filling the dataset ' .... report.SetDataSource(dataSet) Me.CrystalReportViewer1.ReportSource = report Me.CrystalReportViewer1.Refresh() The dataset I'm passing to the viewer contains only one row; when the viewer is displayed, it shows all the data, so it means it shows data returned by the query in the report itself, not from my dataset, like it's overwriting my dataset. Is there a more appropriate event than the Load method of the viewer to set the datasource to my dataset ...Show All
Visual C# Unable to delete folder - being used by another process
When I try to delete a directory I get an IOException because it is being used by another process. The only process that is using it is the one trying to delete it. To prove this I created a folder and added a txt file to it. I started the app, used an OpenFileDialog object to get the string of the selected file. I then try to delete the file but get the exception - I also get the error if I try to delete the file through Windows Explorer. When I close the app I can delete the directory in windows explorer. I don't understand why this is happening as I have disposed of the object. Is the OS holding onto something that I need to clean up Here is a simple example of the problem. try { OpenFileDialog openFileDialog1 = new ...Show All
SQL Server Installing Report Service in Window XP - Report Builder and other option are not displaying
hi I have installed SQL Server Reporting Service on window xp. everything working fine except one thing. I have installed sql server with my a/c. my a/c have admin rights. when i giving http://dineshpatel/reports it is displaying page but Report Builder and other option are not displaying. I hope i don't have admin rights. I have checked with local administrator login also but same problem. what additional setting are require for admin rights Dinesh Patel Can you try un-installing and re-installing SSRS after logging in as an administrator on the box Even the site setting missing from the page surely seems to be a permissions problem. May be re-installing is a faster than trying to look ...Show All
SQL Server heavy-ish, continued cpu usage on 1 of 16 cpu's...
Hi all. We have an interesting situation we are trying to understand. Running SQL 2005 64 bit SP 1 hotfix rollup (9.0.2153) on SQL 2003 SP 2. We have a '16 cpu' (4 x dual core, hyper threaded) box. We are seeing one CPU running at between 25 to 40 % usage consistently, over the course of an entire day. We've stopped and started unnecessary services at times when we could (i.e. SQL Server agent when nothing was running) - but no dice - that single CPU continues to run hot, while the other cpu's run between 5-10%. SQL in not constrained to only use 1 CPU, and is using the others: [code]select scheduler_id, current_tasks_count, runnable_tasks_count from sys.dm_os_schedulers where scheduler_id < 255[/code] gives us between 1 an ...Show All
Visual C++ Two Projects Colliding
I have a project with twenty configurations (I'll call it "project A"). I suddenly had a need to build two versions of all those configurations - one with dynamically linked CRTs, and the other with static linked CRTs. So I decided to duplicate the project file, giving it a new name ("project B"), and added it to the same solution. I changed the name of its executable output, so it would not overwrite the other executable being produced. This trick only works by declaring project B to have a dependency on project A, and using the "rebuild" command. If I just use the plain "build" command, I get all kinds of linker errors of identifiers already found. This is because both projects are sharing th ...Show All
