Arsip: wordwrap pada dbgrid??

 
user image
more 18 years ago

imunk

tanya lagi neh mas.... (wah lagi semangat nanya neh..:)) kalo kita pake label, kita bisa set tampilannya kalo datanya banyak bisa turun kebawah (jadi mirip memo deh) pake wordwrap kalo gak salah, nah kalo itu diterapkan di dbgrid bisa gak ya mas...?? makasih sebelumnya.... maju terus.
user image
more 18 years ago

gaussac

Coba pake ini, mudah2an bisa ngebantu procedure TForm1.DBGrid1DrawDataCell(Sender: TObject; const Rect: TRect; Field: TField; State: TGridDrawState); var P: array of char; {array size is number of characters needed} BS: tBlobStream; {from the memo field} S: String; begin if Field is TMemoField then begin with (Sender as TDBGrid).Canvas do begin BS:= tBlobStream.Create(TBlobField(Field), bmRead); FillChar(P, SizeOf(P),#0); {terminate the null string} BS.Read(P, 50); {read 50 chars from memo into blobStream} BS.Free; S:= StrPas(P); while Pos(#13, S) > 0 do S[Pos(#13, S)] := ' '; while Pos(#10, S) > 0 do S[Pos(#10, S)] := ' '; FillRect(Rect); {clear the cell} TextOut(Rect.Left, Rect.Top, S); {fill cell with memo data} end; end; end;
user image
more 18 years ago

imunk

@gaussac aku dah coba coding yg dari mas gaussac, tapi ko gak jalan ya... gimana neh mas gaussac, bisa kasih coding gak? @all ada yg bisa bantu aku gak? tolong dong.... maju terus.
user image
more 18 years ago

deLogic

coba ke sini deh: http://www.delphi-id.org/dpr/index.php?name=PNphpBB2&file=viewtopic&t=812&highlight=
more ...
  • Pages:
  • 1
Share to
Local Business Directory, Search Engine Submission & SEO Tools FreeWebSubmission.com SonicRun.com