| | |
DropList Help?
![]() |
well to perform the math you have to convert the droplist values into numbers.because they(droplist values) always come in string format.use the VAL function to do the conversion like :-
dim a,b as integer
a=val(trim(combo1.text))
b=val(trim(combo2.text))
after this you can perform any mathematical operations like :-
dim subs as integer,divd as double
subs=a-b
divd=round(a/b)
use the ROUND() to round up any values.
then u can display the output like :-
label1.caption="Substraction :" & subs
label2.caption="Division :" & divd
hope it'll help.
regards
Shouvik
dim a,b as integer
a=val(trim(combo1.text))
b=val(trim(combo2.text))
after this you can perform any mathematical operations like :-
dim subs as integer,divd as double
subs=a-b
divd=round(a/b)
use the ROUND() to round up any values.
then u can display the output like :-
label1.caption="Substraction :" & subs
label2.caption="Division :" & divd
hope it'll help.
regards
Shouvik
Shouvik_The_Expert_Coder
Have a problem? Don't worry just give me a call and I'll fix it for you.
Have a problem? Don't worry just give me a call and I'll fix it for you.
![]() |
Similar Threads
- trojans wont let me connect to internet (Viruses, Spyware and other Nasties)
- help with hjt and vx2/urllogic (Viruses, Spyware and other Nasties)
- help with hjt and vx2/urllogic (split from http://www.daniweb.com/techtalkforums/showthread.php?t=18540&page=1&pp=15) (Viruses, Spyware and other Nasties)
- 213.159.117.130 trojan.. help!! (Viruses, Spyware and other Nasties)
- Populating a fields on a form base on a selected item from a droplist. (PHP)
Other Threads in the Visual Basic 4 / 5 / 6 Forum
- Previous Thread: error "Unrecognized database format"
- Next Thread: Passing Variants from VB to VC++
Views: 1233 | Replies: 11
| Thread Tools | Search this Thread |
Tag cloud for Visual Basic 4 / 5 / 6
6 7 2007 access activex append application array banned basic beep bmp c++ cd client code coffeehouse college column connection connectionproblemusingvb6usingoledb convert copy ctrl+f data database date delete designer dissertations dissertationthesis dissertationtopic error excel excelmacro filename form grid group header image implements inboxinvb keypress list listbox listview liveperson login machine mail match metadata nice number objectinsert open oracle os outlook password pause pdf prime print printer problem program query random range-objects readfile record refresh report reports retrieve save search sendbyte sort sound spectateswamp sql string subroutine table tags textbox time variable vb vb6 vb6.0 vba vista visual visualbasic web windows





