Recent content by Berry-tan

  1. Berry-tan

    Update SP - to show users logged in.

    It probably runs, but most definitely will not do anything to your database. The correct syntax is: CREATE PROCEDURE SP_UpdateStaus ( @Status BIT, @Email VARCHAR(50) ) AS UPDATE Schoolmates SET Status=@Status WHERE Email=@Email; RETURN
  2. Berry-tan

    How to create reports with data from multiple tables?

    I noticed that you're trying to join two tables. But before I make a suggestion... What's the entity relationship between tables "Account" and "Student" -- does a student have more than one account or does an account belong to more than one student?
  3. Berry-tan

    Multi-threaded TCP redirection (proxy)

    I'm writing an HTTP proxy server program. It's multi-threaded and the server part (where the local computer accepts a TCP connection and gets the server name and headers) works fine. It reads the headers, builds a new header, and sets it up to be sent. From there, all the proxy needs to do is...
  4. Berry-tan

    Delete a row in a dynamic table - place help

    You could create a stored procedure to delete one specific record, but that might be overkill. Here are a few of my recommendations: Use an AutoNumber as a primary key (if you're not already doing so). Use the primary key to refer to a row to delete. That way, you can prevent SQL injection...
  5. Berry-tan

    Load a entire column into a combo box

    Oh, well that's easier than. I thought you wanted to combine different columns from each row into just one column. Here's how you do it: Go to the "Data Sources" tool window. Expand the table you want to get the data from. Highlight the column you want to be made into a combobox. Click the...
  6. Berry-tan

    deploy with an Access database

    When you added the Access database to your VB.NET project, it should've asked you if you wanted to add the database to the project. Hopefully, you chose "Yes" (Visual Studio would have made a copy of the database for itself).
  7. Berry-tan

    Need help Delete Record from Access DataBase

    Your table adapter (LoginTableAdapter) is missing a valid DeleteCommand, which should have been automatically generated by Visual Studio. Try the following: Open up the .xsd file that holds the dataset. It's in the "Solution Explorer" window. Click the "Table Adapter" part of the Login table...
  8. Berry-tan

    Load a entire column into a combo box

    Are you sure you want an entire column? Multiple columns typically have multiple data types.
  9. Berry-tan

    Converting a bitmap to byte array

    It appears that you're trying to load the entire file, and not just a mapping of bits, into the byte array. What you could try to do is to "skip" the first 53 or so bytes, which is the approximate length of the header, and just store the bitmap (see: Windows bitmap format). I'm assuming there's...
  10. Berry-tan

    Frequency of letters finder

    Is this in VB.NET or VB6? I'm assuming .NET, which is probably why my answer is far shorter: Private Function CountLetters(ByVal Input As String) Dim intLetterCount(26) As Integer Dim CurrentChar As Char Dim Summary As String = "" For LetterCount As Integer = 0 To Input.Length -...
  11. Berry-tan

    Serial Key

    I'm not sure what serial number you want, but here's how you can get the Product ID (just as unique as the 2000/XP serial #, by the way): Dim ProductID As String = Microsoft.Win32.Registry.GetValue("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion", "ProductId", "")
  12. Berry-tan

    Data Reader woes!!

    While your VB.NET code may be sound, your approach to getting the newly-created Customer's ID is flawed. Imagine if two John Smith's in Manhattan were in your database: which one would show up? Since you're using Microsoft Access, I'm going to assume it's a single-user system. What I would...
  13. Berry-tan

    DataGridView (With Relational Data)

    Each DataGridView object is bound to a TableAdapter object, which stores all the required SELECT, INSERT, UPDATE, and DELETE statements that are automatically run when you load, insert, edit, or delete a record, respectively. VB.NET can automatically generate the queries with tables that only...
Top Bottom