Results 1 to 9 of 9

Thread: Passing Data Over Form Problem

Threaded View

  1. #7

    Thread Starter
    New Member
    Join Date
    Sep 2006
    Posts
    14

    Re: Passing Data Over Form Problem

    Saeem My English is not good enough to explain my problem lol,

    here is my problem condition
    first i declared a public variable on "Main.Form"

    VB Code:
    1. Public text1 As Integer
    2.     Public text2 As Integer
    3.     Public text3 As Integer

    On the second form i have 3 textbox and 1 button,when the button clicked it will first verified the data whether numeric or not and if it's ok continue to set the value from the three text box into 3 public variable on Main.Form
    VB Code:
    1. ElseIf IsNumeric(txt1.Text) = True And IsNumeric(txt2.Text) = True And IsNumeric(txt3.Text) = True Then
    2.                         Main.text1 = CInt(txt1.Text)
    3.                         Main.text1 = CInt(txt2.Text)
    4.                         Main.text1 = CInt(txt3.Text)
    5.                     End If

    and also i have a function in module which something like this :
    VB Code:
    1. test = (ascode * Main.text1)
    2. test = (ascode / Main.text2)
    3. test = (ascode - Main.text3)


    somehow when i trigger the function the Main.Text1,Main.Text2,Main.Text3 value inside of the module always changed into hex value! ,
    Sample :
    VB Code:
    1. Main.text1 = &H28
    2. Main.text2 = &H5
    3. Main.text3 = &H3C

    how to always keep real integer inside the module?? i didn't experience this on normal Form , already tried with Cint(Main.text1) , all same always hex value
    Last edited by Sabour; Sep 21st, 2006 at 09:25 PM.

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