Results 1 to 8 of 8

Thread: String Problem...

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jul 2004
    Posts
    235

    String Problem...

    Erm...

    I got this

    Dim ooo as string = "0000"

    when i textbox1.text = ooo

    It returns me 0 instead of 0000...

    any help will be appreciated....

  2. #2
    Frenzied Member mar_zim's Avatar
    Join Date
    Feb 2004
    Location
    Toledo Cebu City.
    Posts
    1,416
    hey man...i tried it...but works fine in my machine..
    VB Code:
    1. dim s as string = "0000"
    2. textbox1.text=s

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Jul 2004
    Posts
    235
    but i;m trying to put inside a for loop...so that i can create some timings...
    example.....

    like 0000 to 0600
    0600 to 1200

    and so on.....

    any help will be appreciated...

    thxn

  4. #4
    Fanatic Member brown monkey's Avatar
    Join Date
    Jun 2004
    Location
    Cebu
    Posts
    552
    it's a hint. you want us to do everything?

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Jul 2004
    Posts
    235
    nope...i want to know how to go about doing it....

  6. #6
    Fanatic Member brown monkey's Avatar
    Join Date
    Jun 2004
    Location
    Cebu
    Posts
    552
    like this?
    VB Code:
    1. Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
    2.         Dim i As Integer
    3.         Dim s As String
    4.         For i = 0 To 100
    5.             s &= Format(i, "00000") & vbCrLf
    6.         Next
    7.         MessageBox.Show(s)
    8.     End Sub
    if not, sorry.

  7. #7

    Thread Starter
    Addicted Member
    Join Date
    Jul 2004
    Posts
    235
    what does the 'i' suppose to mean ??
    i dont really get what the codes meant...

  8. #8
    Fanatic Member brown monkey's Avatar
    Join Date
    Jun 2004
    Location
    Cebu
    Posts
    552
    that's the iterator. you can create your own iterator.

    perhaps these also help

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width