Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. Replacing, removing lines.

Replacing, removing lines.

Scheduled Pinned Locked Moved Visual Basic
9 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    NANCO
    wrote on last edited by
    #1

    can anyone tell me a way to replace a line and to remove. I used this; doesn't work. ex:-Richtextbox1.lines(0).replace("sdf")

    K G 2 Replies Last reply
    0
    • N NANCO

      can anyone tell me a way to replace a line and to remove. I used this; doesn't work. ex:-Richtextbox1.lines(0).replace("sdf")

      K Offline
      K Offline
      kubben
      wrote on last edited by
      #2

      In vb.net you do .Replace("sdf","") to remove that section. Ben

      N 1 Reply Last reply
      0
      • K kubben

        In vb.net you do .Replace("sdf","") to remove that section. Ben

        N Offline
        N Offline
        NANCO
        wrote on last edited by
        #3

        If you could give a more clear coding it will be appreciated.

        1 Reply Last reply
        0
        • N NANCO

          can anyone tell me a way to replace a line and to remove. I used this; doesn't work. ex:-Richtextbox1.lines(0).replace("sdf")

          G Offline
          G Offline
          Guffa
          wrote on last edited by
          #4

          Your first error: The Replace method needs more than one parameter. Your second error: The Replace method doesn't change a string, it returns a new string instance that contains the changes. Richtextbox1.lines(0) = Richtextbox1.lines(0).Replace("sdf", String.Empty)

          --- single minded; short sighted; long gone;

          N 1 Reply Last reply
          0
          • G Guffa

            Your first error: The Replace method needs more than one parameter. Your second error: The Replace method doesn't change a string, it returns a new string instance that contains the changes. Richtextbox1.lines(0) = Richtextbox1.lines(0).Replace("sdf", String.Empty)

            --- single minded; short sighted; long gone;

            N Offline
            N Offline
            NANCO
            wrote on last edited by
            #5

            someone pls help me.

            C G 2 Replies Last reply
            0
            • N NANCO

              someone pls help me.

              C Offline
              C Offline
              CPallini
              wrote on last edited by
              #6

              Then you need to be more precise in you postings. :mad:

              If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler. -- Alfonso the Wise, 13th Century King of Castile.

              1 Reply Last reply
              0
              • N NANCO

                someone pls help me.

                G Offline
                G Offline
                Guffa
                wrote on last edited by
                #7

                Standard question #1: What do you mean by "not working"? Standard question #2: What error message do you get? Standard question #3: What does your code look like?

                --- single minded; short sighted; long gone;

                N 1 Reply Last reply
                0
                • G Guffa

                  Standard question #1: What do you mean by "not working"? Standard question #2: What error message do you get? Standard question #3: What does your code look like?

                  --- single minded; short sighted; long gone;

                  N Offline
                  N Offline
                  NANCO
                  wrote on last edited by
                  #8

                  no error messages just doesn't work.(doesn't do anything)

                  G 1 Reply Last reply
                  0
                  • N NANCO

                    no error messages just doesn't work.(doesn't do anything)

                    G Offline
                    G Offline
                    Guffa
                    wrote on last edited by
                    #9

                    Standard question #3: What does your code look like?

                    --- single minded; short sighted; long gone;

                    1 Reply Last reply
                    0
                    Reply
                    • Reply as topic
                    Log in to reply
                    • Oldest to Newest
                    • Newest to Oldest
                    • Most Votes


                    • Login

                    • Don't have an account? Register

                    • Login or register to search.
                    • First post
                      Last post
                    0
                    • Categories
                    • Recent
                    • Tags
                    • Popular
                    • World
                    • Users
                    • Groups