Red300's Q&A profile
Visual Basic ComboBox Frustration: Setting a default "SelectedIndex" when adding a new record refuses to work.
Help! This is a very frustrating problem. Ok I have a typical databound Form with a bound ComboBox bound on the form Load event. I have a typical BindingSource and BindingNavigator Control with an "AddNew" button. When a new record is added to the dataentry form (i.e. not the combobox) I intend the combobox to default to the first value in the list by setting... mycombo.selectedindex = 0 I have this in the BindingNavigatorAddNewItem_Click event but it has no effect! I also tried placing mycombo.selectedindex = 0 in the BindingSource "AddingNew" event but this also has no effect. I have discovered that the "selectedindex" is somehow inexplicably changing itself back to -1 As an experime ...Show All
Visual Studio Tools for Office How to make certain menu invalid or disabled
I want to disable certain menu like " F ile->Print" or "File->save as" in Office Word. Does vsto can do this and how or is there any other technology can achieve this Thank you very much. Thank you for you answer. Your code can make all the command bar invisible, but what I want is make one of them disabled(cannot be used), and make one of menus not useable. And user cannot make it useable when he/she use it. And thank you all the same. ...Show All
Visual Studio 2008 (Pre-release) c++/cli wcf client
Anyone have any examples on building WCF clients using c++/cli. I have generated the H file using the mex interface from the server, but the c++ header file is not a friendly as the c# generated code. ...Show All
Visual Studio Microsoft TV Plugin for VS 2005
Hello, Is there any plugin for microsoft TV application development for VS 2005 Please help me on this. Thanks Sajal Mahajan ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Correct material order
I have noticed that it is vital to draw subsets/materials of a mesh in the correct order. My modeller has given me a .x mesh file exported from 3DS max... When I draw them in order 0 to 80, some subsets appear infront of others where they should be behind; where if i draw in the reverse order (80 to 0), the scene is completely wrong... So, how do you draw in the correct order Is this something that must be done in 3DS max, or can it be done at the DirectX level I have solved this problem. It was simply through not using a Z-buffer. I read this tutorial, which made everything nice and clear: http://pluralsight.com/wiki/default.aspx/Craig.DirectX/ZBufferTutorial.html ...Show All
Visual Basic Sub Main
How can I collect data from the registry before showing the main form. Hey bro, this is the exact method and should work May be in your code (in the form's activate, load event) you might have written something that closes the form. Please paste the sample code that you are trying so that i can give you a better support. You also need to change the Form Startup Object to "Sub Main" from Project > Properties. You can alternatively try Application.Run(frmServer) instead of Those 2 lines that creates an object of the form and then call the .Show() event. ...Show All
Visual Studio Express Editions Event Handlers and Raiseevent issues
Hi, I seem to be missing something here!! I am looking at the process of Event driven coding and I am a bit confused. If I understand it correctly all I need to do is: 1) Within the form that will raise the event declare the event with the event key word and raise the event Public Class Form2 Public Event xevent() Sub raiseevents() RaiseEvent xevent() End Sub End Class Within form1 create an instance of form2 with the withevents keyword Public Class Form1 Dim WithEvents eclass As New Form2 Private Sub eclass_xevent() Handles eclass.xevent MsgBox( "test" ) End Sub End Class The issue I have is the above only works if I call the form2 raiseevents ...Show All
Visual Studio Express Editions Multiline TextBox and pre/appending lines
Basicaly I have alot of txt files I need to format, but also need to make a few changes to them while formatting them. So figured it would be a good time to get my feet wet in VB Ok, so, what I need to do is have 2 multiline text boxes with a 'format' button. First one paste in the original text, second to show the formatted text. Easiest design for what I need. I've spent a few hours getting familar with the VB IDE, now time to dig in and do things. I have my 2 textboxes, mulitline, my button, even added some label texts to jazz it up. Created an click event handler for the button, and started reading about how to access the contents of the textbox1. Now to my quandries. How would I access the textbox information as an array of ...Show All
Visual Basic Two REALLY noobish questions
Well I decided to switch from VB 6 to VB 2005 Express. Been working with Express a bit and like some of the features. There have been several changes and I am still trying to learn some of this new stuff so bare with me. I have the basic stuff down but need to know a few easy things.\ First: I have buttons and each different button I want to load up different Word Documents(.doc). I basically just want to click on the button and it will load a file specified to that button. The file will always be in the same directory and will never change. I just need to click on the button and have the file come up. Second: Set up a menutoolbar. Want there to be File > Exit Just need to program the "Exit" part to unload the program. Hopefu ...Show All
Visual Studio CR Licensing Requirements
I am in the planning stages of moving a fairly large app from Access to ASP.NET 3 / C# / SQL Server 2000 and am investigating report generators. I am the sole developer of the app outside of testers and sporadic subcontractors. The new app will have both a Win forms solution and a web forms solution. Using the CR which came with VS 2005, I am wondering what the licensing requirements for my client would be. There will be up to 40 users or so on the Win forms app, and maybe 20 more or so on the web forms app, but I would think that only one or two web users would be connected at a given instant. On the Win forms side, the generation of reports and spreadsheets is pretty intense, so it is easy to imagine up to 20 or so generating reports ...Show All
Visual C++ Manifests in VS2005-- What are they?
In my experience, manifest files have enabled the Windows XP control themes in applications. That is all I know about them. Can anyone explain what manifests are, and how they are used I also noticed that Visual Studio 2005 Professional supports embedding manifest files. Does this mean the IDE is capable of automatically making applications support Windows XP control themes Thanks ahead of time. I tried with adding manifestodependency through linker command line as below /manifestdependency:type='Win32' name='Microsoft.Windows.Common-Controls' version=' 6.0.0.0' processorArchitecture='X86' publicKeyToken='6595b64144ccf1df' language='*' But while compiling i am getting an error LINK : fatal err ...Show All
Windows Forms passing data into another form
Hi, I have the following code, which works perfect, when I makes af DataGridView with drag and drop (the code pass over the FakturaId to the new form, so I can make a select on this) System.Data.DataRowView SelectedRowView; fakturasystemDataSet.FakturaRow SelectedRow; SelectedRowView = (System.Data.DataRowView)fakturaBindingSource.Current; SelectedRow = (fakturasystemDataSet.FakturaRow)SelectedRowView.Row; FakturaVis FakturaVisForm = new FakturaVis(); FakturaVisForm.LoadFakturaVis(SelectedRow.FakturaID); FakturaVisForm.Show(); But now I have made my own dataset and adapter and I have some problems with the above code. I don't know, how I get the FakturaRow in intellisense (how I get this into the code, where I instansiate the dataset an ...Show All
Audio and Video Development Problem with 'content ID' while creating directory in 'persistent storage'.
Hello Everybody.... In the java script for creating a directory (FileIO_createDirectory), do we have to specify the content id also If we don't specify, whether the directory will be created or some exception will be thrown I am giving two examples below, please tell in each case what will happen. 1. FileIO.createDirectory("file:///required/app1",callback_createDirectory); 2. FileIO.createDirectory("file:///required/11111111-1111-1111-1111-111111111111/app1",callback_createDirectory); Hello to Everybody.. I am really getting confused about who specifies the content ID and how can be there more then one Content IDs possible..... Please see if anybody know about this.... thanks in advance Azaz ...Show All
SharePoint Products and Technologies Supplying a default value of a parameter for a class that can't be instantiated directly.
I'm calling a webservice method that requires an XmlElement as a parameter. For example: public void MyMethod(XmlElement MyXmlElement); XmlElement objects can't be instantiated directly. In code this is no problem as I can grab the XmlElement from my XmlDocument, however I don't see a way to do this using the BDC. Any help would be greatly appreciated. COmplex Paramenter types would be possible but you have to be crafty in your XML for the BDC... I played with it a bit and got some to work but never quite as good as I would like. Typically in scenario's like this, I build a facade web service that has the methods that I want to call and the simple input types, this service then marshals ...Show All
Visual C# Attribute Problem
Hi all, I have the following problem with using attribute. I declared an attribute class (MyAttribute) with a list of properties. That attribute class is in its own dll. Now I have another class (MyClass) that referenced this attribute class. Everything works fine. But now, I want to add additional properties to the attribute class (MyAttribute). It seems that any new property I added to (MyAttribute) is not recognized by (MyClass). Another test I did was simply adding the new property to (MyAttribute) and use reflection in (MyClass) to simply list out all the attribute property, even that errors out. For some reason, it seems that once i declare an attribute class, I can't add or change it. If I add or change anything, the program t ...Show All
