im pretty new to VB 2008 and programming in general.im using a button_click event to run a .exe i am adding it as a resource and in run time the button_click wont work, i cant figure out the code to make it run on from the click event.i can get my .exe to run at runtime
I have created multiple dropdown list at runtime and populated with data. I also have added an eventhandler to determine the selected value of the drop down list.
The code is as follows : Dim tbl As New Table() tbl.EnableViewState = "true"
I'm creating an app to manage the movies I've watched and get some info about these movies and then display these info in labels.At moment I'm trying to load the "runtime" and "genre" into label3 (runtime) and label5 (genre). Once the movie name is clicked in the listbox control, these info are loaded from a website (webbrowser control) and then displayed in the labels. My question is: Is there any way to make the My.Settings save these info for EACH movie? Something like this:
Saving the info:
vb If ListBox1.SelectedItem.ToString > 0 Then 'LOADING THE INFO CODE... 'SAVING... 'create: My.Settings.(ListBox1.SelectedItem.ToString & "1") = Label3.text 'create: My.Settings.(ListBox1.SelectedItem.ToString & "2") = Label5.textEnd If
I have a Visual Basic 2005 program which runs fine if I execute the built Executable. However if I start the application in VS2005 debugger it gives a weird error
I'm trying to populate some file dependant settings from the database. Values I can add no problem but how to set the names as they differ from datafile to datafile? For Each myRow In SetModDataTbl.Rows Dim SettingName As String = myRow.Item(1) Dim SettingValue As String = myRow.Item(2) '>> SettingName = SettingValue << Next myRow
I recently created a windows service that starts other applications that I use on windows startup. Basically this service is for virtual computers i use to test software and web sites. The service starts and stops just fine but when a custom made application actually is run within the service I get a .Net error in my event logs. Ive read up online and found that this is caused by an unhandled exception (As a result of this error in version 2.0 of the framework the application is killed.) so i added the correct handler and it didn't work. Then i found that another issue could be .net being corrupt so i uninstalled and reinstalled still no fix. I know theres an issue with one of my applications but i cant find were. I don't get any errors when i debug anyone know what i should do? [code]
How do I filter my datareport in vb 2008? When I run my form containing my datareport everything is being displayed. Is it possible to filter my datareport? How?
I've got a series of textboxes that are bound to a dataset. I've got them disabled and will be hiding them. Then I have a series of check boxes related to each textbox. The user clicks the check box and I change the value of the databound textbox. Nice and easy way to bind check boxes to DB fields. Any way to create these relationships at runtime - basically creating the events that I'm hardcoding right here.
Private Sub IntprtLead_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) _ Handles IntprtLead.TextChanged _ , IntprtCheck.TextChanged _ , IntprtCons.TextChanged _ , IntprtSimul.TextChanged Dim strValue As String = TryCast(sender, TextBox).Text [Code] .....
I know I can loop through the controls on the form and find these "named" objects easily enough. Is it possible to have more "generic" event code and then create the handles relationships at runtime?
I am working on a project that uses a .txt file to store data for my arrays. Everything is working correctly i.e. I can read the file and write to the file, my issues when I exit out of runtime I get this msg
Quote:
M:My4BVB....Customer.txt
This file has been modified outside of the source editor. Do you want to reload it?I understand what it means, what I would like to know - is there a way to stop it from popping-up?
How do I change my code so that it will change the Value of the My.Settings.* to what TextBox1.Text is
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click If RadioButton1.Checked = True Then My.Settings.Acc1 = TextBox1.Text And My.Settings.Pass1 = TextBox2.Text
I want to change the underline property (to true) when the mouse is over it (either mouse hover. enter, or move - i don't know which is best to use.Then change it back using the form's mouse over/hover/enter property.So how would I change it?
I have 2 forms. I am calling form2 from a button click in form1. I want through the button click to set the location of form2 by setting X,Y cordinates. I have tried this but nothing happens:
form2.Location = New System.Drawing.Point(100, 15) form2.Show()
i have a byte array in my code which contains hex values which is readed from a bin file. now what i want to do is cut this array into equal size of 4096 bytes and made new array,s at run time and assign first (4096) byte,s to first array and so own
I have 2 Comboboxes on my Form which also has a DataGridView. One ComboBox is populated with Font Names and the other is populated with a range of Numbers (Font Sizes). On a button click I've added this code
I have a question regarding the manipulation of a form at runtime. Let's say I created a simple form in the form designer before runtime containing a couple of buttons, text boxes and labels. While the program is running, I would like to change properties of these controls, while having the ability to move them around, along with the addition of newer controls, say a listbox.
After the form is 're-designed', I would like to save the new settings of my form, in either a database or settings file. Whats the best way to implement this?
I am using combobox on a form to select a graph to display on MSChart. The points are then drawn on the chart which is fine for the first chart selected.If I then select a second chart to display it adds the data to the current graph.I have tried Me.Chart1.Series(0).Points.Clear()which clears the points but the axis information remains ie The first chart has 10 sets of points so the y axis goes to 10. When selecting the next chart which has 15 points the y axis goes to 25 even with the points removed.I have also tried manually setting the x and y max values after the new points are added but it doesnt alter the values.Any idea how to set the chart back to default so that I can plot the next.
Ok so i am currently working on a magic square game and basically my form creates an 2d array, dimensions make by user(ex:2 by 2), then the form creates the number of textboxes(Ex:4) and i need to get the values in runtime to check if it is a magic square
Dim MakeArr(dbltxt - 1, dbltxt - 1) Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
I have 2 forms. I am calling form2 from a button click in form1. I want through the button click to set the location of form2 by setting X,Y cordinates. I have tried this but nothing happens:
form2.Location = New System.Drawing.Point(100, 15)form2.Show()
I want to create an access table at runtime. It happens that my table has to change, this means that i need to alter some or all of the fields. I need to be able to do this at runtime. I am using the following code, but it does not seem to work. The last field has to be an Autonumber field.
Private Sub CreateLessonPlan() '' Create table if it does not exsist If con.State = ConnectionState.Closed Then con.Open() End If Try ' Drop the Employees table if it already exists. [Code] ..... Is it possible to alter the structure of a table that already has some records in it?
I am working with a simple game idea. I wanted to have two players running around shooting each other (very low graphics, like circles and squares). I've got this far; I have the ability to move around both characters, and change directions etc. ive also been able to set up my shooting. Only problem I run into is getting the bullet to move! I cant use a preset timer, because if I used that, I could only shoot one bullet at a time, so I would need to create new ones dynamically.
So my question is; how does one add dynamic timers to a form on runtime, and alter the tick sub so that it moves the picturebox (bullet) and once it can be moved, (I was thinking about using player locations in relation to the bullet, and if they were equal than the health would go down or whatever, but unfortunately, this means it would have to be directly in the middle of the player, which would be odd..
I just recently started getting an index out of bounds error on one of my arrays at runtime. I was not having this issue previously. It only seems to happen when several items are added to a listbox.
Here is my declaration and code. Dim ClientActiveMedProbs(frmmain.lstActiveMedProbs.Items.Count) As String 'store all active medical problem information in an array & build a string For i As Integer = 0 To frmmain.lstActiveMedProbs.Items.Count - 1 ClientActiveMedProbs(i) = frmmain.lstActiveMedProbs.Items.Item(i).ToString [Code] .....
The actual error message is: Index was outside the bounds of the array.
I am creating a program which allows the user to add some buttons during runtime. Each button can be moved, sized and added to any tab on a tabcontrol. What I would really like to do is binary serialize a class that contains the properties of each button including which tab it's on.
im trying to work with adding controls in runtime. Anyways ive added a ContextMenuStrip control in runtime and added a item called "Display". The ContextMenuStrip is also added to textbox's that are also added in runtime and when i right click a textbox i see the "Display" but i want it to do "msgbox(textbox.text)" when i click "Display".