Make App Perform Event Every 5 Starts?
Jul 9, 2010
How can I make my app perform an event (in this case updating) on the first run, and every five starts after that? So on the first, then the fifth, then the tenth etc. I know I could do it by adding 1 to a settings variable every startup, but I can't figure out how to check if it is a multiple of five. Or is there a better way?
View 9 Replies
ADVERTISEMENT
Nov 3, 2009
How Do I Make Button.click Event Perform both the enter and period(del) keys on the numeric keypad? [Code] Case Keys.Enter and Case Keys.Separator do not work. Nor does anything like Keys.OEMPeriod for the period(del) key. I've also tried calling the enter key in a KeyPress event etc. But to no avail. Any ideas? I'm trying to mimic Windows calc.exe for a school project and thought I'd try throwing in a few extras such as numeric keypad functionality.
View 1 Replies
Jun 9, 2011
Me and a friend are making an app which we need to play a sound when Form1 is started. How do we do this? I don't mind code.
View 2 Replies
Nov 19, 2010
I have 64 labels in my program and I need to perform a single bit of code every time each of them is clicked.
[Code]...
View 4 Replies
Dec 9, 2009
I have a datagridview comboboxcolumn populated with jobs. these jobs have a wage attached to them. for example job "Policeman" has a wage of R20.I have 5 checkboxcolumns for each day of the week as well. so if I check 3 of the checkboxes and have the job "Policeman" selected, I must then calculate the weekly wage (3*20=60) and display the wage in the weekly wage column. which event is best to handle this.
View 2 Replies
Oct 15, 2011
how can i perform a label click event using the code only.like in button we have a code like me.button1.performclick
is there something like in label
View 1 Replies
Nov 14, 2010
I have a feature in my program that allows the user to have multiple tabs, each having its own rich text box. Is there a way that I can only perform an event, such as "Text Changed", for the selected tab's rich text box, or will everything still work (the way I want) if I give them all the same name?
View 12 Replies
Mar 24, 2010
I have a WinForms DataGridView control on a form. There are two fields in this DataGridControl:
Email Address
Resolved Email Address (calculated based on the input in Email Address)
After the user inputs or changes a value in Email Address, I want the value in Resolved Email Address to update based on a separate method. What event should I tie in to so that that the Resolved Email Address cell is updated after the Email Address cell is updated?I'm not sure where to put the event because the user could do a number of things after adding/changing a value: tab to the next cell, click cancel on the form, click ok on the form, etc.
View 3 Replies
Sep 30, 2009
I know the code to make labels invisible but i dont know how to make them invisible as soon as the program starts. where would i have to put the code fro that to work?
View 2 Replies
Jul 31, 2009
I wan't to make a button in my program that opens it when the computer starts up but how would I do that? I am using Visual Basic 2008 Express Edition.
View 4 Replies
Dec 20, 2011
i just want a program that start automatically.
View 5 Replies
Apr 17, 2012
I am creating an Excel Add-In using Visual Studio 2010. I would like to run some code when users clicks a combination of keys.Here is the code I have got
Public Class CC
Private Sub ThisAddIn_Startup() Handles Me.Startup
EnableShortCut()
End Sub
Sub A1()
[Code]...
The Add-In when installed shows an error on clicking the short cuts. It says the specific macro cannot be found.The code under the Sub EnableShortCut() works well when it is in an excel vba module. The same won't work when it is added to an Excel Add-In created with Visual Studio.
View 4 Replies
Jun 8, 2011
I am trying to make an application which will list all processes in a string when it starts. After it has listed them all I enable my timer, and in the timer there gets checked if the process is in the process list (string), and if it isn't it will add it to my listbox. The only problem is, it's not working, it's never adding an item.
vb.net
Public Class Form1 Dim AllProcesses As String Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load 'The first check For Each p In System.Diagnostics.Process.GetProcesses() If AllProcesses = "" Then AllProcesses = p.ProcessName Else AllProcesses += "|" + p.ProcessName End
[code]....
View 3 Replies
May 16, 2011
I am currently working on a launcher, and it must consist of the following:
- one main routine being called, NO WINDOW may be created at any times after or before this main routine.
- one small form called by the main routine if a certain command was sent through the Command (shortcut).
At this point I use a Windows Form, but it seems a little useless to create and initialize a form if you won't even use it. Any way to make a routine run when my program starts without showing any window? But still make it possible to show that small dialog?
I did this at first but it seems a bit dangerous:
'NOTE: The following procedure is required by the Windows Form Designer 'It can be modified using the Windows Form Designer. 'Do not modify it using the code editor.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Main()
End Sub
Sub Main()
'Code to run here
End Sub
It starts another program (process) which has a GUI, so I do not want to display a console window.
View 6 Replies
Jul 16, 2010
I want to make that program starts when computer starts. I have no idea how to do that.
View 4 Replies
Jan 18, 2012
I am trying to make a vb.net program which will perform WMI queries to check for remote computer's name and OS. I manage to do the first query of name using the code below..
[Code]...
I am getting error "Local variable 'query' is already declared in the current block. (BC30288)".I understand that I am using same name for the object variable for performing subsequent query. Is there a way in which I can dispose the variable completely and reuse it again for querying the new required WMI detail? My search in the net couldn't give me any clue as of how to clear the variable and use it again. The issue is with two variables "query" and "searcher". Is it only possible that I should give unique names to each query object variable as I might add more queries later on?
View 2 Replies
Feb 9, 2011
I am attempting to have my program select a file, create DataTables and then perform some other functions. I want to be able to open another file and re-do the same steps.The problem I am having is that I add columns to my Datatables and when I try and to open another file while one is already open I get a message that a column of xyz is already added how do I properly "clear my datatable" or perhaps that isnt even the correct approach? Here is the code I have that Opens a File
HTML
Private Sub OpenToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OpenToolStripMenuItem.Click
[code]....
This was working at one time but after adding to my project I must have placed something in the wrong place inadvertantly or it has soemthing to do with adding columns,?
View 4 Replies
Sep 20, 2010
Starting from my understanding about Background worker control, I understands that the background worker runs the code in its "DoWork" method in a seperate thread, while ProgressChanged and RunWorkerCompleted events are executed on the main thread.In my senerio, I report the progress and under an specail condition my application displays a message box to the user in "ProgressChanged" method using MessageBox.Show(). and in "Run Worker Completed" event the application finalize some work. There the sequence is important, suppose that the message is of Yes or No type and finalization depends on it. Now when i run my application, the background worker triggers "ProgressChanged", but as soon as backgroundWorker's cancelAsync() is called the program leaves the current "ProgressChanged" method and executes "RunWorkerCompleted" code first.How can i make sure that the "Run Worker Completed" code executes only after the completion of ProgressChanged method.
View 9 Replies
Oct 12, 2009
I want to make a code happen then the date changes. Is there a better way of doing this other than setting up a timer and having it check the time/date all of the time?
View 3 Replies
Oct 7, 2010
I am programming in VB.NET. I am trying to make an onClick event for a div tag. How can I make this in the code behind?
View 2 Replies
Aug 1, 2009
i wanted to ask how to make picturebox1 ,to which functions are already assigned, perform the same function as picturebox2 ,to which no functions are assigned.For example:I have already made picturebox1 and have assigned it alot of function like when play button is pressed then picturebox1.visible = true and when we press pause button picturebox1.visible = false. So now i decided to make a theme and have to remove the picturebox1 and want to allow the picturebox2 to havefunction of picturebox1.But when i disable the theme the function of picturebox1 should go back to picturebox1.
View 6 Replies
Oct 17, 2009
I'm making an application in VB Express in which when a key is pressed (for example- the 'f' key) a sound plays. How could I make a specific key event for each sound? I have seen the KeyPress event, and I don't know if this is what I'm looking for.
View 3 Replies
Dec 18, 2011
How to make an event for keydown, but for second press?
Yes, i know how to make event, eg.:
If e.KeyCode = Windows.Forms.Keys.Escape Then
Me.Close()
End If
But i want code for second press. For example...:
First use button space: open form1 Second use button space: open form2
View 2 Replies
Mar 8, 2010
Is there any event for Right Mouse Click on Visual Basic?I wish to have a code or any thing so it allows a specific code to be done while Right Click while if Left Click another code will be done
View 7 Replies
Jun 1, 2011
How to restrict the textbox input to be a-z, A-Z, 0-9?How to make the enter key event in the textbox?
View 6 Replies
Feb 14, 2009
I have tried to make a program not able to be forced to close by naming it the same as a system process. However, this only works on XP, not on Vista. I don't actually mind if the program is closed but I would like something to happen when it is, thus being able to end the process is not good.Is there any event that can contain code to be run when the process is stopped? I'm guessing not but it's worth asking. If not, is there any other way to stop this? Maybe have 2 programs continually watching for each other or something?
View 6 Replies
Jul 2, 2009
how do i make an event for only one checkbox in the checked list box ie there are 3 items
item A
item B < this one needs to have the event...
item C
View 4 Replies
Mar 9, 2009
how to make an event happen when user presses a key ... let's say space or whichever...and the other thing - how to display a folder on my hard disk ("E:Music") in a ListView box in my program?
View 7 Replies
Jul 19, 2009
When I use the code below, I can't get any (copy)effect as I drag things onto the picture box(img). Therefore, I can't dragdrop files. How can I make dragdrop event possible?
[Code]....
View 2 Replies
Jun 9, 2011
In my case, i want to make some tool with event, example : make a new textbox with event button click. Can Visual Studio 2005 vb.net do that? How to do that?
View 2 Replies