CariDotMy

 Forgot password?
 Register

ADVERTISEMENT

View: 2219|Reply: 6

Display data from two textbox to one textbox

[Copy link]
ieeya This user has been deleted
Post time 3-4-2007 12:42 AM | Show all posts |Read mode
Hai guys.....I need your help......


1.  How to display data from 2 textbox to one textbox in vb 6.0. I really need your help.




2. How display that data yang di search tu secara berturutan?Dalam textbox terbabit(saya nak display data terbabit spt cth di bwh)

cth: Data 1 : ID:123  Student : Siva
       Data 2 : ID:456  Student: Yana
       Data 3: ID:789  Student: Mohd
Reply

Use magic Report


ADVERTISEMENT


ieeya This user has been deleted
 Author| Post time 3-4-2007 12:44 AM | Show all posts

Reply #1 ieeya's post

Katakan terdapat 1 database yg menyimpan data tersebut dima ID merupakan primary key
Reply

Use magic Report

ieeya This user has been deleted
 Author| Post time 3-4-2007 12:45 AM | Show all posts

Reply #2 ieeya's post

I'will appreaciate any advised and comment
Reply

Use magic Report

Post time 3-4-2007 01:35 AM | Show all posts
txtbox1.text = txtbox2.text + txtbox3.text

ni bukan dalam vb6... tak ingat syntax vb6...
Reply

Use magic Report

Post time 3-4-2007 02:19 AM | Show all posts
camane laa textbox nak display list data cik kak.. ker aku yang tak paham soklan nih.. kalau nk display list kene laa pkai datasheet ker.. listbox ker..

kalau nak display dari one table, gune jer query find list dalam list box.. tak pon data sheet.
Reply

Use magic Report

Post time 3-4-2007 02:54 PM | Show all posts
soalan pertama macam yg padlie tunjukkan,

soalan kedua
buat satu temp. variable dan sambungkan semua data yg telah dicari,
dengan buat looping untuk sume rekod yg telah dicari dalam database

rekod.movefirst
do while not rekod.eof
    tmpString = "ID:" & rekod.column("ID") & " Student: " & rekod.column("Nama")
    if rekod <> rekod terakhir then
          tmpstring = tmpstring & vbcrlf
    end if   
    rekod.movenext
loop
textbox1 = tmpstring
Reply

Use magic Report

Follow Us
Post time 8-4-2007 12:28 PM | Show all posts
textbox1=textbox2 & " - " &  textbox3

so your data will display :
ID:123  Student : Siva - Data 2 : ID:456  Student: Yana
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

 

ADVERTISEMENT



 

ADVERTISEMENT


 


ADVERTISEMENT
Follow Us

ADVERTISEMENT


Mobile|Archiver|Mobile*default|About Us|CariDotMy

31-12-2024 04:54 AM GMT+8 , Processed in 0.043845 second(s), 21 queries , Gzip On, Redis On.

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

Quick Reply To Top Return to the list