Rahul Thathoo's Q&A profile
Visual Studio Team System Getting Constructor Passed Parameters
I've cast an SqlParameter Newobj opcode's Value parameter to an InstanceInitializer class. I'm trying to find out if the second passed parameter in the constructor is of type HttpContext. I could do this by walking the IL around the Newobj instruction, but I'm wondering if there's a simpler way using the Parameters collection of the Instance Initializer class. I have tried: InstanceInitializer createdObj = methodInstructions //emoticons/emotion-55.gif" alt="Idea" />.Value as InstanceInitializer; // Some checking of number of parameters, etc here if(createdObj.Parameters[1].Type.DeclaringType.Name.Name == "HttpContext") { & ...Show All
Visual Basic userDeletingrow event handler (DataGridView)
I have the following code in my windows app: Private Sub UserDeletingRow( ByVal sender As Object , ByVal e As DataGridViewRowCancelEventArgs) Handles RTDataGridView.UserDeletingRow ProRec.Text = RTDataGridView.Rows.Count End Sub ProRec is just a label on the form displaying the current number of rows in the datagridview. Now, if i delete a single row, i don't get any change on prorec However, if i delete MORE than 1 row, it all works fine. Any suggestions please ...Show All
Visual Studio Getting files by label failure - VSS 2005 beta (8.0.50215.44)
Hi, I'm trying to get files by label and get this error: " SourceSafe was unable to finish writing a file... " I work with VS2005(beta), and the VSS database is on the shared location in the internal network. When I ran "C:\Program Files\Microsoft Visual SourceSafe\analyze.exe" -F -V3 -D " \\myserver\vss\data ", I've got following messages (many of them): "A timestamp in the log for .... is out of sequence" "There is a diff chain size mismatch in file .......... at version ... (versions earlier than that version can no longer be retrieved from the database)" What do I do wrong What should be ...Show All
Visual Studio Express Editions Print text from inside textbox
i want to be able to print what ever text is in my textbox1. how do l do this Look up 'printing' in Help. Specifically, Printing.PrintDocument has a printing example under the constructor method. From there you can link to anything you need to know about printing. ...Show All
Visual Basic exposing c header file
i am looking for a c parser that would parse a c header file into xml or a format that will allow me access the strutures defiend in it Does any one know of an api or something that lets you open up a c header file and exposes it's metadata as xml. i was wondering since this is a feature used in code itellisence. I have a need where i need to parse through a c header file which has a whole munch of typedefs i need to be able to find one that i am looking for and return the variable defined in the typedef. kind of like a meta data of the c header file example sample c header file content typedef struct ABC{ CHAR variable1[3]; ...Show All
Windows Forms TreeView label edit
I’m trying to implement renaming of a single node in a TreeView and running in to a problem when I try to keep the node in Edit mode IF the name does not pass validation. (Similar to the way how file explore does it if you enter “< > or |” in the file name. My code (below) is based on the code from the MS Help file but after error message is displayed node is NOT kept in edit mode. Any one know of a way this can be done private void m_treeView_AfterLabelEdit(object sender, NodeLabelEditEventArgs e) { NavigationNode updatedNode = e.Node as NavigationNode; string errorMessage = "Group name must be in the fo ...Show All
Visual Studio Team System TF command line checkin
I am trying to update our old vss command line scripts to be used with Team Foundation Server. I have successfully tested the tf get , tf label and tf checkout commands. However when I run the tf checkin command it returns 'No files checked in' I am using this command line: tf checkin /comment:"Doing a new build" /override:"Build process commandline checkin" /noprompt On the screen I am seeing the check in policies that are not being meet (in yellow), then a line saying policies have been overriden (in blue) then 'No files checked in'. If I just type tf checkin and go through the GUI the files are checked in. Am I missing something or is ...Show All
Visual Studio Need to run CLEAN SOLUTION to get a new compilation
I've been working with vs2005 for a few months - all ok. 'Suddenly' when I hit F5 to run in debug mode I get the previous build - without debug info. When I run Clean Solution and then F5 everything is ok... Any ideas thanks, John Hi John, can you give a bit more background, e.g. if there are any websites/webservices in your solution and in which kind of project you get the weird behavior Or try the following first: See Tools > Options > Projects and Solutions > Build and Run make sure 'Only build startup projects...' is not checked -> Check the other settings on that page as well! Open y ...Show All
Visual Studio MSBuild functionality
Does anyone know if you can use MSBuild. For an build project. For example: Code to build an program from multiple programs. And to make startup forms ect. Using the file Not sure what you mean here - but MSBuild is a build engine that is used for building managed applications, and Visual Studio uses it as the build engine for building your applications. MSBuild allows you to also build your projects without having Visual Studio installed - and this is ideal when you want to run your builds on a build box that does not have VS installed. That's only the 50,000 foot view - for more details on MSBuild, you can refer to the MSBuild docum ...Show All
Smart Device Development unresolved external symbol __CxxFrameHandler3 or __ArrayUnwind
I am building my application targeted for the PocketPC platform. The app builds for Win32 fine. I get one linker error when I build now: LIBCMTD.lib(ehvccctr_ce.obj) : error LNK2005: "void __cdecl __ArrayUnwind(void *,unsigned int,int,void (__cdecl*)(void *))" ( __ArrayUnwind@@YAXPAXIHP6AX0@Z@Z) already defined in ccrtrtti.lib(ehvecdtr.obj) If I remove the LIBCMTD.lib by adding it to the ignore libraries, then I get this error: IconWin.obj : error LNK2001: unresolved external symbol __CxxFrameHandler3 (>280 times for different modules) plus one other error: tSkinnedWindow.obj : error LNK2019: unresolved ex ...Show All
Visual Studio Tools for Office Order of selection events with Bookmark controls
Hello, I have created a simple VSTO Word project with two bookmark conrols: [BOOKMARK1] [BOOKMARK2] They appear in this ordert in the document. I have added handlers for the Selected/Deselected events, and I am getting strange results: When I select BOOKMARK2 and BOOKMARK1 is selected, I get: Deselected: BOOKMARK1 - Selected: BOOKMARK2 Then, if I select BOOKMARK2 while BOOKMARK1 is selected I get Selected: BOOKMARK1 - Deselected: BOOKMARK2 The event sequence is inverted compared to what one would expect. I do not know if this behavior has already been reported, or if I am doing something terribly wrong, ...Show All
Windows Forms Detecting mouse click location for a DataGridViewCell
I have a ContextMenuStrip in which different options are shown depending on which cell of a DataGridView the user clicks on. My problem is that I am unable to get the x & y co-ordinates of cells. I get the mouse position by using : Point mouse = MousePosition; I tried getting the cell's location by saying: Rectangle cell = dataGridView.Rows[r].Cells[idx].ContentBounds; cell.Offset( this .Left + dataGridView.Left, this .Top + dataGridView.Top); However, the cell co-ordinates I get are completely wrong. Any ideas Thanks for the help in advance guys! Private Sub MyDataGr ...Show All
Visual Studio Tools for Office How do I add new Tab in the default contacts window?
Hi! I'm starting a project in VSTO and I need help in adding a new Tab button along with "General", "Details", etc. in each individual contact inspector window. Your help will be greatly appreciated. thank you! Rajat rbshrestha , To add a new tab to the Contacts window, you need to modify or extended the Contacts Form. I would suggest you to learn about Outlook Custom Forms to get started with it. Outlook Form designer can be reached through Tools > Forms > Design a form... menu item. Pick the Contacts form and you are ready to go. You might be able to use Outl ...Show All
Visual Studio Team System Change priority from integers to strings
I've been customizing the Work Item template in the MSF Agile template. So far I've made good progress in implementing the states (Active, Closed etc) that we currenlty use. For Priority, we currently have High, Medium, Low, Memo but when I change the Microsoft.VSTS.Common.Priority type from Integer to string and added these values, it throws the following error when I import the template: Exception Type: Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ProvisionValidationException Exception Message: TF26038: Field type for Microsoft.VSTS.Common.Priority does not match the existing type. It was Integer, but now is String. ...Show All
SQL Server lookup and commit; How it works
Lookup and commit; How it works I am importing data from text file and I have data lookup to check reference table. If the reference row doesn't exist I want to add row to reference table, other wise row is added to the detail table. I am using oledb destination to saving reference table row with rows per batch to 1 and maximum insert commit size to 1. When I run the package duplicate rows are in grid view. How can duplicates end in there the commit size is 1 Next time the data exists in reference table and should be going to detail not to reference table. Funny but this was just answered in ...Show All
