How to work on one form

Hey everybody
First of all, I started my application by using 3 forms :
I'd like to use one form to switch between them
i got this solution to show form2 and hide Form 1 but this isn't smell good :D
please help to solve this, 
I hope u understood me ! 
thanks ^^

what i want is when i run the program i got the form1 ( all controls) and when i click on next it should show all controls of the form2 in the same size of form1, 
ps : like when we install a program we dont notice that the first form is gone and show the secontd, we notice that controls change in the same form.
So you still want to use multiple forms in the application, but you need to ensure that each form opens with the same size and position as the previous form, like a wizard.
In the form that you are opening (Form2 in your example), create a constructor that accepts the size and location information.   Use this size and location information in the form load event.
Private _mylocation As Point
Private _mysize As Size
Public Sub New(ByVal MyLocation As Point, ByVal MySize As Size)
InitializeComponent()
_mylocation = MyLocation
_mysize = MySize
End Sub
Private Sub Form_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Me.Location = _mylocation
Me.Size = _mysize
End Sub
Then, in the form that does the opening (Form1 in your example) create the new form with the information about the size and location.
Private Sub Button_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnNext.Click
Dim NextForm As New Form2(Me.Location, Me.Size)
NextForm.Show()
Me.Hide()
End Sub
If you allow Form2 to be moved and resized and if you have an option to close form2 (or a Back button) then you have to feed that changed size and location  information back to Form1 when Form2 closes:
Private Sub Form2_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
Form1.Location = Me.Location
Form1.Size = Me.Size
Form1.Show()
End Sub

Similar Messages

  • How do I use one form field to enter data into another form field?

    Does anyone know how I can code a form so that when I select
    a name in one drop-down form field, I can ensure that the person's
    e-mail address will appear in another text field?
    Thanks.

    Thanks Roel,
    I remember that I tried to define multiple DML. but it did not work for Apex gets confused.... which items belongs to which table...
    instead-of-triggers (to process the inserts/updates/deletes) Can you pls, elaborate more on this solution ... ?
    Regards,
    Fateh..

  • Can multiple people work on one form

    We do onsite assessments. I am attempting to determine the best method to have all of my assessors' feedback compiled into one form. Any help will be much appreciated!

    The only link I have is to manage your team account http://forums.adobe.com/thread/1460939?tstart=0
    The only Adobe program/process for team work that I know of is Adobe Anywhere, but that requires a very different process
    Adobe Anywhere http://www.adobe.com/products/adobeanywhere.html
    http://www.creativeimpatience.com/adobe-anywhere-enterprise-solution/

  • How use multi user one form same time

    I have four different form
    1.Mainmenu from
    2.Expense payment form
    3.salary payment form
    4. purchases payment form
    My problem is when any user use one form same time other user can not use that form
    Such as user aamir are using expense_payment_ form if that time user Kashif try to open expense_payment_ form the oracle form not give permission to user kashif . it’s mean only one user can use that form no other can not use same form that time
    Please give me idea how I solve that problem and use same form multi user same time
    thanking you
    aamir

    I have four different form
    1.Mainmenu from
    2.Expense payment form
    3.salary payment form
    4. purchases payment form
    My problem is when any user use one form same time
    other user can not use that form
    Such as user aamir are using expense_payment_ form
    if that time user Kashif try to open expense_payment_
    form the oracle form not give permission to user
    kashif . it’s mean only one user can use that form no
    other can not use same form that time
    Please give me idea how I solve that problem and use
    same form multi user same time
    thanking you
    aamirWhat do you mean by not give permission???
    What is your Forms version??
    Are you getting any errors?? what is the error code???
    I also suggest you read the [url http://forums.oracle.com/forums/help.jspa]FAQ and [url http://blogs.oracle.com/shay/2007/03/02]The 10 Commandments on OTN Forum Posting
    Tony

  • How to work with PDF forms filled up by the user?

    I would appreciate any help regrading work with PDF Forms.
    I present a PDF form to users with several fields that they need to fill up.
    My problem is to receive the values of these fields back.
    In PDF forms you can add a "Submit" button that sends the fields to a given servlet.
    That, however, takes me out of my session and out of JSF navigation model.
    I can't find a way to go back.
    The PDF form is shown in an iframe, so Java Script outside of the iframe cannot know about the "Submit" button action.
    Thanks for any help or reference on this subject.

    Hi Sridhar
               Thanks for ur reply. but iam not getting any clear idea on forms.
    just i will tell u , wat i understood,if i am wrong pls correct me. in pe51 we create form layout
    and specify fields in required format, later run the program RPCEDTU0.wat is the program  for indian payroll?
    thanks in advance.

  • How come the same script only works in one form?

    I made a checkbox that when checked it makes another subform visible. The script works perfect in one pdf. When I used the same script in another pdf (except I changed the variables of course) it doesn't work??????
    It's set the same in both scripts. The subform name is exactly "CR" in uppercase. In the Events its set to click*, javascript at the client. Here is the script. Please let me know what's wrong????
    if (this.rawValue == 1)
    CR.presence = "visible";
    else
    CR.presence = "hidden";

    You have to have the object referenced correctly and that can include subform and section information.

  • How to work with HR forms

    Hi,
             i am new to HR Forms & Payroll Reporting.
    any one, pls send me step by step procedure for HR forms. I have gone through PE51 , how to connect the data to form.its really urgent.as i need to develop forms in 4.6C.
    thanku.

    Hi Sridhar
               Thanks for ur reply. but iam not getting any clear idea on forms.
    just i will tell u , wat i understood,if i am wrong pls correct me. in pe51 we create form layout
    and specify fields in required format, later run the program RPCEDTU0.wat is the program  for indian payroll?
    thanks in advance.

  • Same script..works in one form but in another keep getting "Date is not a constructor" error.

    Using this javascript in one of my forms to timestamp it, (just a simple protected text field.)
    form1.MainPage.DateTimeStamp::docReady - (JavaScript, client)
    if (form1.MainPage.DateTimeStamp.rawValue == null) {
            var now = new Date();
            form1.MainPage.DateTimeStamp.rawValue = nowtoDateString() + now.toTimeString();
    This timestamps the form as it should.  The problem is on another form I'm building I'm using the identical script, (with different absolute paths of course,) and I keep getting a javascript error about date not being a constructor.  I've type the script in ten bajillion times and I'm at a loss for what is causing this.
    All I want is a simpel javascrip where I can display the time/date from the users system in a text field.

    Hi,
    You are missing a . inbetween "now" and "toDateString()"
    Also you can simplify the script as it is in the docReady of the textfield:
    if (this.rawValue == null)
         var now = new Date();
         this.rawValue = now.toDateString() + " " + now.toTimeString();
    Hope tht helps,
    Niall
    Assure Dynamics

  • How Cartridge works in OAS/form server

    Hi, guys:
    I am deploying forms to the web.
    Since the base HTML file for cartridge implementation is the
    same as that for non-cartridge implementation, I really can not
    figure out how the OAS/form server knows if using Cartridge or
    non-cartridge implementation. (ie: Do I need call the
    Cartridge in my base HTML?)
    Your help is highly appreciated.
    Sherry
    null

    Sherry,
    Is the cartridge necessary for internet (browser) deployment or
    just from intranet (application) deployment?
    Richard
    Sherry Yang (guest) wrote:
    : Hi, guys:
    : I am deploying forms to the web.
    : Since the base HTML file for cartridge implementation is the
    : same as that for non-cartridge implementation, I really can
    not
    : figure out how the OAS/form server knows if using Cartridge or
    : non-cartridge implementation. (ie: Do I need call the
    : Cartridge in my base HTML?)
    : Your help is highly appreciated.
    : Sherry
    null

  • How to work on one project but with two different computers

    I'm editing a movie.
    My computer might be overwhelmed with all the information - speed is slowed and it gets hot quickly.
    I would like to use my second computer where I have cloud installed
    to edit on the same timeline or in a different sequence to give my
    main computer a rest.
    Is that possible?
    Thank you for your help!

    As well as the reply from Anish about using your program on 2 computers, you need to ask in the program forum for how to best use the programs to do what you want
    http://forums.adobe.com/community/premiere_elements/content
    http://forums.adobe.com/community/premiere/content

  • How to work with standard forms

    hi all,
          when i execute the print programs for standard forms , it is not giving output?
          i hv modified form MEDRUCK (ex: uploaded LOGO)
    can i create a new program or modify a standard program for the form.

    Hi Praveen,
    If u want to change the layout of the standard form, copy the form and modify the layout. Depending on the layout, if there are any subsequent changes to be made in the print program. Then modify the copied program. We can assign this new program to the copied form using NACE.
    Secondly, we cant execute a print program. In case u want to test the layout/program for MEDRUCK, go to ME23n and check the print preview from there.
    Reward points if helpful....

  • How to work in one window...

    "and avoid opening up multiple windows, when going to a subfolder?

    Have this problem even with "Always open folders in a new window" unchecked?
    Solution:
    In the Finder menu: View > Show Toolbar (option-command-T)

  • How to use one form to calculate totals form 4 individual forms

    If i had 4 separate forms with 3 number fields each, how can i use one form to calculate theirs totals?
    Form 1 numbers + Form 2 numbers + Form 3 numbers + Form 4 numbers = Form with combined totals
    can anyone point me in the right direction?
    Thanks

    kwesij wrote:
    Can someone please help me on this,
    I am developing a jsp website and I want to use one form to submit data to 4 tables on mysql database and the tables are related by one foreign key.
    Can someone bail me out of this ....I've hit a hard brick wall!!!!...What's the problem? What does a brick wall look like?
    Connect to the database and execute four SQL INSERT/UPDATE statements as a single unit of work. The fact that you have one form shouldn't be an issue.
    I'll bet you're having trouble because you haven't layered the problem either in code or in your mind.
    I'd recommend that you write a POJO to take in some objects and execute the SQL. Once you have that running successfully you can worry about the form. Decouple the two.
    Computer science is all about decomposing large problems into smaller ones.
    %

  • Can one form submit to different servlets? Urgent!!!!

              Hi, all
              Can someone tell me how can I submit one form to two servlets?
              The case is:
              Some of data in one form need to pass to one servlet, and the rest of them need
              to pass to another servlet. E.g. an Order form in some site, the financial info
              will go to some secure SSL credit card payment gateway, the product and delivery
              infor will goto another servlet. How do u handle the case? Does anyone know?
              Thanx in advance
              Divid
              

    This sounds like a candidate for a controlling servlet that handles a single
              request, then forwards 'pieces' of each request to different servlets.
              Hope this helps
              Rob
              "JFan" <> wrote in message news:3b789f4c$[email protected]..
              >
              > Hi, all
              >
              > Can someone tell me how can I submit one form to two servlets?
              > The case is:
              > Some of data in one form need to pass to one servlet, and the rest of them
              need
              > to pass to another servlet. E.g. an Order form in some site, the financial
              info
              > will go to some secure SSL credit card payment gateway, the product and
              delivery
              > infor will goto another servlet. How do u handle the case? Does anyone
              know?
              >
              > Thanx in advance
              >
              > Divid
              

  • How can different people work on different tabs of one form

    Dear OTN Users,
    We are developing Client-Server application using D2K tools.
    We are using the new feature TAB of Forms 5.0 in our current
    development.
    We are currently have 10 or 12 tabs per form in our application
    and we need different people to work on it during development.
    How to over come the error of one's work overwriting other's work.
    All of them will be working on different tabs.
    Thanks in advance for you help
    null

    It's a really bad idea to have more than one person working on a
    single Form at one time. However, if you must...
    Try getting everything in the Form, except for your tabs,
    working first. Then take 12 copies of your Form (one for each
    tab) and give a copy to each of the 12 developers. Make sure
    that they name any objects that they create uniquely: this
    includes any blocks, procedures, tab canvases etc - nominate one
    person as 'design master' and make sure that anyone clears any
    new object names with the design master before creating them.
    When they have finished developing and testing their code
    individual for each of the single tab Forms, get someone to
    create a thirteenth Form, and then merge in all the objects
    created for the first tab. You can do this relatively easily by
    opening two Forms at the same time, and dragging the items from
    one Form to another.
    If you're feeling really clever, and you will have lot of
    maintenance to do on the Form, then you could reference the
    objects rather than copy them: in this case you would need to
    keep your 13 forms in perpetuity, but you could have parallel
    maintenance going on. However you decide to do it, be sure that
    you have a comprehensive test plan!
    You will find that you may save some time in this way, but it
    will take more man-hours (though less elapsed time) to develop
    the Form in this way, than by having a single person develop the
    whole Form.
    Simon Hedges
    Gloucester
    UK
    null

Maybe you are looking for