Tom T.'s Q&A profile
SQL Server Problems with DTS package
I am working on sql server 2000. here is my question. How can I update a table from the data in a text file. I created a DTS package to do this job. I am able to insert the data from text file to a table perfectly. But What I want is to update the existing row instead of inserting a new row. Here is sample data: text file: col1 col2 1 A 2 B data in the table: Col1 Col2 1 C 2 B Now I want to update the first row for which the col2 is not matching. How can i do this. I wrote a activex script (for transformation) to update but it alwasy trys to insert rather than update, Here is the script. Function Main() if DTSDestination("Col1") = DTSSource("Col001") and DTSDestinati ...Show All
.NET Development Check Network Connectivity - VS2003
Hi, I am using Framework 1.1, I want to create an application which detect when network connectivity and show a message with current state, when network is ready or when lost the connection. In Framework 2.0, I use "AddHandler NetworkChange.NetworkAddressChanged" and it's a good alternative, but it functionality isn't available for 1.1.- Someone knows how can I do it. Regards, Luis R. The patterns and practices team has an offline application block that you can use. Currently the block does a P/Invoke to WinINet APIs. http://www.microsoft.com/downloads/details.aspx FamilyId=BD864EB5-56B3-43A5-A964-6F23566DF0AB&displaylang=en Checking characteristics of the network, connectivity, et ...Show All
Visual Studio Express Editions what is wrong with vbtab
I am new to vb .net but i have used the vbtab with success in vb 6 to read files, however i have been trying to use code below read the file as included but instead of creating any array of currentRow i get only one array of currentRow.. can u help.. Other delimiter like " " seems not to work. Dim MyReader = New Microsoft.VisualBasic.FileIO.TextFieldParser("C:\DATA.txt") MyReader.TextFieldType = FileIO.FieldType.Delimited MyReader.SetDelimiters(vbTab) While Not MyReader.EndOfData Try currentRow = MyReader.ReadFields() Console.WriteLine(currentRow(0) & vbTab & currentRow(1) & vbTab & currentRow(2) & vbTab & currentRow(4) & vbTab & currentRow(4)) Catch ...Show All
Visual Studio Consuming MSSCCI plugins
Hi I am trying to write some software here to help our less technical users intergrate with version control systems. To do this I am trying to create an application that uses the existing MSSCCI plugins out there. I have downloaded the latest SDK from the Visual Studio Integration Partner (VSIP) website (https://affiliate.vsipmembers.com/), and it has been very helpful, but the MSSCCI documentation is (understandably) more geared towards writting a MSSCCI plugin, rather then consuming an existing plugin. I have got some of the basics working, but it has been an uphill struggle. Have I missed something or are there any examples of consuming MSSCCI plugins anywhere Or any help at all would be great! Thanks Kevin ...Show All
Community Chat Unable to download
Microsoft allows me to download windows vista, but when I try to download. there is nothing available at the download loaction ... http://download.windowsvista.com/preview/rc1/en/x86/iso/vista_5600.16384.060829-2230_x86fre_client-lr1cfre_en_dvd.iso the dvd size is 0 bytes. I have probably tried all the things, my pc is up2date with antivirus software, n i have more then 15 gb space free @ that drive where i m downloading, also i tried all the links in that page. I have "download accelerator" installed in my pc, when i try to download anything it display all the detail about that download, as location, saving location, item size etc. but for win vista when i found in the detail as 0 bytes, also on the link 4 brow ...Show All
Gadgets How can I access a local database (.mdb) in gadgets?
can i use vbscript Yes, or JavaScript, as in the example I gave on this thread . ...Show All
Visual Studio 2008 (Pre-release) BindingList<T>, works via remoting but not via WCF
I have a custom list EntityCollection<T> which inherits from BindingList<T> When I try and get one of these custom collections through WCF I get an error similar to that below; >> Type 'System.DelegateSerializationHolder+DelegateEntry' >> with data contract name is not expected. Add any types not >> known statically to the list of known types - for example, by using >> the KnownTypeAttribute attribute or by adding them to the >> list of known types passed to >> DataContractSerializer. Im not using a generated proxy, I am using the same assembly both on the client and the server (this is a closed system) this seems to work fine via .NET remoting - how can ...Show All
Smart Device Development Custom MessageBox UserControl
Hi, I want to make a usercontrol acting as a messagebox for my smarphone project. The idea is that when myMsgBox.Show("Are Your Sure ") is called, a small rectangle box appears on the screen with the specified text, and the menuItems on the form turn to "Ok" and "Cancel". The calling code should block (like showDialog does on forms) and continue when the user presses ok or cancel. The myMsgBox.Sho() method should also return the boolean true or false, depending on the users choice. Psudo-Code: MyFunction() { .... bool result = myMsgBox.Show("Are you sure "); // THIS CODE IS NOW BLOCKED AND THE CUSTOM MSGBOX IS ACTIVE // THE MENUITEMS ON THE FORM HAS CHANGED TO "OK" ...Show All
Windows Forms Windows Installer deployment
Hi, In the help document it tells how to use Windows Installer deployment to create a deployment project as the following: " To create a deployment project On the File menu, point to Add , and then click New Project . In the Add New Project dialog box, in the Project Types pane, open the Other Project Types node, click Setup and Deployment Projects , then click Setup Project in the Templates pane. ......" But there's no "Setup and Deployment Projects" template in VS2005 Express, isn't it So I cannot use Registry Settings Management in Deployment to add registry keys and values during installation. How can I access registry keys and values What are the functions Thanks. ybc ...Show All
Visual Studio Load Report Failed in VS 2005 - additional info
I have a VB 2005 app with a CR viewer and CR report designed in VS 2005 (version 8). The app is run from a network share. The report is connected directly to an SQL Server database and filters records based on a parameter from the app. The report has a few subreports in it. The report loaded fine for me when I ran it with my personal computer logon and admin logon. However, when using a test logon without admin rights, I got this error when trying to run the report: System.Exception: Load report failed. ---> System.Runtime.InteropServices.COMException (0x80004005): Access is denied. at CrystalDecisions.ReportAppServer.ClientDoc.ReportClientDocumentClass.Open(Object& DocumentPath, Int32 Options) at CrystalDecisions.Report ...Show All
SQL Server Export to MS Excel carriage returns
I have a report which has multiple fields in the same column of a table. So that it formats correctly, on the stored procedure side I inserted char(10) + char(13). This allows the next field to correctly carriage return on the report. The report looks great. But once the report is exported to MS Excel, it appears to add in extra carriage returns. This can be cleaned up by going record by record and back-spacing over the carriage returns. Is there any other work around for this Just curious. Thank you for your help. T.J. I haven't found one as yet. The other minor annoyance is that when you open the exported report in excel the cells with carriage returns all have the same row height and hence ...Show All
.NET Development Async File Copy
Hi everyone, I'm sure this has probably been asked before but I couldn't find it using the forum search. Is there a way to copy a file asynchronously (with a progress callback/delegate) I've tried googling, but just keep getting articles complaining how the File.Copy() isn't asynchronous. I managed to use the WebClient class to copy files how I want but it doubled the time it takes to copy files which is unacceptable since I'm copying large numbers of large files (100x 1 gig files). I believe it can be achieved using the WINAPI FileCopyEx but this results in unmanaged and messy code. Thanks in advance. DragonWolfZ wrote: Thanks guys, but I'm more ...Show All
.NET Development Memory leak when changing tray icons
Hello, I'm written a small programme in C# 2005 which works fine and animates the tray icon from an Image list but there's one big problem with this. Although the everything runs smoothly, this swapping of images from the image list is causing a memory leak of 16KB/s. I don't know how to stop this! The code is placed inside the tick event of a timer. At the top of the file I've declared Boolean OrigImg = true; I've tried disposing of the icons in the finally clause and I've created bitmap, assigned the image from the image list and then disposed of the bitmap itself but the memory still goes up. The only time it decreases is when the application is minimised. I've read on other forums to insert a GC.Collect(); in the finally clause and th ...Show All
Software Development for Windows Vista custom sql persistence
What I'm basically doing is deriving from the SqlWorkflowPersistenceService: public class SqlWorkflowStepPersistenceService : SqlWorkflowPersistenceService { protected override System.Workflow.ComponentModel.Activity LoadWorkflowInstanceState(Guid id) { Guid StepID; byte[] State; if (RetreiveNextStepData(id, out StepID, out State)) return WorkflowPersistenceService.RestoreFromDefaultSerializedForm(State, null); ...Show All
Visual Basic Null Reference Exception
I am having a problem with a multi-form application I am writing in VB .Net 2003. When I transition back from one form to my startup form, I get an intermittent Null Reference Exception. Sometimes it will work, moving back and forth from form to form with no problems for 15-20 minutes, and sometimes it will crash everytime. I have tried putting a try-catch block around the instantiation of the main form. It does not catch anything. The exception points to line 2 of the startup form, which reads: Public Class frmWelcome Not much to cause a problem there, I would have thought. I am attaching the code for bringing up the welcome screen in hopes that someone will see something I am not thinking of. Try Dim welcome As New frm ...Show All
