John Paterson's Q&A profile
Visual C# How To Register Web Part & How Deploy the Web Part To SharedPoint Portal Server 2003
hi I am Using VS.NET 2003 & Working On WebPart Library Project Problem to me is i am able to create web part using ASP.NET User Control and also .dwp file also i am able to update After you make the changes to trust the Web Part, My web.config file will look similar to the following code: <SafeControls> <SafeControl Assembly="System.Web, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" Namespace="System.Web.UI.WebControls" TypeName="*" Safe="True" /> <SafeControl Assembly="System.Web, Version=1.0. ...Show All
Visual C++ How to prevent <oledb.h> being included
Hello, I created a MFC ActiveX project recently, and need to use my own ocdb.h file instead of the oledb.h(the oledb.h seems be included automatically), but I don't know how to prevent it from being included, no "include" of such file could be found in my whole program. sb. pls do me a favour. Thank you very much. OZ ...Show All
Windows Forms .ShowDialog - unusual results
After posting in another forum, I decided this may be best placed in an MS forum. I am developing an application in vb.net, using vs 2003, which has a variety of forms, modules, classes etc etc. One of the more simple tasks I have tried (without any luck) to do, is to open a form as a modal form. That is, to use the .ShowDialog function. Consider this code: Sub Main( ByVal cmdArgs() As String ) Try Cursor.Current = System.Windows.Forms.Cursors.WaitCursor ...Show All
SQL Server Trigger question
I would like to know how many records there are in the INSERTED & DELETED tables at once when a trigger fires. I'm looking at a trigger that checks for COUNT(*) in both tables (INSERTED & DELETED) and will perform a different T-SQL statements base on COUNT(*) being 1 or greater than 1. I always thought that triggers fired for every record in a INSERT, UPDATE, DELETE transaction. If so, there should not be more than one record in neither table (INSERTED & DELETED). That much depends on what you want to achive within the trigger you will have to know that the Inserted / deleted tables exist in ...Show All
SQL Server SQL Mobile Server Tools install on SQL 2000 SP4
I am trying to install SQL Mobile Server Tools (beta 1) on my SQL Server 2000 SP4 server. I have already installed the SP4 Replication Components upgrade and my existing SQL-CE databases replicate ok, however when trying to run the SQL Mobile Server Tools (beta 1) install it fails the System Configuration Check with the following error: "You must first install the Replication Components for SQL Server SP 3a or higher or the SQL Server 2005 Client Connectivity Components" Can anyone assist Stuart Eastland MSDE is a edition SQL Server 2000 which is license-free for use. When I say the paid version, ...Show All
.NET Development multithreading in c# 2.0 and locking an object
i have a winform app in c# 2.0 . i am reading an object's property in the main thread and changing it on a background thread. i am using backgroundworker class. should i lock the object before writing and reading can anyone give me some code samples Yes, you should lock the object if you want threadsafety. If you won't introduce locks then you cannot rely upon object value as it can be changed by the other thread. in the main and background threads you can wrap the code, where you access object properties with lock statments lock(myObj) { //access myObj props here } ...Show All
Visual C++ Where can I get ml.exe
I've just installed VC++2005 Express, and I couldn't find ml.exe anywhere. Where can I get ml.exe (no need for the rest of Visual Studio) Thanks! I don't believe ml.exe is provided now except through VS versions. Unfortunately, VC Express doesn't include ml.exe and it only in the other SKUs. Nevertheless, you are not the first one to ask for it via the Express install. Could you please log a suggestion issue at http://lab.msdn.microsoft.com/productfeedback/default.aspx so that we can try to address the issue in the next release or service pack. Thanks in advance in taking the time to log the issue! Thanks, Ayman Shoukry &nb ...Show All
SQL Server SCD component in SQL2005
Hello, I have problems specifying my historical attribute in the SCD component. Regardless of wich option I choose on the Historical attribute options I cannot choose a field in the table, it is simply empty, nor can I write in the information... I am using the 1st release version so I suspect that this function should be fully functioning. What am I doing wrong and how should I go about this Hanna, The scenario works for me and it should also work for you on your RTM build(1399). I am not sure at this point why you saw date got set at the enddate column, when inserting a new ...Show All
Windows Forms 128 Bar Code Printing
I'm trying to print a 128 bar code but can't find anything in the documentation. It's the first time I'm trying printing in .net and so far I can print text fine with the PrintDocument class. Can anyone help I'm using a Zebra TLP 2844 printer (if that makes any difference) Well you dont have to do anything special for the Zebra printers its the same print document class you can use it for priniting. I use print document class to print and I am using a third party component which basically makes the barcode. The only pain is the alignment but you can use the print preview dialog which will save you lot of t ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Device is ambiguous in the namespace microsoft.directx.direct3d
Can anybody tell me what this compiler error message means. "Device is ambiguous in the namespace microsoft.directx.direct3d" I get the same message for PresentParameters, SwapEffect and CreateFlags CreateFlags I get it when trying to use directx3d in any program, even samples that should compile.. The code is included below. I have checked and double checked that I have all the necessary references, imports and includes. Obviously I am missing something. Thanks Dick Imports System Imports System.Drawing Imports System.Windows.Forms Imports Microsoft.DirectX Imports Microsoft.DirectX.Direct3D Pu ...Show All
Visual Studio Express Editions Getting Data from Excel Spreadsheet to Populate TextBox Controls on Form
I just coded a functionality in my program that with a click of a button pulls up Excel, takes all values as strings and populates the spreadsheet in a particular format, with column names, and even makes a line chart out of two column's data. This was pretty hard to find out how to do but after fits and starts it finally works great. My question now is... I'd like to go in the reverse direction - to open a particular spreadsheet (which will be created new daily and saved to a default folder; with studies of stock market picks, stocks, trade ideas and so on) and bring that data back into my form, back into the original place it came from, ...Show All
Visual Studio Express Editions VWD Express Edition 2005 error
I downloaded VWDEE several weeks ago and have been using it religiously since then. It is a great tool and I have really learned a lot during those weeks. I have now run into a real problem that I can't seem to get a handle on, so I thought I would ask here and see if anyone else has seen this problem. I started having random problems with my really simple ASP application. This application uses a database connection and most of the problems at first seemed to happen when connecting to the DB but I have verified that the DB works well with other programs and I can't find any real indications of DB problems. The first real evidence that I h ...Show All
Visual Studio Team System Accesing build programmatically (API)
I've found a couple of examples to access the build objects (BuildInformation and BuildController) in the extensibility kit but they don't work, some of the libraries seem to be missing (Microsoft.VisualStudio.Bis...). Based on the comments on one of the slides, it looks like the beta 2 release doesn't have this feature yet, is this correct Is it possible to access the build objects programmaticaly in Beta2 Thanks Pablo Ok, this works perfect to launch and monitor the progress of a new build. But how can you instantiate build objects to query their attributes (state, etc.) Thanks ...Show All
SQL Server How connect SQL server 2000 with c#.net .....?
Hello masters, help me yaar i am using dotnet 2003 and SqL SERVER 2000. BUT UNABLE TO CONNECT DATABASE using dataAdaptor(design time ) or sqlconnection any can help me gs whats the error lets see the connection string. make an empty text file called "c:\test.udl" - double click it and try to build a SQL Ole Db Provider datalink. . . can you get that to work Are the TCP protocols enabled in your machines client network settings and in the servers network settings ...Show All
Visual Basic Rotated Text in GDI+
Ok, I won't pretend to understand GDI matrixes :) I've been looking for a simple example to print rotated text, without having to create paths and such, just by applying a temporary transformation to the page. My simple example would be to print "Rotated Text" in a circle patern with the bottom-left corner of the "R" being the anchor point around which the text rotates, something like: Private Sub Form1_Paint( ByVal sender As Object , ByVal e As _ System.Windows.Forms.PaintEventArgs) Handles Me ...Show All
