knuckle05's Q&A profile
Windows Forms refresh the data table disable to select
hello, i have a problem with refresh the data table function in the tableadapter. It is disable and not allow to select, how to fix it thx table desc: 1 unique primary id no special character I have also discovered that you have to have a primary key defined on the table for this option to work. If you don't the check mark disappears after you save your changes. ...Show All
Visual Basic How to erase the first line in a image?
I have drawn some lines on a image(for example a map ),now i want to erase some of those lines .How do I do so that i can not left the mark .(i have to cover the line with background color that i want to remove ) One way might be to create a collection that you add each line to as it's drawn to the image. Also keep a copy of the original image (before any lines were added). Then if you want to erase a line, you can remove it from the collection and then recreate the image by taking the copy of the original and drawing all the lines that remain in the collection to it. ...Show All
Game Technologies: DirectX, XNA, XACT, etc. How to monitor microphone input level?
I'm using VB.net with Framework 2.0. How to monitor the mic level of the default soundcard I would like to be able to set a threshold value (0-100%) and when the mic level is greater than that a message box would appear. It would be important that the detection would be fast (with as short delay as possible) and consume CPU resources as little as possible. Is this possible without DirectX SDK I found some code in VB6 and C but could not translate them in VB.net. Thank you! I don't believe that the .NET classes include such implementation, DirectX would be the best way for this as it contains everything you need in regards to multimedia (video and audio) I will move this thread to the DirectX forums wh ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Trouble with XNA Game Launcher
I am having some trouble with the XNA Game Launcher... I have had it up and running since December, but today for some reason, whenever I launch XNA Game Launcher(while signed into Xbox Live) it tells me it could not establish a connection with Xbox Live. So I decided to delete XNA Game Launcher and redownload. When I go to redownload it, it will not let me do so. The download acts like it wants to start, then freezes at 1%. I thought at first something might be wrong with my connection to Xbox Live, but I just started downloading the demo of Alien Hominid, and it is at 97% right now... Anyone else experiencing any trouble at all Well..I suppose that means its something on my end. Can anyone think of any reason why I wou ...Show All
Windows Forms ContextMenuStrip check boxes to work like RadioButtons?
I am using a ContextMenuStrip with a number of ToolStripMenuItems added to it. These ToolStripMenuItems have a Check, and I want the Check to work like RadioButtons, so that when I check one item all other items are set unchecked. Obviously, I can do this programmaticaly on the click event. However, is there an easier way to do this Thanks, Michael follow sample add radio button to contextmenuscript, check it if fit your need using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Text; using System.Windows.Forms; namespace CS { public partial class contex_menu : Form { ...Show All
SQL Server Beginning with SQL Express
Hi everyone, I want to set a database which will be made of two parts: - One main set of files which is shared among users - Another set of files which is proper to each users and will be mainly used for processing infos. Because I must support Windows 2000 and XP as O/S platforms, I can't use SQL Everywhere. It seems that I'm stuck with SQL Express. My questions are the following: - Can SQL Express manage database files with variable namepath - How can I configure SQL Express so that such a file may reside on a dynamically configurable path, I mean, which would be configured by application Many thanks in advance for your help, Stephane I'm still not clear on what is contai ...Show All
.NET Development Convert date in textbox to either datetime or null
Hi, I have built a simple search procedure to query an orders database by company name, contact name etc and one of the fields I would like to search on is the order date. I have a masked textbox that can optionally be populated and if it is I want to do the search to include this. Stored proc looks like: create proc search_orders ( @company_name varchar ( 100 ) = null, @order_date datetime =null) Calling code looks like: this .orders_searchTableAdapter.Fill( this .ordersDataSet.orders_search, company_name, order_date); I can pick up the strings (company name) using the .Text; property of a textbox, I then check if it == "" and if so set it to null (I've discovered strings are allowed to be null ...Show All
Visual Basic How to initialize a Structure in VB and how to create an instance of the structure that is created.
Hi. I have 2 programs which are: a DLL in C and a VB application that uses DLL functions. Flow: The VB application calls the functions in the C DLL and also VB aplication passes some arguments to the functions of the C DLL. My Query: I have a structure whose pointer has to be passed as an argument to the DLL function.How can we initialize a structure in VB. Is there any way to pass the instance of the structure(for example in C we pass the pointer to the function to access all the members of the structure) Eagerly waiting for the reply. Thanks in Advance This is the same question posted previously, and as such, eliciting the same response: Sorry, but this forum is for VB.NET or VB2005 questions, NOT VB6. ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Serializing CustomVertex
Microsoft.DirectX.Direct3D.CustomVertex is not marked as Serializable, so an array can not be Serialized. Is there any way to overcome this Thanks. Let me be more specific for the extra intelligent perfectionists: How do I serialize an array of CustomVertex.PositionNormalTextured items (or any other of the many types). For example: Public Vert() As CustomVertex.PositionNormalTextured ReDim Vert(nVerts) Dim FS As FileStream = New FileStream(fname, FileMode.Create) Dim BF As New BinaryFormatter() BF.Serialize(FS, Vert) This does not work and gives the following message: Type Microsoft.DirextX.Direct3D.CustomVertex+PositionNormalTextured is not m ...Show All
Visual Studio Express Editions ToolStripMenuItem.Click ?
hi all, i am new to c# and i have some dificulties with a ToolStripMenuItem. i designed a gui (windows forms) with vs and wanted to lay some functionality on my menu items. unfortunately i couldn’t. :-( i’ll paste some code below, which will describe, what i have done so far. my menu has one item so far - called "modul", this item has one subitem - "ausbildung" . what i want is, to call a method, when i click on the subitem "ausbildung" - would be great if someone could help. thanks in advance, k this.Menuzeile.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.modulToolStripMenuItem}); this.Menuzeile.Location = new System.Drawing.Point(0, 0); this.Menuzeile.Name = "Menuzeile"; this.Men ...Show All
Windows Forms list box and datasets
hey, how do you make it so that a list box shows the items on a dataset Thanks :) Well, the user has to be happy so I guess I will not do it that way... So becuase I dont seem to like using datasets(due to dificuly of getting it to work with my controls) I will directly save it to a XML file...and when the form loads it will take the info from the XML file and put it in bookmarks and listbox... But here is the thing, when the user clicks on add bookmarks it opens a form I made called Addbookmarks and in that form you type in a textbox what you want to name the bookmark(the name that you will see in the bookmarks list) how do I..well hold on let me try to make the XML file first and then see what ...Show All
Visual FoxPro VFPOLEDB.1 trouble returning large dataset
My asp.net web service uses VFPOLEDB.1 to connect to a legacy app free-VFP table. Of the five function calls to this table one is giving us trouble. In fact they all work in development and on a practice server but during real deployment this particular function balks. The troubling function call returns a pretty good sized dataset (1150 records) but after working for a half hour or so then decides to return an error of 'file not found' and continues to do that for another large block of time which is not very helpful because the other functions use the same connection string and work fine. The call to this function happens every 1 minute from a polling through my web service by another company. To me it almost feels like a resource ...Show All
SQL Server Problem installing SQL 2k 32bit on Windows 2003 64bit x86 SP1
I've been having no luck trying to install SQL 2k 32bit on Windows 2003 64bit x86 SP1 - I've found several articles regarding needing to put SP4 on the 64bit OS, but my problem is the SQL 2k 32bit ",,\x86\setup\setupsql" won't run. I consistantly receive a "...(localuserdir)\Local.ins. Unable to load installaion instructions. Error 703." And of course, the SP4 setup won't run because there is not an existing SQL Service to upgrade. Anyone come up against a similar problem Thanks! ...Show All
Visual C# How to Iterate through List or IList
i can add the values to the IList or List, if I need to get these values in the way they went it...Say I added 5 addresses to the list and I want them one by one... I can use foreach and get all, but I need a way to only get one at a time or two at the max as I need to update some textboxes... First When I do this : if(something[0]) // Cannot implicitly convert type 'object' to 'bool'. An explicit conversion exists (are you missing a cast ) Then If I try to conevery to bool by doing this Convert.tobool(something) // Thats where it throws an exception... ...Show All
Software Development for Windows Vista Protected Registry key access under Vista.
I have code which works on 2k and XP, which, when run under an administrators account, changes the permissions on a hardware/enum key in the registry so that we can make changes to a value for our device. Normally the local administrator does not have this access but creating a new DACL for the account, then opening the key with WRITE_DAC access and setting the new access allows opening the final key with write permissions. This has stopped working in Vista. Everything about the procedure including AllocateAndInitializeSid, InitializeAcl, AddAccessAllowedAce, InitializeSecurityDescriptor, SetSecurityDescriptorDacl goes off without a hitch just like under 2k and XP but then RegOpenKeyEx with WRITE_DAC access fails with Error 5 (Acess Den ...Show All
