I tryed to make a media player and i added a button to the form called "Full Srceen".[code]'so i get an error message : Catastrophic failure (Exception from HRESULT: 0x8000FFFF (E_UNEXPECTED))
I have made quite a nice and tidy little game. Its based around space invaders and works quite well. however because i have finished my college project almost 2 weeks ahead of the assignments release date, my tutor has asked me to tweak my project and make it better.So far i have added a full main menu to the game and a full splash screen. I would like to add in a section for recorded high scores but have no idea how to attempt this at all.
I created 3 Forms (Form1, Form2 and Form3) and I added a button on every form. This is code for Button1 on Form1:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Form2.BackColor = Color.Red Form3.BackColor = Color.Red Me.Hide() Form2.Show() End Sub
Code for Button1 on Form2:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Me.Close() Form3.Show() End Sub
Code for Button1 on Form3:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Me.Close() Form2.Show() End Sub
Now, the problem is that when I click on Button1 on Form3 it shows Form2 but the Form2 BackColor is not red, it is default color, A.K.A Control Color. But I specified in Button1 on Form1 that Form2.BackColor is Red. And also if I click on Button1 on Form2 when Form3 shows it, the Form3 BackColor is also default, it is not red.
I know one way to solve it but it is so not-professional. It is that you add on Button1 on Form2 this:
Form3.BackColor = Color.Red
and on Button1 on Form3 this:
Form2.BackColor = Color.Red
It is ok in this situation but what if I have more stuff, for example if I have an option for changing theme so it has to change all labels and buttons ForeColor, what then, is there any other way?
I'm using the arrow keys to move an animated gif around a form. However when I add a button control to the form the animated gif no longer responds to the arrow keys.
#include "stdafx.h" using namespace System; using namespace System::Drawing;
I have a form with a text box and a form with a list box. I would like to be able to push a button on the form with the text box and have it be added to a list box.
well here's where im stuck, I need Glass to get added to a string or something, so it can be called in myAddNew
vb.net "VALUES"Dim myValue As Integer ' Base value of frames Dim myValue1 As Integer ' Glass or plastic value Dim myValue2 As Integer ' Scratch Coating value Dim myValue3 As Integer ' UV value Dim totalCost As Integer ' Total value Dim deposit As Integer ' Deposit value, 20% of total myValue = 50 'Base value of frames, always 50 If GlassRadioButton.Checked
I have a form called FrmPracDetails which is built up with a List view called LvwColProc. Therefore when you click a field on the LvwColProc it takes you to another form called FrmColProcessing, here you can make changes to certain fields which are also present on FrmPracDetails. What I want to do is when you make changes on FrmColProcesing and Click the Save Button (which calls the Save function)the changes appear instantly on FrmPracDetails. Please note, FrmColProcessing will always be open next to FrmPracDetails. I have tried to put this code in the Save function present in FrmCol Processing as shown below, but it doesnt Refresh FrmPracDetails form. [code]
i've tried to make it so when i Click "Button1" what ever is in TextBox1 will be added to an .txt file called "MutedUsers.txt" But i want every User on an seperate line
I have a form being called form several forms using ShowDialog().
1. Is there a way for called form to know which form called it by receiving a code or key from the calling form?
2. The calling form has a gridview. How can the called form pick up a column's value from the currently highlighted row in gridview in the calling form?
I have a Toolstripmenu with ten drop-down items in it.(named menu1, menu2, menu3 etc)
I have a sub with ten handles Menu1.click, Menu2.click etc.So clicking on any of the ten menu items calls the sub.But- how do I find out which one of the menu items was clicked?
I want basically: foo = clickedmenuitem.text
I could do it with ten different subs but that would be a lot more code.Especially since the sub is quite large and I only need to know which item was clicked for a small part of it.
How do I find which of the ten handles for the sub was triggered?I tried handle.tostring but that gave the same string of numbers for each menuitem, that was clearly the wrong command.
I have a button called btnimport, when this button is clicked I want to open the local drives where a user can select a file (excel format ONLY - where ever it is stored on the desktop) and import the data (which are ID's) to a textbox on my form... First thing first, I want to click the button to open the local drives from my PC, then Second step will be to read the spreadsheet i.e., excel and populate a textbox with all the IDs.
This code is for a media player and am wondering how to make a full screen option that toggles on and off with a button and has a track counter that hides it self at a certain time just like wmp 11, fast forward,rewind and time counter
im trying to make yahtzee. but i dont know how to do the full house (2+3 the same). if the user press the full house button then it has to do something smart. i cant write down all the combinations. does somebody know a smart technique? let's assume that:
im making a tabbed web browser for private use which is basicly done apart from the fidly bits however i want to be able to hold down the "ctrl" key and press t to open a new tab like google chrome and firefox, im verry new to programing and dont even know where to start, so far i have been watching youtube tutorials and reading tutorials on here which has got me to the point where i can actualy use the browser and its verry handy but this would be an excelent feature.the way i open new tabs at the moment is by click a button called "new tab" using the following code. [code] these i could probably work out with google searching but im not to bothered if i can get it to work.
I have added a button in datarepeater. If clicked once, it executes code and Button.text should change to Yes. Clicked again, it executes the opposite code and button.text should change to No. Codes are being executed (I am using flag variable) but Button.text is not changing.
How to change this text. I am simply trying Button.text="Yes" but probably I need to give some reference of the row no. too. How to do it?
I'm looking to write a function that is called everytime an exit button is pressed, just simply prompting the user to click yes or no is there a guide anywhere? is there a name for this kind of thing i can look at it more?
This is what I have..Dim frmSettings As New frmOptionsfrmSettings.ShowDialog(Me)frmSettings is a settings form that you can choose the color for background of form1(Me)
I have two forms. Form1 and Form2. The user is supposed to fill out some information in form2 which then will be used to compute some data in form1. However when I used the code, Form2.Show, within a function in form1, the form2 is diplayed but when the user fills the data and submits them using the ok button, the code does not return back to the function in Form1.
I have never programmed anything in my life -- and I'm learning VB from a tutorial which I found here:[URL]...So I've created my button and added the code. Then it says:
"Now run your first application!"I have no idea how to do that!
I have a program that displays all of prisoners details.I use a form to add all of the details and then on another form it shows them, i have a search so that when you type the prisoner number in it will find that specific prisoner.When i add a prisoner a count in a textbox moves up 1 to show how many prisoners in the system.When i have added all of the prisoners i need to be able to go through them using a next and previous button.Can someone help me with the coding for these two buttons?
I have an application that is currently playing videos through the windows media player control from a website. I want it so that a button I have created, when clicked will make the wmp control full screen.
I found that if you press F5 or refress from browser window, the last event fires again example, I have clicked on a button, the button event is carried out normally, but if I refresh the page by pressing F5 key the same event is fired again.
I have an explorer-like interface which in many ways mimiques the behaviour of a standard explorer window. What I need is to find some way of knowing if something had changed in the filesystem since the last time I checked.What I mean, for example if a user creates a directory or renames a file - I need a way to know that. Right now I re-read the contents of the displayed folder once per second and I added a manual 'Refresh' button, but I wonder if there is a better solution.I tried to use FileSystemWatcher component for that but either I couldn't figure out how it works or it doesn't have such functionality.
I have a full screen button, so that when it is clicked the windows media player control will go to full screen. This works fine, however I need a way to check that the video has started to play before the button can be pressed to make it full screen.