GTH's Q&A profile
Visual Studio Express Editions Combobox Databindings
I am totally mystified by the workings of the combobox in the .Net environment. My problem is similar to that described by Johnathan on 25th Jan 2006 and replied to by Mattias Sjogren. Whilst Johnathan's original attempt was not the solution he used the following statement "foreach (String item in comboBoxCatagory.Items)" In order to try and get and understanding of how the Items are used I tried to execute the following: "foreach ( String str in SectorComboBox.Items)" and got the following error: Unable to cast object of type 'System.Data.DataRowView' to type 'System.String'. I have been attempting t ...Show All
Visual C++ Native Code and Relocatable Memory Blocks
Although I have found the new extensions to C++ in the 2005 beta to be thoughtfully designed, I am thinking about using old code. I don't (usually) need automatic garbage collection but I would like to have relocatable blocks of memory in the application heap. Is there an Easy way to use the OS to move blocks of memory that are allocated using "new" Or alternatively, is there a Simple way that I can use gcnew to dynamically allocate blocks of memory that could then be accessed as if they were dynamicly allocated native arrays (similar to those that can be allocated with new) I cannot fi ...Show All
Visual Studio Internet Connection in VS 2005
Hi, I just installed VS 2005 on my machine, but my online help cannot be accessed. I keep getting the message: "The request failed with Http Status 407. Proxy authentication required". IE on my machine does have proxy authentication. Is there a fix for this Thanks, Arshad Hmmm... not really. We're using HTTP POSTs to make our web service calls. Are you able to do HTTP POSTs (not just HTTP GETs) in IE to internet sites through your proxy ...Show All
Visual Studio Team System No effect of "define _CRT_SECURE_NO_DEPRECATE 1"
For the moment I want to suppress all the deprecated insecure functions during static code analysis. I've added this line in two separate files that get included in all source files: #define _CRT_SECURE_NO_DEPRECATE 1 to no effect -- the output still contains warning of these functions. A colleague has resorted to #pragma to supress these warnings. I'm curious as to why this doesn't work as documented in the help. Thanks. Sample warning: foo.cpp foo.cpp(18035) : warning C4996: '_wfopen' was declared deprecated c:\program files\microsoft visual studio 8\vc\include\wchar.h(827) : see declaration of '_wfopen' Message: ' ...Show All
Visual Studio Team System Why is 'Drop' outside of source control?
I'm sure a familiar site for a lot of people working with Team Foundation at the moment is a build machine file system littered with a folder after folder of previous builds in the drop location and it seems a bit odd that there is no provision for having the output of the build also placed in source control rather than clogging up the build machine, is there any particular reason for this So, OK, I could extend my team builds 'AfterBuildDrop' target to checkout the previous drop from source control and checkin the new one overtop and giving it a sensible label. I then want to be able at a later date to get against that label and publish to ...Show All
Visual C# How do I test a button when running an event?
I have a start button which runs a section of code continuously - how do I test the stop button while this code is running Colin, it is usually not a good idea to have an event executing for a long time, as while you are serving an event, the other events get blocked. This amounts to freeze the user interface. If you plan to have a lengthy task running in response to a button click, you should probably use a Thread, or the ThreadPool. It's fairly easy to use, and it's well worth the little time it takes to set them up, as the code becomes cleaner and easier to manage. Anyway, there is another option, ...Show All
Windows Forms right mouse click on treeview
can anyone show me how to display a context menu after a right mouse click on a specific node. This is what i have been able to acheive so far If e.Button = MouseButtons.Right Then TreeView1.SelectedNode = TreeView1.GetNodeAt(e.X, e.Y) If TreeView1.SelectedNode.Text = "Categories" Then ...Show All
Visual C# abstract class
This is my first time designing a abstract class and i have a question lets say you have a base class callled Bassclass looks like this namespace pratice { public abstract class BaseClass { public abstract void start(); } } i then have a derive class called Dev. in this class i havve implemention for methnd start here it is public override void start( int a ) { int r; throw new Exception ( "The method or operation is not implemented." ); r = 5; r++; } } as you can see in my implemention i have parns in my methnd start. Can i do this this is polymo ...Show All
Visual Studio 2008 (Pre-release) Accessing Child Property Element in a Trigger
Hi I want to animate the GradientStop element which is inside my rectangle. This rectangle is contained within a control template. My rectangle code is as follows - <Window.resources> <Style x:Key="CardStyle" TargetType="{x:Type Button}"> <Setter Property="Control.Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type Button}"> <Canvas> <DockPanel Name="HighLightDockPanel" Height="25" Width="{TemplateBinding FrameworkElement.ActualWidth}"> <Rectangle Name="Highligh ...Show All
Software Development for Windows Vista How do I get the context of the workflow instance?
Hi, I have a client sending an xml message to a SequentialWorkflow through a remoted service. The service exposes some methods which each triggers an event. The workflow has several Eventsink activities each “listening” to a specific event. When the event is triggered from the service, the xml message is sent to the workflow through the eventargs and is also stored in a local service variable (System.Collection.Generic.List). I can use this service variable to access every processed message. 1. Is there any way to invoke the workflow instance to get my xml message directly from the runtime instead of s ...Show All
.NET Development DataSet Usage - Not saving to file
Ok, my knowledge of the DataSet object is elementary at best, but I'll try to make some sense. I've added a MS Access .mdb file to my VC# project using the New Data Source wizard. Incase it's pertinent, here's the connection string (sorta): Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|\db000.mdb;Persist Security Info=True;Jet OLEDB:Database Password=xxxxxxxxx Now, I want my program to count validate that there's at least one user account in the table 'Users' during startup. I'm checking this with [object].Users.Rows.Count , which works just fine. When the application inevidably discovers there's no accounts, I ...Show All
Visual Studio Issues with dexplore.exe after installation of VS2005 and SQL Server 2005 Dev Ed.
Hi, I am having serious issues with the help viewer for my Visual Studio Professional Product. I have installed VS2005 Pro and then installed the workstation client tools and SQL Server 2005 Books Online of the accompanying SQL Server 2005 Dev Edition. Issue 1: Clicking “Help” > “How Do I” in Visual Studio gives me: --------------------------- Microsoft Visual Studio --------------------------- Attempted to read or write protected memory. This is often an indication that other memory is corrupt. --------------------------- OK &n ...Show All
Visual C# Question About Threads
i want to creat form using thread but the form disappear i write this private void button1_Click(object sender, EventArgs e) { Thread T = new Thread(CreateForm); T.Start(); } void CreateForm() { Form2 f = new Form2(); f.Show(); } The Show method shows a modeless form, which means that the code that created it keeps on running. In this case, that means the thread ends. Your form should be a member variable, and you should probably just show it, and use threading within the form for any work that the form does. Or you could call ShowDialog, which would show a modal ...Show All
SQL Server How can I find out whether SSIS is installed in the server?
Thanks a lot. Have a look at the service SQL Server Integration Services, if it is present you have SSIS installed. YOu can check that by open the SCM or type in the "net start" on the commandline on the server. HTH, Jens Suessmeyer. --- http://www.sqlserver2005.de --- ...Show All
Visual Studio Team System How to get the name of a .vb file
Hi Guys, I developed the rule below to get the name of all *.vb files that are inside a projet and wanna verify if the name has an especif construction. But, when I debug the rule method, I get the name of the .dll of the project and not the files inside it. How can I verify each file in a project I am analysing in fxCop the project dll. Is it correct Public Overloads Overrides Function Check( ByVal Modulo As Microsoft.Cci.Module) As ProblemCollection Dim failed As Boolean = True Dim fileName As String = Path.GetFileName(Modulo.Name) Dim filePrefix As String = fileName.Substring(0, 3).ToLower If fi ...Show All
