lkinney's Q&A profile
Visual Basic Building issue: Import Excel object in a PC without Excel installed
I have a project that needs to use the excel file and therefore I import Excel reference into my project. Everything is ok in my development PC that has MS Office installed. However, I need to build the project in our building PC that has not installed the MS Office. I got the following error during building the project in the building PC: error BC30466: Namespace or type 'Excel' for the Imports 'Excel' cannot be found. ... Any idea Thanks in advance lauch I believe that when you install Office, it installs the extensibility dlls that you're effectively referencing (via an interop dll that's included with ...Show All
Windows Forms Searching files in directories
hi.. how do i search files in a directory using file attributes like modified date,file size,create date time using .Net. Regards dhn Here is a self-explaining example: DirectoryInfo directory = new DirectoryInfo("c:\mydirectory"); foreach ( FileInfo file in directory.GetFiles() ) { if ( file.CreationTime.Date.Equals( DateTime.Now.Date ) { // Found a file that was created today. } } ...Show All
Visual C# sentence case string
How to convert uppercase string to sentence case string in C# e.g. input: HI ALL! I'M A NEWBIE. PLZ HELP! output: Hi all! I'm a newbie. Plz help! Here, I just wrote this as this made me curious. I know this could probably be done a lot better by iterating over a chararray and changing the case depending on flipping a bit to indicate it was necessary but I was lazy and used strings: /// <summary> /// Represents a paragraph in English /// </summary> public abstract class Paragraph { /// <summary> /// Convert a string in arbitrary case to English sentence capitalis ...Show All
.NET Development Assembly.Load to not throw a FileNotFoundException
I'm trying to have Assembly.Load or LoadFrom not throw the FileNotFoundException if the assembly does not exist. Return a null maybe if possible. Using Path.FileExists is out of the question since the assembly can be in the GAC or even in HTTP (as part of a no touch deployment scenario) and I want the checking procedure to be as fast as possible. Any help is appreciated. Thanks, Kousay You can wrap your Assembly.Load call to a bindless try/catch block like this: try { Assembly.Load("not_existing_assembly.dll"); } catch {} Regards, -chris ...Show All
Visual C# Could I "inlcude" a C# source file?
For example, there are three C# project in my solution, and I want to synchronize their version. What I have to do now is to manually edit "AssemblyInfo.cs" file in every project. If there were a way to "include" a C# file, put information common to all projects in that file, it would be much easier to maintain it. Thanks! I think what he want is to have a consistent and uniform metadata for all the asseblies in the solution, and link file is one the best way to achieve this ...Show All
Visual Studio Team System Failed to open a vsp report
After my program exits, a progress bar is shown indicating that the analysis is executed. At the end of the analysis, a dialog appear saying that "Error VSP1743: DIA symbol engine not registered.". If I open the vsp file directly, the same error appears. Yes, Before I install VS RTM, I installed a Beta2 version if VS on that machine. Is the DIA DLL is : C:\Program Files\Microsoft Visual Studio 8\DIA SDK\bin\msdia80.dll After I regsvr32 it, profiler works ok now! Thanks! ...Show All
Visual Studio Tools for Office what is the best method to let the Actions pane refresh?
I have a VSTO Excel workbook that loads a CSV text file 138 MByte big [ --- don't ask why :) ---], chop it in several pieces, format it, and load it in a final workbook. The whole operation takes about 2 minutes. All the logic so far is working great (I am programming it in C#). The only issue I have is that I am using an Actions Pane that tells the user about the progress of the operation. In the pane I have a textbox and a progress bar. Now, I put several progressbar.PerformStep() at several points in the code while the loading, formatting and chopping happen. But because Excel continues working immedi ...Show All
Windows Forms ERROR: Cannot create a child list for field Table
I am coming across a very strange problem where can't seem to bind my datatable to my datagrid. I have two datagrids, where the first is having no problem binding to a datatable. However, my second datagrid keeps getting a "Cannot create child list for field 'Table'". Does anyone know what this error means A snippet from my code is as follows: dsSOItems = SalesOrder.GetStagingItems(stagingDate) If Not IsNothing(dsSOItems) AndAlso _ dsSOItems.Tables.Count = 1 An ...Show All
Visual C# How can I duplicate elements in a windows for - like groupboxes or image objects
Hi all- I am having trouble finding an answer to my problem. I would like to add a bunch of master images to a project, then I would like to loop over an xml file. For each node in the xml file, I want to add a new groupsbox to my windows form. Then for each sub element in the node, I want to add a picturebox object inside the groupbox. Has anyone done anything like this before or know of a way to do this I can work with the XML file with no problems, I am having problems duplicating objects and adding new objects to my windows form. Thanks for the help! Matt The best way to figure out how to add controls to your form is to ...Show All
Visual Studio Team System Project creation failing with error "The identity [Project Name]\Project Administrators is not a recognized identity. "
Error The identity [Test]\Project Administrators is not a recognized identity. Explanation The identity [Test]\Project Administrators is not a recognized identity. User Action Warning TF30144: The New Team Project Wizard attempted to roll back all of the steps taken to this point but was unsuccessful. Contact your Team Foundation Server administrator for further instructions. Here is what Team Project Creation log file says.... 10/20/2005 1:56:17 PM | Module: ELeadServiceMediator | Team Foundation Server proxy retrieved | Completion time: 0 seconds 10/20/2005 1:56:17 PM | Module: Wizard | Retrieved IAuthorizationSer ...Show All
Visual Studio Team System LoadTest - Unable to connect to the remote server
I've been running some load tests and have been getting the following error once the tests scale up to a little over 400 users: RequestFailed: Unable to connect to the remote server If I keep the user count lower, then the error does not appear and it is not linked to any particular test cases or page requests within those test cases. I have verified CPU, memory, threads, etc and everything seems to be OK on the machines in question. I am running the tests locally (ie. no Agent rig) and have also tried running on more powerful hardware. I have tested on both a hyperthreaded dual proc and a hyperthreaded quad proc machine. Both resul ...Show All
Windows Forms GDI+ graphics and viewport
Hello, I am using .NET 2.0 and building a custom control. There are multiple graphics elements that I would like to render on the surface. When drawn together they form the complete control image but need to be managed separately because they might have different scale, units, move indendently, and are updated at different times for different reasons. My idea was to maintain several buffers or graphics objects that I could use draw into and load images as they needed updating. Because the total image is larger then the control - I was planning to copy regions of the larger in memory images onto the control surface - like a viewport ...Show All
SQL Server Calling DB2 SPs using ODBC (Vendor:DataDirect) from SQL reporting Services
We are having the same issue for executing a SP using parameters from SQL reporting services project. Ih the data view of the RDL, with the command type as text and dataset as Dataset1, I wrote this in the generic query designer Call DSNP002.SPODS001( , ) //the SP takes 2 integer in params click the execute button. It asks for parameter values.Put in the parameter values and OK. Error. Error[HY000][DataDirect][ODBC DB2 Wire protocol Driver][UDB DB2 for OS/390 and z/OS]Value of input host variable Num 001 not used; Wrong data type. _____________________________________________ I used the same stuff from ASP.net program ...Show All
Microsoft ISV Community Center Forums Application Error
Hi experts, We have an application written in VBA. The application is failing with the following log entry in the event log. Faulting application: appname.exe Faulting Module: VBE6 Version: 6.4.99.72 Fault Address 0x000dc6f2 Event ID: 1000 The application is running on Windows XP SP2 with Office 2003 SP2. Help would be much appreciated. Thanks Steve Additional information: The application is not a Word or Excel application. It was written in VBA using the VBA SKD 6.2 development environment. We have vba project files that contain forms,modules similar to VB6 project files. The problem here is, ...Show All
Visual Studio Team System UsePropertiesWhereAppropriate vs PropertiesShouldNotReturnArrays
Hi, I'm converting some code to match FxCop rules but I've one problem with 2 looping rules. Here is the code : public decimal[] GetValues () { return m_values; } public void SetValues (decimal[] value) { Debug.Assert(value != null && value.Length > 0); m_values = value; } Warning message is : Cause: A public or protected method has a name that begins with "Get," takes no parameters, and returns a value that is not an array. but THIS IS AN ARRAY what is the solution I can't use property because I'll get a warning that I use an array ...Show All
