VS 2010 - Get Data And Add It To Form
Jan 17, 2012
Is it possible to get data from one column in one table (unique reference) search another table for all the enteries of it, Then display each unique reference then a total for it, and add textboxes based on how many unique references then total them?
So the first table would look like
Travel - Fuel
Travel - Food
Travel - Flights
Then in the 2nd table would be
Description Value Date
Travel - Fuel 30.00 03/01/2012 (jan)
Travel - Fuel 20.00 01/02/2012 (feb)
Travel - Food 10.00 01/01/2012 (Jan)
Travel - Fuel 35.00 05/01/2012 (jan)
And then display it
Description Jan Feb Mar Apr (and so on) Total
Travel - Fuel 65 20 85
Travel - Food 10 10
Travel - Flights
and add for a row each time someone adds a new description to table1.
View 3 Replies
ADVERTISEMENT
Apr 26, 2012
I have a project, on form1, clicking "start" button will increase value by 2 each time in textbox1, if value exceed 5 the it requires to check the textbox.text of form2.Both "start" button on form1 and "fill form2" are on different threads, please help me to get the text from form2 when textbox1 on form1 exceed 5.
View 3 Replies
Sep 22, 2010
I created a form with 4 textboxes, one date picker, time and combobox. Now the problem I have is that I want to save all the values in these boxes in a folder which depends on what is selected in the combobox.
Source:
vb.net
Private Sub ListBox1_SelectedIndexChanged_1(ByVal sender As System.Object, ByVal e As System.EventArgs)
End Sub
[Code]....
The idea is that if I select 3 in the combobox, the files has to be saved in the folder 3. This folder is located on a server located in the LAN.
View 31 Replies
Mar 29, 2012
I'm using VB 2010 Express and I want to connect it to sql server 2005 where I have db with just one table.What I want is to write code to connect to db and bind database fields to form controls like text boxes. I'm new in VB.net, and have found some code on net but when I try to load form textbox is empty. Here is full
[Code]...
View 3 Replies
Jun 21, 2012
I recently have been developing an application in .net that uses lots of components created as digital/analog input/outputs, and, when each component is clicked shows a form that shows it's state.The problem is that the form allows to change the state of the component and I don't really know how to reflect the change made in the windows to the component variables, as I don't know if there is a way to call the parent from a windows form or any similar way to do it.
View 5 Replies
Mar 5, 2012
OK so I did a noob screw up, I was cleaning my application and delting unused data sources and unused data bindings. Now my form is blank! All code shows up for the form and all items still show in the mainFrm.Designer.VB
View 4 Replies
Oct 23, 2011
Im new here and hoping that I post this in the right forum. I am SLOWLY learning VB, and have run into a problem that I cant figure out. I have a standard form that you can enter data into.I want to take that data that is entered, and save it to a text file once I click the submit button at the bottom of the form. The form could have up to 500 entries into the form.
View 19 Replies
Oct 11, 2011
I have a listview with a collection that is filled from an array with data from a database.
HTML
Public Sub AddHandoverItems()
'Create item to hold contents of handover array
Dim itm As ListViewItem
[code]....
highlight/select an column and each column in the entire row, doubleclick the row, and populated a form with the .selecteditems(0) and subitems(0) to the text controls on the called form?
View 1 Replies
Oct 17, 2011
translating form data (fetched from mysql) to excel doc how can i do it? i saw a couple of examples but none worked only in vb6?
View 3 Replies
Dec 14, 2011
I am trying to learn how I can enter data into a Microsoft Visual Basic 2010 TextBox on a form and when I Tab to the next TextBox, the data from the first TextBox is automatically appended to a Microsoft Access 2007 table. For this question, no other controls or objects are necessary.
View 5 Replies
Feb 17, 2012
I have a bunch of Excel files full of research data. Everything is strait forward: rows of research categories and columns of research parameters. I want to create a simple search form that allows opening any of the spread sheets that contains the type of data that I specify. For example, I would choose a parameter
[Code]...
View 5 Replies
Aug 22, 2011
I created a VBA project in Excel. I would like to figure out how to transfer the data back in forth to make a more presentable and user-friendly program in VB Studio.Basically, I need my form in VB to input data to into an excel �workbook.data�, where the calculations are preformed. Then I need to copy the finished excel data cells �workbook.results� and paste them into an end result form in VB. I have tried looking at threads and cannot come up with a solution. There is no data saved each time the program runs, so I don't have a database.
View 14 Replies
May 22, 2009
I have just started with vb and would like to know if there is a way to input several boxes of data on one form and display individual pieces of that data on several other forms at timed events in the future?
View 1 Replies
Oct 13, 2010
Currently we are using a VB script macro created in word to create some fairly simple forms based off of data entered on a data entry form. I am very new to VB, and I have been able to create many applications using forms, but I have absolutely no history creating reports. I have been reading up on the reports, and it looks like they are designed to use with data sources like tables. I merely want to take either data from the entry form, or from data derived internaly from processing the user entered data and populate a defined report "form". I have been searching, but there is so much on printing reports, that I feel overwhelmed. I am not looking for the exact answer as much as a link or place to look for a sample for what I want to do.
View 2 Replies
Aug 14, 2010
I am working on a huge multiform project for my company, and one of the few issues I am having is that when I am on the Main Menu Form, then go into a specific form (i.e Sales Order, etc.), do updates, changes, or just view data then close the Sales Order Form, if I happen to go back into the Sales Order Form without closing the entire project, then the Sales Order Form will display data instead of opening a blank form like when I first opened it.
Is there something that I should be adding to the Form Close Event to dump all of the data or refresh the data adapters so that if I open the form again, it will display a blank form that is ready to be used like when I first opened it?
I have tried using;
Me.Dispose()
Me.Close()
when closing these subforms, but if I open them again, the data fields (combo boxes and text boxes) will have random data in them.
View 5 Replies
Jul 31, 2010
I have a listbox in my form that gets its values from a data table by data binding. My question is, when the data (row) is loaded it also selects the first line automatically. I do not want this because I want the listbox to select an item only when the user clicks on it. Otherwise, the iteme should ony be listed. Is there a way to manage this?
View 2 Replies
Mar 27, 2008
I have a simple windows form that i would like to send the values of a few textboxes and comboboxes to an rdlc report after saving them (I have VS 2005 standard, so no crystal reports) - it's as follows:
-1 form
-3 textboxes - textbox1, textbox2, textbox3
-1 label - label1
-1 combobox - combobox1
-5 buttons - button1, button2, button3, button4, button 5
the textboxes are labeled length, width, height the combobox is labled unit of measure and contains two options - inches or centimetres the label has text of "your total cubic inches/centimetres is:" - followed by the unit of measure selected.the buttons are labeled save, calculate, print, print preview, and exit.Having said all of the above, the save, calculate and exit button code is easy enough and is good to go - it's print and print preview i'm stuck on the solution i'm after is to take those values and send them to an rdlc report that immediately prints (calls up the default printer dialogue) without preview or anything when the print button is clicked and also have a print preview function as well for when of course the print preview button is clicked.The report has already been created with the titles mentioned above..
View 1 Replies
Jul 27, 2009
I have two data tables within my data set that are loaded onto my form on form_load using statements written in code (not the designer. When I change a value for the first table via a text box the change is made to the data set. But when I try the same for the second table, the change doesn't remain in the data set when I switch to a different company and come back. I query the second table using the primary key of the first table but no code is needed when I change the values for the first table so I don't understand why the same doesn't work for the second when I change a value via a data-bound text box....
Here is my code that initially binds the data:
'This is used to read our data from the data base
Public Sub Read_Data_SQL()
Call Clear_Bindings()
[CODE]...
Here is the code I call when the selected index of my company combo box changes to have the second table reflect that of the first:
'This sub populates any information contained in the Contact2 table
Private Sub Update_Contact_2()
Dim Company As String = cmbCompany.Text.Replace("'", "''")
[CODE]...
View 1 Replies
Jan 29, 2010
I have a main form with datagridview containing a list of contacts:
VB
Public Class Form1
Private Db As New DataClasses1DataContext
Private Sub Form1_Load
[Code]....
After saving, I get the correct message ("Saved"), and the DataGridView in the first form gets updated in real time.
But... when I take look at the data (or close and reopen the forms) the data in the database (SQL server) have not changed! What happens!
View 4 Replies
May 15, 2012
How do i load the Main form of a WPF so that a seperate thread goes and gets data from the database while the form is in an apartmentstate? (drag-able / movable) I Know this is possible with opening a new window from your main form like this :
Private Sub openOrderWindow()
Dim OrderWindow As Orders = New Orders
OrderWindow.ShowDialog()
End Sub
[code]....
I've tried putting MyBase.ShowDialog() and .Show() and .9000+ other things The only benefit I've got out of using a seperate thread to load from the databse is i can see the screen right away (as oppose to it being a transparent box until it loads) but i cannot move it around or minimize it?is there any way to make it Movable while it loads?
View 1 Replies
Jul 15, 2011
Im getting that error in the da.Fill(ds)
Imports System.IO Imports System.Data.SqlClient
[Code]...
View 20 Replies
Sep 24, 2010
I have a Windows form I would like to save the Ovals I created while running the form for use and review later I have been trying the SaveFileDialog but have not figured how to get my data out to the file that is created. I have read about using datatable but there again I'm working with that but need to find how to load all my Oval parameters into the table so I can recreate the current look of the form.
View 4 Replies
Apr 23, 2010
how to use the VS 2010 IDE tools in a way the Microsofties didn't specifically intend. But since this is something I immediately tried without success.
I have defined a .NET 4.0 WPF Application project with a simple class that looks like this:
Public Class Class1
Public Property One As String = "OneString"
Public Property Two As String = "TwoString"
[Code]....
The expected result was that "OneString" would appear next to "One" and "TwoString" next to "Two" in the running window.
The question is: Why didn't this work? What will work instead? If I put bindings in a DataTemplate, it works. Blend, with its sample data stuff, implied that this should work, but it doesn't.
View 1 Replies
May 15, 2011
I was using 2 forms, the first one has general data capture and the second one is a calendar form. On Form1 I have mulitple windows controls. A Textb ox and beside a Calendar button. When I click on a Calendar Command button, it should open calendar form and once the user selects the date, the date should be placed in the text box on the form1. Identical to this on Form1 I need multiple textboxes that needs date to be captured.I cannot use a global variable for this as I need to validate mulitple text boxes. To explain this, I have a Transaction Date and Date Received. I need to validate whether Transaction date is prior Date Received or not? I dont want to use several global variables b'coz I might need multiple validations as above. Please help me on this.
View 6 Replies
Jun 10, 2009
Private Sub Button3_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
'Para abrir un formulario independiente /Open independent form
[Code].....
View 2 Replies
Oct 14, 2010
There are few steps to find out the half slopes of the graph.
Step 1: Rank the data The independent variable is required to rank it from the lowest to the highest.
Step 2: Divide the data Divide the sample size into 3 roughly equal parts, which is the lowest, middle and the highest parts. If n/3 has remainder of 1, +1 into the middle part. If n/3 has remainder of 2, +1 into the lower part.
Step 3: Find the median The size of each part = n, find the ((n+1)/2)^th value for both dependent and independent variables. If the ((n+1)/2)^th is not an integer, sum up the 〖n/2〗^th value and ((n+2)/2)^th value and divide the total by 2 to make it as median. The median, m1 for independent variable in lower part indicate as XL , middle part median, m2 as XM and the highest part median m3 as XH. For the dependent variable the median is indicate as YL, middle part as YM and the highest part as YH . Figure 3.2 Example of median m1, m2 and m3
Step 4: Find the half slope Find the half slope for the lower half, b_L=(Y_M-Y_L)/(X_M-X_L ) and for the upper half, b_H=(Y_H-Y_M)/(X_H-X_M ) .
Step 5: Find the half slope ratio, b_0=b_L/b_H . If the ratio is negative, the dependent variable need to add with a constant, c in order to make the slope same direction.
Step 6: Identify transformation. Depend on the graph pattern pick one type of transformation which is nearest to the original of the variable.
Step 7: New half slope Find out the new half slope ratio, b1 by repeat step 4 and 5 with the transformed variable.
Step 8: Repeats steps Repeat step 6 and 7 with choose the transformation which is nearest to previous transformation and find the new half slope ratio, b2, b3,�, bn. Repeating this step until |1-b_i |≤|1-b_j |, for i<j, i and j = 1,2,3,
Step 9: Result bi is chosen. The data transformation used in bi is the most closest to be normality.
How to make it into visual basic and let it run by the program?
View 5 Replies
Oct 25, 2009
i want to know that when im adding my data in form after loading one person data then 2nd person data the 2nd person data cannot come to next line it is adding on the same line.plz tell me wat can i do?
View 6 Replies
Apr 11, 2011
i want 2 select data from data gridview and want retrive that data into another form in to the textbox ...is it possible ? i 'm doing like this for that
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.[code...]
View 2 Replies
Mar 27, 2011
I need to detect shift + arrow key in blank form. But it's not working. I also tried overriding IsInputKey method but it only detects single key press (like arrow key) but when multiple key are pressed it simply doesn't work.
View 5 Replies
Aug 11, 2011
Im doing this project but u have a problem. im trying to make it so that when a timer in the first form(form1) ticks a progress bar in the other form goes up by 1.
View 2 Replies