Add A New Item To The Form?
Nov 10, 2009I would to add a new Item in the form like this picture [URL] how can i do it?I am using vb2008?
View 1 RepliesI would to add a new Item in the form like this picture [URL] how can i do it?I am using vb2008?
View 1 RepliesRegarding my college project. i'm working on a sales system . i have a form which consist of all the following information( item code , item name , item price , quantity of item ) which is display using a data grid . data input by user using text box and all this information will be stored in a database(sales database) i'm using ms access 2007. the grand total will be displayed in a text box . and amount paid will be input in a text box too , my major problem now is how to i create a reciept that will have all this information of the purcase. i have a reciept button . what the next step ? i dont have any idea how to get the reciept done.
Imports System.Data.OleDb
Public Class Form5
Dim con As New OleDbConnection
[CODE].......................
I have been creating a call management application and I am having a problem with something that I have spent weeks on trying to get working and nothing I try is working for me. My application is an MDI application written in VB.NET 2005 Professional, using .NET Framework 2.0. It uses a back end database using Microsoft SQL Server 2005.When the MDI application launches, a form is displayed to the end user asking for phone number (MaskedTextBox) and a partner name. The partner names are within a ComboBox.
When the end user types in the phone number and selects a value from within the ComboBox, s/he clicks on the start button. This then opens a second form. The phone number from the MaskedTextBox is to default in a second MaskedTextBox (this I am able to get working without issue.) The partner name selected from the ComboBox is to default on the second ComboBox. This is the part where I have been working on it for weeks and not able to get it to function.
The second form has many ComboBoxes, all of which pull down items from a particular table within the database. Some of them are editable and some are not. The ones that are editable are also auto complete Suggest/Append on the ListItems.I wrote a sub to handle the population of these ComboBoxes and also to handle if they are editable or not. All of this is working. However, my main issue is that I can't get the value on the second form to default to what ever was selected on the first form. I do not get any errors but regardless of what I do, the second form always stays as the first item in the list regardless.
The code I am using is as follows:
<CLSCompliant(True)> Public Sub PopulateDropDownListFromDB(ByVal cboName As Elegant.Ui.ComboBox, _
ByVal TableName As String, ByVal ColumnName As String, _
ByVal UseAutoComplete As Boolean, _
ByVal UseSQLDistinct As Boolean)
[code]....
I have a list box on the form which functions as a copy/paste. When you copy something, it is automatically added to the list box as a "clipboard helper". Here is the problem,however: if the text is more than 1 line, the list box does not show all the text.It ends up looking messy.So getting back to my question, is it possible to make the list box item height for an item depending on the amount of lines that item contains?This is a one line sentence in the list box and should take up one line.This is a multi line sentence in the list box and should take up two lines for item height.
View 11 RepliesIn my application I have a listbox and SelectionMode should be MultiSimple because users need to see which items they selected. In another tab we have another listbox this one should show all the selection users had done in first tab. Private Sub
[Code]....
im doing a project in vb 2008 with 5 forms. i need form 2, 3, and 4 to send an item that is doubleclick in a listbox in those forms to a listbox in form 5.
View 10 RepliesI have a multiple form application with a listbox on each form. I want to be able to select an item in one listbox on one form and then click a button and it show up in a listbox on another form.
View 3 RepliesI want Add Item to Listbox in Form Load, I Mean Before I Start The Program It Already Shows Items in The Listbox also i want to know how to create a search button so that when i click the search button it search from the items in the listbox if it available it say found it if not it say error !
View 3 RepliesI'm new to databasing. How do you make it so you can add an item to a database on a form, Then follow a link to another form which has the database on, then what you put in on the previous form will be there?
How's it done? Sorry - Haven't been using VB very long >.<
how to use datagrid, that when i clicked or double clicked a data shown in datagrid it will appear in a textbook.
i'm using this codes
Dim Col As Integer = 0
messagebox.show(DataGrid1.Item(DataGrid1.CurrentRo wIndex, Col))
but i don't know how to display the selected item in other form even i had declared a public variable in my module to use.
How to set the cursor of a windows form using VB.NET?
View 1 RepliesAnd this problem:+ I have 2 form. - Form 1 have 3 combobox with some item load from database Access.- Form 2 load data when change item at combobox form 1.
View 5 RepliesI am using vb.net 2008 and just installed crystal report x.I tried opening my project in Vb.net and the problem is I could not see the Crystal reports icon. I wanted to add a new form via Add new item and select crystal reports but it seems that Crystal reports is not displaying...
View 5 RepliesI want to know how I can check with the listview item on my main form to see that if the text property of the selected listview items has got the same text property of the listview on the another form?
I used this:
Private Sub Button1_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim i As Integer
If Form1.ListView1.Items(i).Text = Me.ListView1.Items(i).Text Then
[code]....
The item I have been added after I have got the same item as my form1.listview.items and form2.listview1.items. How can I find with both of the listview items that if both have got the same text property similar as I have created? I am not sure if the form1.listview1.items(i) variable is incorrect.
I have two forms, both with listboxes, and a module with a global variable called strItem.Lstbox1 on my main form is blank, and lstbox2 on the second form has 3 items in it that has a price on it.[code]...
My problem is that if I use an activated event, I notice that if I have a message box pop up by clicking a button, it will add the item in the variable again. But if I use a load event, it doesn't function at all. I think I still need to be using a activated or load event so the mainform will update when I add items from the other listbox, but I'm still doing it wrong?
I have a visual basic 2010 project that has a menu item hidden (visibility). there is a second form (child window) that you can popup and hit a button to show the menu item. I am having trouble finding the right commands to do this. I am use to C and the API where you can get the handle to the parent windows menu, and do it that way. But I have been unsuccessful in VB.
View 4 RepliesI have a combo box on form1 which is linked to a table from my data base. I am trying to get the item selected from the combo box to be a label in form 2.
View 17 Replieshow can I all the import and declare item into a list and use it on every form?
View 1 Repliesmy test:
Public Class Form1
Public Const WM_SYSCOMMAND As Int32 = &H112
Public Const MF_BYPOSITION As Int32 = &H400
[Code]....
and i get an error:
PInvokeStackImbalance was detected
Message: A call to PInvoke function 'WindowsApplication1!WindowsApplication1.Form1::GetSystemMenu' has unbalanced the stack. This is likely because the managed PInvoke signature does not match the unmanaged target signature. Check that the calling convention and parameters of the PInvoke signature match the target unmanaged signature.
How do I make a item on a form working in another one without moving it?
View 3 RepliesI have a combobox on a form which has data bound items, the datasource is a dataset called ShiftType that was created using the new data source wizard. The data consists of three columns ID, Name ,Description. Name is the display Member and ID is the value member. This form is called from a different form, a variable containing the shifttypeid is passed as a parameter. I am able to get this parameter across fine.
What I would like to be able to do is, match this parameter with the data in the dataset and find the row index and set that item as the selected item of the combo box. I am confused as to how to proceed with it. Also, I would like to add an extra item to the dataset apart from the items obtained from the database. This represents "NONE", i.e. so if the user doesn't want to choose a shift type they can use the None item. How do i add this without having to add a dummy value in the database.
How do i get my first item to show in combo box when form has loaded?
View 6 RepliesIs it possible to compare 2 dataitems and then display the result depending on the 2 values using if eval at run time?I have a ListView with databound controls. 1 is RedemptionChoice and the 2 is CashBack.When 1 reads "0" and 2 reads > 0.00 the output should read AUTO I have read many comments online and most point to create a new function within code behind but have found it impossible to implement on my own.I tried this as a test on the actual page:
<%# If(Eval("CashBackRedemptionChoice").Equals("0") & Eval("[CashBack]").Equals("0.00"), "Auto Cashback"))%>
2 needs to be greater than 0.00 for AUTO to be displayed. Hence I know this would not work. Just trying to give an example of what I would like.
I've got a TCP Listener running on a separate thread. I want to have it log the incoming and outgoing messages in a list on the form instead of in message boxes. I've been reading about multiple threads, and I know there's something extra I need to do because form controls are not thread safe.
Unfortunately I've tried several tutorials on delegates and invoking but it still doesn't seem to insert the log items to the list. I even spent $60 on this Mastering Visual Basic 2010 book to "Build Rich Client and Web Applications with Visual Basic", but there isn't a single chapter on how to handle multiple threads.
i want to add new database item to create new account at login form using database access file.the new database item can save and update. but, it cannot recall the new item..[code]
View 6 RepliesI am new to programming and i am working on a windows fom app. In this moment i have my windows form set with several controls that insert data into sql db. Now, what i need is this:
When the user select a employee name from my dropdownlist, i want the form automatically fill with the data inserted in the past to the tables db. Is like choosing the different profiles by selecting the name in the dropdownlist. I have many controls to fill, name, secondname, lastname, telmobil, address, etc.
I'm trying to make an aplication in wich you'll use the textbox to select an item form the listbox If the listbox has:
[Code]...
I have a listview and labels on my form. When the user clicks on the label the labels text displays in the listview. And the first item in the listview is selected. But when I click on another label the text is displayed as the 2nd item in the listview but it is not selected.
Attached is the code for a couple of labels.
Private Sub Label49_Click(sender As System.Object, e As System.EventArgs) Handles Label49.Click
Dim intIndex As Integer
For intIndex = 0 To ListView1.Items.Count + 1
Next intIndex
ListView1.Focus()
[Code] .....
I have looked through the properties control but could not seem to find the option which let me to display the item in a combobox when form loads. I don't want to leave it empty when form loads.
View 3 RepliesI have a form. On its load event, i have a txtName.focus , this is a text box inside a group box on the form.However when the form loads it does not focus the cursor in to this text box.I tried using the groupbox1.focus but that didn't work either.
View 3 Replies