Craig Main's Q&A profile
Smart Device Development Windows CE / .NET CF 2.0 / Custom UI
Any resources to explain how to go about developing user/custom controls which DON'T resemble Windows Forms If I am going from a proprietary embedded OS with our own application framework to Windows CE, it seems like .NET CF is not very useful for my products. I don't use a stylus on my device. I don't have a bunch of controls with right angles...etc, etc. My UI does not resemble Windows 95. I think you get the picture. It seems like all of the controls and documentation for .NET CF 2.0 is very Windows Mobile centric. What if you are designing an embedded device using Windows CE Core 5.0 and wanted to ha ...Show All
Software Development for Windows Vista Tracking workflows dynamically loaded from xoml files
Is it possible to track a workflow which is dynamically loaded from an xoml file I tried to use the sample "Workflow Monitor" from SDK to track such a workflow, but it always gave me an error: " Object reference not set to an instance of an object. " Here are my workflow files: <WFHelloWorld.xoml.cs> public partial class WFHelloWorld : SequenceActivity { public void SayHelloWorld_ExecuteCode(object sender, EventArgs e) { C ...Show All
Windows Forms ToolBar color and Height problem
I am trying to get a flat toolbar to work with the lighter gray look of the XP toolbar, as with IE. I am calling Application.EnableVisualStyles(); in Main. I set ToolBar.Appearance to ToolBarAppearance.Flat. However, the button bar ends up a darker gray than it should and there are are several additional pixels of gray beneath the buttons. What am I doing wrong,  ...Show All
Software Development for Windows Vista error after Install february ctp winfx
Hello, I install the new version february ctp. As i have already install the december ctp, i uninstall it before (this versions worked correctly on my system) To install, the february CTP, i respect the order describe on then download page. the installation finished successfully, but when i create new project or load an existing peroject i have problems : 1) the referencies assemblies aren't found except for Winfx service library. 2) when i try to compile the project, i have the following error : Microsoft.Build.Tasks.Windows.GetWinFXPath" task could not be loaded from the assembly PresentationBuildTasks, Version=3. ...Show All
Visual Basic Problem with my DATABASE
Ok i been studing this for a couple of days now and im gettin somewhere im finally able to make a connect what i did was i had to go in the sql manager and Enable the TCP Protocol also i had to use the data source manage and use the Connection string to connect when i connect now i get this is points to this bold part of my code If conn.State = ConnectionState.Open Then conn.Close() End If ConnectionString = "TEConnectionString" conn.ConnectionString = ConnectionString conn.Open() cmd = New SqlClient.SqlCommand(sql, conn) Try cmd.ExecuteNonQuery() Catch ae As SqlClient ...Show All
Visual Studio typedef struct being misinterpreted by debugger in locals window
I am having an issue with the debugger misinterpreting the data elements inside my structs from one local file to another. Here is an example of what I mean: In this program there are 3 files: ( C_test.cpp, file_A.cpp, file_B.cpp ) C_test.cpp: #include "stdafx.h" void file_a(); void file_b(); int _tmain( int argc, _TCHAR* argv[]) { file_a(); file_b(); printf("end of C_test \n"); return 0; } file_A.cpp: #include "stdafx.h" ...Show All
.NET Development Connecting to SQl 2005
Hi, I have built an application in C#, using VS.Net 2003 and .net framework 1.1. i am trying to connect it to a SQL2005 database, which is held on another machine within the same network. I keep getting an error reporting that the sql database does not exist or can be not accessed. The connection string is OK. Do I need to install .net framework 2 on my local m/c, or is there something else which I need and if so what Thanks Jason You might be having network issues, security issues, server configuration issues or your connection string is in fact not OK. I've outlined troubleshooting connection issues here f ...Show All
Windows Forms webbrowser in vb2005
i have a runtime created webbrowser and i want to use it's ProgressChanged event and some others, too. how can i do this I used this code and it worked just fine... Private Sub WebBrowser1_NewWindow( ByVal sender As Object , ByVal e As System.ComponentModel.CancelEventArgs) Handles WebBrowser1.NewWindow Dim NewURL As String = CType (sender, WebBrowser).StatusText Dim TabPageTemp As New TabPage(NewURL) Dim WebBrowserTemp As New WebBrowser WebBrowserTemp.Dock = DockStyle.Fill AddHandler WebBrowserTemp.NewWindow, AddressOf Me .WebBrowser1_NewWindow TabPageTemp.Controls.Add(WebBrowserTemp) Me ...Show All
Visual Studio Express Editions Page Setup Dialog and its Margins
I need some help please with the following issue: I have a simple application that writes a line of text to a page. When I check the values of the System.Drawing.Printing.PrintPageEventArgs pagesetup margin values they are all 100mm. If I then open and close the PageSetupDialog whose margins are all set bydefault to 10mm the margin values change to the following: Left=39 Right=39 Top=39 Bottom=39 If I then open the PageSetupDialog again, the margin values have all chaged to 3.9. Without changing anything I close the dialog and re-check the System.Drawing.Printing.PrintPageEventArgs PageSetup Margin values. They have all chang ...Show All
Visual Studio Team System Problem with Automatically added Locks
Hi, I have been testing VSTS for our company for over a month now. We recently came across an issue when adding files into source control in Team System. When the files were added to the source control, Team System would automatically add a check-out lock to some of the files. The addition of the lock appears to be random, it affected one file but not another. This poses a problem, because we use shelvesets to review and audit code before creating a changeset. When the files are locked, another user cannot unshelve the pending changes and review the code. What I would like to know is why Team System is adding locks to some files, but not ...Show All
Windows Forms ToolStripItems: how to duplicate?
In my scenario, I have a context menu which should show additional sub-menus from loaded plugins. As I want to use the visual designer (not create the menus each time in code), my problem is how to copy some ToolStripItems from a ToolStrip menu to another. What's happening on simple copy (enumerating in first menu and adding to second) is that the items are removed from the source menu on copy (I assume the Owner changes so the item is automatically removed from the source owner). ex: ctxMenuDestination.Items.AddRange(ctxMenuSource.Items) does not work, as copying removes them from the source collection and gives an enumeration error. Betwee ...Show All
SQL Server Annoying scrolling in SSIS
Hi Jamie, I raised questions about this kind of thing way back in the private beta timeframe. It was perceived as not too much of a practical problem. Either that, or it was relatively low priority compared to other things that needed to be fixed. Another "feature" is that when you lay shapes out nicely on the designer, close and re-open the package they can be moved! Which is a nuisance. Andrew Watt MVP - InfoPath wrote in message news:8cf48857-f836-4a83-b5f3-ea3a5246be4e@discussions.microsoft.com... >I have a package with 2 and only 2 tasks in it - which obviously easily > fit onto the control-flow surface at t ...Show All
Software Development for Windows Vista play a stream
Hi,i have the following problem: My computer(client)is connected to a server using a socket.The server sends an avi stream through the socket.How can the client play this avi stream....without saving it on the harddisk Any ideas....sample codes....anything.Thanks You'll need to write a source filter to read the data from the socket and deliver it to the decoder filters. You'll probably want a push-mode source filter (modelled on something like the ball sample), that splits the audio and video and delivers them to the decoders on separate output streams. G ...Show All
Visual Basic Can you create an enum for strings
Is it possible to create an enum list for strings Example, I would like to have a selection of status codes which are "CS", "BP", "MT". And I would like to be able to specify this parameter type in a function call. As far as I know you can only create enums for integers. Currently: Public enum MyStatus stCS = 1 stBP = 2 stMT = 3 End enum I would like: Public enum MyStatus stCS = "CS" stBP = "BP" stMT = "MT" End enum Is this possible Thanks! enumerations must be integer values, however you can utilize a structure for that purpo ...Show All
Windows Forms Throw and Catch Exception--customizing
Can I throw an error message if criteria is met in an if condition, and then catch it with a specialized format. for example if (strTom = "johnny") then throw error catch( ex as error) msgbox(ex.message) --Using vb.net (please excuse any syntax paraphrasing) Throw New ApplicationError -- very interesting... thanks! ...Show All
