Activate Only One Form At A Time?

Dec 27, 2009

In my project i have 4 Forms including main form. Form2 is open through main form then Form2 remain active until user close Form2.Mean to say Form2 not allow any other form active until user closer form2.

View 3 Replies


ADVERTISEMENT

Make A Form That Would Activate The Program?

Apr 2, 2011

On my program I am trying to make a form that would activate the program.I have the activation codes but when the user enters the activation code in a text box, is it possible that it would erase that activation code or wont accept that activation code again after being used once. Then if the program accepts the activation code can it open the main form (form1) and if the user closes the program and the re-opens the program, is it possible that the activation form doesn't open again and instead, going to the main form. I have this password code:

Private Sub textbox4_KeyDown(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles MaskedTextBox1.KeyDown
Static WrongCount As Integer = 0[code].....

Then can there be slashes every 4 characters in the text box?

View 1 Replies

MDI - Form Activate Event Not Firing

Jul 22, 2011

I am using VB.Net for my Windows application. I will open two child form from MDI. Both forms will open. Now if I will go from form1 to form2 then Activate event for form2 will not fire.

View 1 Replies

Activate Form On MouseEnter Event Not Working

May 25, 2010

I'm trying to make my application become the active window if it currently isn't as soon as the mouse enters the main form of the application (so there is no need to click the title bar of form itself to make the window the currently active one if it's not).

It only sorta/kinda work .... I have to enter the form with the mouse 3-4-5-6-maybe 7 times ... then the window finally becomes the active one.

I know the MouseEnter event is firing each time the mouse enters the app, but the main window isn't becoming active most of the time.

Private Sub frmMain_MouseEnter(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.MouseEnter
rtbStatus.AppendText("Just got a frmMain.MouseEnter event" & vbCrLf)

[Code]....

View 10 Replies

Load And Activate Events For A Form In Program?

Nov 18, 2011

I am having three forms

1. Main page

2. Input page

3. Output page

I want load event to be activated whenever coming from Main page to Inputpage and activate event when coming from output page to input page.But what i am getting is that only for the first time load is activated and for all other only activate is called.

View 2 Replies

VS 2008 Odd Behaviour When Attempting To Activate A Form?

May 12, 2009

I have a program where the main form is called (shown/activated) via a keystroke combination. When the form pops-up, I've set the focus to a textbox to begin typing right away.

When the keystroke event occurs, I have:Me.Activate()And in the Form_Activated event:

Textbox1.Focus() Simple right? It works the way I want it to, even after I've compiled and run the EXE, but ONLY if Visual Studio 2008 is running. Once I close my project in VS, with the program still running outside VS, the form is shown, but input focus is not set to the textbox.

Input focus is however still set to whatever it was previously, like a word document for example. My form will be topmost, but if I attempt to input text, it would still be entered into the word doc. why having my projects' source open in VS has anything to do with running the compiled EXE of said program?

I've even tried API calls to SetForegroundWindow and ShowWindow with the same result.

View 4 Replies

.net - MDI Child Form Does Not Activate When Clicked In Client Area?

Jul 29, 2010

My VB.NET app supports several kinds of MDI child forms. Some kinds, but not others, are 'troublesome' -- they cause the focus mechanism to become weird. Once a 'troublesome' child form has been opened, NONE of the MDI child forms will become activated unless I click on either the title bar or the border. Clicking in the client area does not activate the child form -- its title bar remains gray, and it does not receive Activate or GotFocus events. Strangely, however, the clicked-on form actually DOES receive the focus, because its controls receive mouse and key events. Only the Z-Order and the highlighting do not change.

Once this problem develops, it persists even after the 'troublesome' form is closed, and it affects child forms which are opened afterward. However, if ALL of the child forms are closed, the problem clears up, and new child forms behave normally -- until the next 'troublesome' form appears.

I have no idea why one kind of child form is troublesome, and others are not.

View 1 Replies

Activate RIGHT MOUSE CLICK To Press A Button On A Form?

Jul 1, 2011

I have a form with some buttons i built in visual studio basic 2010 When I left click a button it uses 1 value...but I want to be able to right click the same button and it use a different value i cannot find anywhere how to activate the right mouse button so it presses the buttons on the form so it use the different value i specify.

View 13 Replies

MDI Child Form Does Not Activate When Clicked In Client Area?

May 8, 2010

My VB.NET app supports several kinds of MDI child forms. Some kinds, but not others, are 'troublesome' -- they cause the focus mechanism to become weird. Once a 'troublesome' child form has been opened, NONE of the MDI child forms will become activated unless I click on either the title bar or the border. Clicking in the client area does not activate the child form -- its title bar remains gray, and it does not receive Activate or GotFocus events. Strangely, however, the clicked-on form actually DOES receive the focus, because its controls receive mouse and key events. Only the Z-Order and the highlighting do not change.Once this problem develops, it persists even after the 'troublesome' form is closed, and it affects child forms which are opened afterward

View 4 Replies

Automatically Turn On / Activate CAPS Lock Key When Form Loads?

Mar 10, 2009

Can i automatically turn on or activate the CAPS Lock key when the form loads?

View 3 Replies

VS 2008 : Differences Between The Form Events Like Load , Initialize , Activate Etc?

Apr 14, 2010

Load , Initialize , Activate . What's the difference among them ? Up to now I was used to the classic VB6 events , but it seems that in .NET they are different . I was used to these ones :Load / Initialize : both the first step before showing a form . One appeared in VB6 , the other in VBA .Activate : triggered when a form is selected .However I thing that now , not only they differ , but they also come in a different order ...

View 34 Replies

.Net Form Activate/Deactivate Event Firing Issue After Removing A TabPage From TabControl?

Nov 28, 2011

I've recently run into an unexplainable issue regarding a windows form application I am working on. I've managed to isolate the issue to a single line of code whereby a single TabPage is removed from a TabControl, leaving no tabs left in the TabControl's collection. What happens next is a bit mystifying: my application proceeds to enter a state in which the main form's Activate event is fired subsequently followed by its Deactivate event. As a result, no matter where I click on the form, the application will activate for a split-second then immediately deactivate itself, thereby causing me to be unable to interact with any other GUI controls on the form. I thought maybe another thread is trying to interact with the deleted tab object, but the tab is created and destroyed on the same main gui thread. Does anyone have any insight that may point me in at least a new direction? Stepping through the debugger to the point in code where the tab is removed does not cause any exception to get thrown, so at first glance there doesn't appear to be any coding issues going on (although I would not be surprised that is actually the case!).

View 3 Replies

When Form Loads It Load The Current Date And Time But The Time Does Not Change It Should Run?

Aug 24, 2010

I am using this line of code on form load event it is working very fine but i have to problems

1. It replaces the form name and display the date and time but i want to keep both date and time and forms caption separated by some space.

2. When form loads it load the current date and time but the time does not change it should run.

What should i do please please help me code is as follows

Me.Text = Date.Now.ToLongDateString & " - " & TimeOfDay

View 11 Replies

C# - Difference Between Load Event,Activate Event And Enter Event In The Form?

Mar 30, 2009

I am using VB.NET for Windows applications. What is the difference between Load event,Activate event and Enter event in the Form and in which order the above event is executed.

View 2 Replies

Multiple Form Declarations - Declaring Them Each Time On Each Form?

Nov 28, 2009

I have multiple forms and have multiple declarations that I need for all the forms, is there a better way than declaring them each time on each form? Can a .dll do this, if so does it require the .dll to be a seperate file than the final .exe file. Or is there someway to reference the variables on other forms?

View 2 Replies

Create The Children Form Within A Same MDI Form Every Time?

Feb 20, 2009

i MDI form there, i was create the children form within a same MDI form every time i click on the button to show the form, which means i create a new form, how i do for ensure that each time i click on the button there will not create a new form is the form is really exist? how to avoid duplicate of the form will not exist twice?another 1 more question is also about the MDI form, everytime i create i new form, the new form is covered by old form, how i do that the new form i created will always show infront, other 1 will show at behide

View 3 Replies

Can Activate The Ctrl+Esc

Feb 3, 2010

Can i activate the Ctrl+Esc ?

View 9 Replies

How To Activate Event From Somewhere Else

Apr 14, 2011

I am creating a web browser in VB 2010. I have a search box, and I want to make it so that when I press enter in the text box, it searches. [code] The problem with this is that when I press enter, there is this annoying "beep". I don't know where this comes from. The only thing I can think of doing is making the event activate the search button, but I don't know how to do that either. How can I fix this?

View 1 Replies

How To Activate Sqlcmd From VB

Jun 10, 2011

The following code does not work. Shell command executes without execption but nothing occurs. The file DBCreate.sql contains a script building a SQL database.

Dim DBNom As String = "DBEssai"
Dim DBChemin As String = "E:DocumentsDBCréation"
Dim CréationScriptTemplate As String

[Code]....

View 3 Replies

Possibility To Activate Sub From Another Sub?

Feb 24, 2011

Is there a possibility to activate sub from another sub?[code]if a is 1 then I want my program to run 'sub 2' and if it's not then it should run 'sub 3'.

View 6 Replies

Activate The Application With A Serialcode?

Mar 17, 2012

I'm now working on a domainchecking application for about 2 weeks and it is in the final developement phase.There is a my.settings that is, by default 1 to indicate that it is the first time starting the application. If it is the first time, the settingsform will show up to activate the application with a serialcode. This works fine. If I start up the app again, it doesn't show the settingsform again because my.settings.firsttime was set to 0.

After 1 cycle of the timer, which checks all the domains,the line: application.restart is being executed. Then **** happens...It shows up the welcome-message again and asks for activation.By check,I put a button on the settingsform which shows you the value of my.settings. firsttime. and ***... It is 1, like magic, it changed itself from 0 to 1. The same problem is with the indicator of the activation.Is the problem caused by application.restart? Is there alternative code for restarting an application?

View 4 Replies

Activate An App That Is In The System Tray?

Aug 27, 2008

I'm using VB 2005, and trying to write a console app that (among other things) activates a different program that is in the system tray.

View 1 Replies

Activate Button In Other Application?

Jul 13, 2011

i wan to active start button in other app, i use spy ++ to check the button styles, i c bs_pushbutton. i try to use win api to do it.i tried WM_SETFOCUS and enter key to do it, but fail

these is my code

Dim hwnd As Int32 = apiFindWindowEx(HWND_DESKTOP, 0, Nothing, "Open File - Security Warning")
Dim cwnd As Int32 = apiFindWindowEx(hwnd, 0, Nothing, "&Run")

[Code]....

View 1 Replies

Activate Msi File With Code?

Feb 15, 2009

had a quick question that I dont think is too difficult, the solution just isn't too apparent to me.I put an option in my program that will allow a user to redownload a setup file and repair a program installation and I wanted the program to automatically launch the msi file and pass a command line arguent to use the repair function in the installer.This code works perfectly to launch the installer, but the user has to manually click repair.

View 6 Replies

How To Activate A Button With The Ctl And A Key Combination

Feb 11, 2009

i would like to know that is there any way to activate a button with the Ctl and a key combination
we can do it with Alt and the key combination but my client is asking for ctrl & the key combination i have searched a lot but failed to find anything.

secondly :
i have used the alt & key combination for my buttons but the prob. is unless and untill the user presses the alt key the key combination is not highlighted. i have seen progs. where the key that is used for e.g. i have given &Add then the 'A' key is highlighted always with the underline. but when i am doing it by giving the name as &Add unless and untill the user presses alt the underline under A doesnt appear. do i have do more than just giving "&Add".

View 4 Replies

RDP Activate On Remote Machines?

Dec 29, 2009

I have a need to activate remote desktop on machines out in the field and have created a VB button that takes a workstation name from a textbox and activates via a WMI call. problem is that it pops back with an "invalid parameter" error.

View 3 Replies

Why Can't Activate Edit And Continue

Apr 29, 2012

Why can't I activate Edit And Continue? When I go into the Options, "Enable Edit And Continue" is checked but it's not allowing me to edit code at run time.

View 2 Replies

Activate Application Through External Link

May 19, 2012

I want to be able to activate my application through my website. Like AIM, they have a protocol "aim?.." what ever, I was wondering how I might go about that? My application is standalone, I wonder if this would reduce the chances of this being possible.

View 2 Replies

Activate Robotic Parts Using A Pic Microcontroller With Vb?

Sep 21, 2009

i want to activate robotic parts using a pic microcontroller with vb.basically i want to use the thechniques shawn in this video :

[URL]

here are my questions :

1 what activex do i add ?

2 are there any references i need to add ?

3 are there any imports statements i need to add ?

4 are there classes i can add ?

5 what commands do i use for output ?

6 what commands do i use for input ?

7 can you recomend a specific microcontroller ?

8 how do i add hardware to the device ?

9 what commands do i need to add so the software doesn't glitch ?

View 37 Replies

Activate SSL When Application Logs On To A Ftp Server?

Aug 28, 2010

I need to activate SSL when my application logs on to a ftp server. I'm searching the net and I can't find some piece of code to work, the username and the password are in plaintext, they are visible

I use this for now but it doesn't work:

Dim request As FtpWebRequest = CType(WebRequest.Create(ftp://ftpwt.com), FtpWebRequest)
request.Credentials = New NetworkCredential("user", "password")
request.EnableSsl = True
request.Method = WebRequestMethods.Ftp.ListDirectory
request.KeepAlive = False

View 4 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved