• userform formats (2000)

    Author
    Topic
    #408771

    Your code is written so that whenever you change Textbox1 it fills the items with the values from the other textboxes. If you have nothing in the other textboxes the cells are cleared.

    Remove the textbox1 change event and it shouldn’t do this. What are you trying to do with that code? You can put the code in the event of a command button just rewrite the info only after you press the command button to “confirm” editing or adding.

    Steve

    Viewing 3 reply threads
    Author
    Replies
    • #866038

      thanks steve for the reply,

      what i want to do is use the userform to fill data..

      let say..in row 1.that is a3..i put number 1..and i will fill continously until the last row nad that is q3..

      then i will move to the next row..and that is a4..iand i will repeat the same operation..

      let say..in the 1st row..in cell b3..i accidentally put awrong speling..and i want to edit it..b4 this..using the same userform and the same coding..in the number box , i will just simply key in number 1..and walla..all the data that i have key in..will apperaed i the userform..so i just select which cell that i’ve make mistake..and edit it..

      and hit the button..”accept the data” and the mistake will be corrected..

      but in the sample file that i attach..this thing is not happen..

      after i fill the number box..eg..number 1..after i hit enter or tab..all the data in the same row..from a3 to q3..will be deleted automatically..

      thats very weird and i dont know how to fix it..thanks again

      • #866068

        Your code after the change event writes to the cell what is in the textboxes.

        Why not read the cell contents into the textboxes instead of putting the textbox value into a cell (your code)
        Range(“A3”).Offset(TextBox1.Value, 0).Value = TextBox1.Value

        Put the cell values into the textbox:
        TextBox1.Value = Range(“A3”).Offset(TextBox1.Value, 0).Value

        Then they can see and edit and then confirm

        Steve

        • #866081

          Thanks steve for the prompt reply..
          but i think that ..you ..dont understand what i’m trying to do..

          for more information , please refer to my new file that i attached

          you see in this file, every time i want to edit the data , i just put the number in the item box..let say #5 and hit enter..

          after the that i can edit it easily..after i hit the accept data button..the correction that i’ve submit will be appear and yet..the data that i dont want to edit ..remains

          this is really totally different with the one that i post earlier..even though i use the the same coding , i dont get the same result..

          what am i doing wrong..please refer to my new attachment..thanks

          • #866131

            You do not have the same coding. In the textbox exit of the latest one, you fill the other textboxes with the values from the cells (as I had suggested based on your original post).

            In your original one, you replace the cell contents with the values from (empty) textboxes so you are “clearing the cells”

            Steve

            • #866498

              Have you tried using the DATA – Form function. This is a very quick & easy solution for entering editing & searching data.

            • #866716

              thanks to all.cheers

            • #866717

              thanks to all.cheers

            • #866499

              Have you tried using the DATA – Form function. This is a very quick & easy solution for entering editing & searching data.

          • #866132

            You do not have the same coding. In the textbox exit of the latest one, you fill the other textboxes with the values from the cells (as I had suggested based on your original post).

            In your original one, you replace the cell contents with the values from (empty) textboxes so you are “clearing the cells”

            Steve

        • #866082

          Thanks steve for the prompt reply..
          but i think that ..you ..dont understand what i’m trying to do..

          for more information , please refer to my new file that i attached

          you see in this file, every time i want to edit the data , i just put the number in the item box..let say #5 and hit enter..

          after the that i can edit it easily..after i hit the accept data button..the correction that i’ve submit will be appear and yet..the data that i dont want to edit ..remains

          this is really totally different with the one that i post earlier..even though i use the the same coding , i dont get the same result..

          what am i doing wrong..please refer to my new attachment..thanks

      • #866069

        Your code after the change event writes to the cell what is in the textboxes.

        Why not read the cell contents into the textboxes instead of putting the textbox value into a cell (your code)
        Range(“A3”).Offset(TextBox1.Value, 0).Value = TextBox1.Value

        Put the cell values into the textbox:
        TextBox1.Value = Range(“A3”).Offset(TextBox1.Value, 0).Value

        Then they can see and edit and then confirm

        Steve

    • #866039

      if it so compicated to explained steve..do you mind ..adjust my code and give me some sample file ..the way that

      you explained to me at above..i haveno idea to fix this mess..thanks

    • #866016

      Hello again guys.

      I’ve created a useform..
      It works fine..

      but the problem occured when i want to edit the data..
      it seems that after i enter the number of the pupils in column a ,
      it will automatically delete all the data in the same row..

      what i want to do is edit certain data in the particular rows ,
      but after i fill the number in the item box in column a , let say 1,
      after i hit enter and go to the name column..that is in column b , all the data in teh same row will be deleted automatically..

      how can i overcome this problem..thanks a bunch

      plz refer to attachment

    • #866017

      Hello again guys.

      I’ve created a useform..
      It works fine..

      but the problem occured when i want to edit the data..
      it seems that after i enter the number of the pupils in column a ,
      it will automatically delete all the data in the same row..

      what i want to do is edit certain data in the particular rows ,
      but after i fill the number in the item box in column a , let say 1,
      after i hit enter and go to the name column..that is in column b , all the data in teh same row will be deleted automatically..

      how can i overcome this problem..thanks a bunch

      plz refer to attachment

    Viewing 3 reply threads
    Reply To: userform formats (2000)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: