c_shah's Q&A profile
Visual Basic IDIV - divide be zero: error handling
Hello. I've got a problem. My software crashes and maybe it's because IDIV instruction - division by 0. Please help me how to handle it in VB6 (check value before dividing) . I found articles on that but only Java and C++ and nothing about VB6. Best regards PS. I already posted this question on other forums as well. But thank you anyway. Best regards For VB6 resources please take a look at: http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=478161&SiteID=1 ...Show All
SQL Server Transactional replication delete data
In SQL Server 2005 SP1 we have a Transactional Replication with only this property in the articles: Action: Delete data... Ant this property in the publication: Don't send schema changes We have in the foreign keys NOT FOR REPLICATION = NO (Exigir para replicacion = "Si" in Spanish). We have one problem and one doubt: The problem is that when the sincronization goes wrong the table in the suscriptor is empty !!!!!. It seems that goes wrong because the foreign keys. The question is = Is necessary that NOT FOR REPLICATION = YES in all the tables , we don't want any check in the sincronization. Why the destiny tables appears empty . Is very dangerous. Thanks. Hi, Can ...Show All
Visual Studio 2008 (Pre-release) Adding Controls During Runtime
I have to present inputs (textbox, combobox, etc) that are not known during design time. In the past this was pretty simple to do. You just add a new control to the Controls property of a form. How can I achieve the same thing with WPF Thanks Button btn = new Button(); btn.Content="hello world"; Grid.Setrow(btn,1); Grid.Setcolumn(btn,1) MyGrid.Children.Add(btn) ...Show All
Visual Studio 2008 (Pre-release) Bug? Loading 3rd Party WPF control libraries
I’ve hit what potentially looks like a bug. We are creating and using 3rd party WPF controls in our Aurora XAML Designer, the WPF assemblies were loaded using System.Reflection.Assembly.LoadFile. newDependencyObject = _ElementToBeCreatedType.Assembly.CreateInstance(_ElementToBeCreatedType.FullName) as DependencyObject ; The control is created, but explodes when added to another WPF object. It complains about the version number and has XAML parse issues. Control works fine linked into an application For 3rd party controls to work properly in Aurora we found that the 3rd party control developer must change the following assembly version directive from … // You can specify ...Show All
.NET Development WS-I18N, Web Services Internationalization
Has anyone done any work implementing the WS-I18N header enhancements with an ASP.NET Web Service, or similar Pablo has posted an implementation of it for WCF, you can find the article here: http://www.codeproject.com/winfx/WSI18N.asp I hope it helps. Gabo ...Show All
SQL Server W2K2 SP1 on SQL 2000 SP4 server
Hi, We are planning to apply SP1 for W2K3 on our SQL Server 2000 SP4 host machines. We have are running SQL Server Enterprise Edition in an Active/Passive cluster. Are there any known issues with this Can we simply go ahead with W2K3 SP1 tia. Hi, Refer below KB which says their is a bug while accessing Analysis Serve Performance Monitor which is then fixed http://support.microsoft.com/kb/907813 and List of Updates after Windows SP1 release http://support.microsoft.com/kb/824721 Hemantgiri S. Goswami ...Show All
Visual Studio Tools for Office How to add caspol security settings for referenced assemblies
I'm building an Outlook add-in using VSTO 2005 targeted at Outlook 2003. I've successfully added the SetSecurity project (from the MSDN "Deploying VS2005 Tools for Office Solutions Using Windows Installer" 2 part series) to my solution, which appears to properly configure security for my primary dll when my add in is deployed to another machine using my setup project. However, the SetSecurity project sample doesn't appear to set up permissions for the com objects referenced in my add-in and my add-in throws an error when I run it. Specifically, my add-in uses the CDO and web browser com objects, so I'm guessing I also need to add Caspol calls for the Interop.MAPI.dll and the Interop.SHDocVw.dll to my setup project What's ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Designing C# & XNA games
Hi I'm currently learning C# from a couple of books with the sole aim of being able to use XNA. I have just a couple of questions: At the moment I focusing on console (DOS like),OOPs, and so on. With XNA, is there any point in learning Windows Forms programming Also, I found that understanding & following game code is one thing but being able to design a game (or any program) is another thing entirely. It's hard to code without some higher level plan or visual aid. Are there any techniques or affordable software available that game designers use in the design process. I've heard of things which might be applicable, such as :- Psuedocode, UML process diagrams, he ...Show All
.NET Development Derived types and System.Collection.Generic.Dictionary?
Hi, I have a Dictionary in one of my classes: private Dictionary<string, RobotPart> _parts = new Dictionary<string, RobotPart>(); RobotPart has many derived Classes (Rod, Joint, Body, etc.) . I have a method called GetFlatPartList that flattens out a treelike structure of RobotPart objects, for easy iteration through the child objects. Hopefully, once I hit "post" my tabs will be kept for the following method: EDIT: I took this method out, and placed it in the following post for readability Now, my problem is that my program will crash, giving me an invalid cast exception when I am trying to search (using a for each statement) for any Type other that RobotPart, even though they (Joint, Rod, Body, etc.) are ...Show All
SQL Server SQLExpress, locked files, and sp_detach
I have a situation where I want to copy a SQLExpress mdf file, after having read some metadata from it, but I find that an exclusive lock persists on the file for about 5 minutes after closing... the lock is held by "sqlservr.exe" This lock prevents me from copying the file. It seems that I may be able to fix this by calling sp_detach_db after closing the connection (does this seem reasonable ) but I am unsure what the database name (dbname) is that I need to pass to sp_detach_db. To make this a little more concrete, here is the connection string I use... "Data Source=.\SQLEXPRESS;AttachDbFilename=C:\testdata\DVDCollectionDatabase.mdf;Integrated Security=True;Connect Timeout=30;User Instance=True'" so in that case what ...Show All
Smart Device Development Square screen help..
hello, In my design windows while creating a new project, it asks for qvga or vga but wont show square screen. And the buttons get mis-aligned in square screens. What i need to know is, if i download the emulator image for square screen, will i be able to get the option to develop for square screen in the design window itself Regards Carty.. Hello, Yes, I did see a square screen emulator where the objects are displayed properly. But when the same application is run on real device, the buttons move away. The buttons are in position on the emulator. Why is this and is there any way to fix the buttons on place instead of finding the screen size and adjusting its position programmatically If no, can you please assist ...Show All
Visual Studio How to load a picture in Crystal Reports at runtime?
It is possible to pass a value to a formula field, but how can I pass the path to a bitmap I am using VS2005 Beta 2 --Goos van Beek Keith Thomson wrote: Hello Goos, Unfortunately, it is not possible to pass the path of an OLE Object at runtime using the version of Crystal Reports included with Visual Studio 2005. Keith - Business Objects Sounds like a sad story :( ...Show All
Windows Forms How to handle Combo_IndexChanged event
Hi, i have a datagridview using a datagridviewComboBoxColumn implemented comboboxColumn's indexChanged event successfully and it was working fine till now. Now i implemented dataGridView_CellClick event to use for some other operations but still have no code inside it. I'm surprized with that after handling cellClick event ComboBox_IndexChanged event became dummy and program never use it. Why Or how can i use both cellClick and ComboBox_SelectedIndexChanged events Thanks. In the datagridview's EditingControlShowing event you can add a handler to the combobox's selected index changed event. It is important that you remove the old handler for the event before you add a new one to prevent the event f ...Show All
Windows Forms Icons Curruption
Hi.. I am developing an application using .net 2.0 and tree control. I have some icons which are put into resource files... I put them into Imagelist on application launching. and from the i use them into the tree-icons. After everything works fine in Debug mode. When i switch to the release mode.. icons suddenly disappears. Also after deploying the application are not seen as well. Any one aware of this kind of situations A temporary fix i did was b4 rleaseing.. i copied the resources-dll from Obj/Debug folder to Obj/Release folder and then i made the builded the application into the release mode... After that i deployed the application. For the first launch of the application it worked smoothly... the icons disappeared from the ...Show All
Visual Studio missing pdb
Hi, I am attempting to debug an application consisting of a main executable and multiple dlls. In most cases the debugger can locate the pdbs, and I can regenerate them so that I can debug the dll from the dll project by setting up the dll project to start the main app. However: One dll project does not appear to be generating a pdb at all , even though it is configured to do so. Consequently, I am unable to set breakpoints within that project. I have limited knowledge of the code. I'm looking for suggestions as to why a pdb file would fail to be generated at build time . One difference between the dlls I can debug and this one is that the output directory does not have the default name "bin". It is named 'bin2'. ...Show All
