Results 1 to 3 of 3

Thread: [RESOLVED] If ....Else....small problem !!!

Hybrid View

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Dec 2005
    Posts
    570

    Resolved [RESOLVED] If ....Else....small problem !!!

    Hi,

    Could you please help me in the following querry?

    If txtOpeningBalance > 0 Then 'if there is no value in the textbox
    txtOpeningBalance = 0#
    Else
    txtOpeningBalance= 'here what i need is if there is a value in the textbox (means in that related field in the table), it should show the same value in that textbox. I am retrieving the values from rs.

    Seema_S

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: If ....Else....small problem !!!

    VB Code:
    1. If txtOpeningBalance > 0 Then 'if there is no value in the textbox
    2.     txtOpeningBalance = 0
    3. Else
    4.     txtOpeningBalance= rs.Fields.Item("OpeningBalance").Value
    5. End If
    Where OpeningBalance is the actual name of the field in your database/recordset.

  3. #3

    Thread Starter
    Fanatic Member
    Join Date
    Dec 2005
    Posts
    570

    Re: If ....Else....small problem !!!

    Thanks for the help.

    Seema_S

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