Dr. Joe's Q&A profile
Visual C++ Use of HTREEITEM in /Clr
HI, When compiling an app that uses HTREEITEM i get an error complaining about _TREEITEM - _TREEITEM does not seem to be defined. I am currently trying to see if this will work: typedef struct TVITEM *HTREEITEM; Any hints on how to get around this I can confirm that the use of typedef _TREEITEM {}; solved that problem. I have not tried fiddling with the Lean and Mean def's as it seems inconsistent to do so. If afxcmn.h is included then the typedef above should occur regardless. The code uses #define VC_EXTRALEAN - it is quite diverse, but is mainly client side DBMS using ODBC with common controls. Thanks... - Tim ...Show All
Visual Studio Using VSS
Hi, I am new to Visual Source Safe. I would like to know of a good site, that can take me through a step-by-step instructions on using the VSS. Also, is it enough if VSS is installed on the server, and all other machines work from the server You can start with the msdn site: http://msdn.microsoft.com/vstudio/previous/ssafe/ Webcast: Source Control and Team Development Using Visual Studio .NET and Visual SourceSafe http://msevents.microsoft.com/cui/eventdetail.aspx eventid=1032254284&culture=en-us VSS Team Blog: http://blogs.msdn.com/checkitout/ MSDN whitepaper: Team Development with Visual Studio .NET and Visual SourceSafe ...Show All
Visual C++ How to compile C++ function to be used by C# ?
I want to write a native C++ function that I can later access from C#. Please keep in mind I do not have much experience developing on windows, (mostly unix) and that my only windows compiler is VS2005. I tried creating a MFC DLL. I am able to access this from a C++ .net program, but not from a C# program using P/Invoke. It seems that a plain MFC DLL is not "good enough" for use with DllImport. Is this correct It seems that I have two options: 1) compile the C++ function as a COM DLL (not sure how to do this from VS2005 - I don't see an option for that). I see an option for an ActiveX DLL...I hope I don't need to do th ...Show All
SQL Server Error connecting to Reporting Services 2005 using SQL Server Management Studio
I have configured my report server using Reporting Services Configuration Manager. I have green checks across the board. I can connect to the report server via the web to view reports and I can develop and publish reports, but I can not connect to Reporting Services using SQL Server Management Studio. I receive the error listed in plain text below. I've spent four hours trying to resolve this with no luck. OS: Windows 2003 SP1 Microsoft SQL Server 2005 - 9.00.1399.06 (Intel X86) Oct 14 2005 00:33:37 Copyright (c) 1988-2005 Microsoft Corporation Enterprise Edition on Windows NT 5.2 (Build 3790: Service Pack 1) TITLE: ...Show All
Visual Studio Express Editions Random Letters
How do I get a Random Letter I think I need to first get a Random number, then have the number = a Letter i.e A=1, B=2 etc but how do I do this This might help: Dim str As String = "" Dim i, n As Integer Dim c As Char Dim rand As New Random For i = 0 To 9 ' Length of string required n = rand.Next(65, 65 + 26) ' A thru Z c = System.Convert.ToChar(n) str = str + c Next MessageBox.Show(str) It's perhaps not the best way of achieving this, but it works... HTH ...Show All
Visual Studio Capturing Text Output from Exec Task
Is there any way I can capture the text that is output to the console while executing the <Exec> task to a property I'm porting my NAnt Scripts to MSBuild and we Create SCM ChangeLists from the exec task. I'd just like to extract the ChangeList ID. Chike I checked the msdn2 page for the Exec task ( http://msdn2.microsoft.com/en-us/x8zx72cd.aspx ) and it says: One disadvantage of using the Exec task rather than a more specific task is that it cannot gather output from the tool or command that it runs. At the risk of sounding silly, maybe you could pipe the output of the command to a fi ...Show All
SQL Server SQL
Hi! We are getting an error while trying to open Replication Publisher's properties on a server named - SERVERNAME.SUBDOMAIN.DOMAIN.COM rather than SERVERNAME with following details... SQL Server replication requires the actual server name to make a connection to the server. Connections through a server alias, IP address, or any other alternate name are not supported. Specify the actual server name, 'SERVERNAME'. (Replication.Utilities) ------------------------------ Program Location: at Microsoft.SqlServer.Management.UI.ReplicationSqlConnection.CheckServerAlias(ServerConnection conn) at Microsoft ...Show All
Visual Studio Visual Studio 2005 doesn't want to run!
I downloaded uninstall tool to kill previously installed Beta2. Than I ran Visual Studio 2005 Final Release setup. All went well, setup completed successfully. But... I launched Studio IDE, it showed Studio Logo and than disappeared. It didn't run. Oh, Lord, give me strength... :) To fix my machine, I only had to uninstall the VS 2005 Extensions for Windows Workflow Foundation. Thanks for the tip! ...Show All
Windows Forms datagrid problem
hi, how can i remove null values in my datagrid i want to display only a blank column everytime that column contains (null). in c# please. thanks. Apply a DataGridTableStyle to your grid. This is what controls its appearance. DataGridTableStyle style = new DataGridTableStyle(); style.MappingName = "MyTable"; DataGridTextBoxColumn colStyle = new DataGridTextBoxColumn(); colStyle.Ma ...Show All
.NET Development Additional information: No connection could be made because the target machine actively refused it
Hello, I am currently getting this error when attempting to instantiate and remote object. Currently, everything is located locally. Here is a code snippet to further explain. The highlighted code is where the error occurs. Can anyone help Thanks =========================================== namespace ResumeClient { public class ResumeClient { public static void Main( string [] args) { ChannelServices.RegisterChannel( new TcpClientChannel()); ResumeLoader loader = (ResumeLoader)Activator.GetObject( typeof (ResumeLoader), "tcp://localhost:9932/ResumeLoader"); if (loader== null ) { Console.WriteLine("Unable to get remote ...Show All
Visual Studio 2008 (Pre-release) Intermediary router and interoperability
Greetings, I am currently designing a solution which requires to have a high level of interoperability. The services will be used by external clients but also by internal applications. For me it would make sense to have 2 different bindings for both audiences. One would be wsHttpBinding for external clients and the other would be netTcpBinding so i can get the best performance for my internal applications. One thing though, is that i don't want to expose these services directly to the outside world. (They are deployed in a secured zode). Therefore i want to use a router similar to the one in the SDK (Intermediary router) that i will ...Show All
SQL Server DB Restoration Problem
I am working on a site redesign which attaches to an MS SQL backend. The hosting company sent me a backup copy of the DB. I am trying to restore the db into my SQL Server but keep getting an error. I created an empty DB and then backed up that DB. I then replaced the .bak from my db with the .bak file he sent to me in a zip document. I then tried to do a DB restore through enterprise manager and recieved this error: Device activation error. The physical file name 'd:\sql\database\mssql\data\stklaweb_db_data.mdf' may be incorrect. File 'stklaweb_db_data' cannot be restored to 'd:\sql\database\mssql\data\stklaweb_db_data.mdf'. Use With Move ...Show All
Windows Forms ClickOnce Appliction Short-Cuts
I have multiply .exe’s within my app using the MageUE.exe to create my .manifest I would like to be able to create additional shortcuts to other files within the ClickOnce deployed application. Or my main concern is to be able to create a shortcut to my actual program with ClickOnce, so it could handle both "myapp.exe" "myapp.exe setup" from the start menu. Has anyone been able to do this or can someone point me in the right direction Cheers, Patrick This is a scenario not supported by ClickOne. If you have multiple executables as part of your Application package you have the followign options - The obvious option to pac ...Show All
.NET Development Implementing ISynchronizeInvoke when using System.Timers.Timer
MyObject is running on the main thread. MyObject.Start is called which calls an unmanaged API to begin a process. It then starts a System.Timers.Timer for 5 seconds in the future The Timer elapses and called MyObject.Stop which calls into the unmanaged API to end the process. Of course this is called on a secondary thread. I suspected that this wouldn't work becuase the unmanaged API doesn't like being called from 2 threads and it turns out I am correct. I have come to the conclusion that if I make MyObject implement ISynchronizeInvoke then I can pass in 'this' as the . SynchronizingObject property on the timer and I ...Show All
Windows Forms Using MS Office to do a mail merge
Ok I know that I have a large number of questions here. Please, I need all the help I can get on this one. I have an application that is putting data into an Excel spreadsheet. I have also created a mail merge document to read that data into a form letter. How can I do the following 1. Open Word 2. Open form letter&n ...Show All
