trichview.support
Re: Using Richview as a log |
Author |
Message |
Peter |
Posted: 06/19/2003 1:39:22 Hey that works. Now I am starting to understand the role of the STYLE component. Ok now tell me if I use say AddNLWTag and sequentialy create a tag number so that each time a block of text is added in tags it with a number, can I click on say a word out of a particular block of text and get an event that returns that tag? What I want to do is as before use a rich view to display a log. If say an error occurs it comes up and displays it in red. The user can click anywhere in that line or group of lines, it returns the tag value of say 10023 and my program goes and finds the extra info stored elsewhere for event 10023. Hope you can understand what I am asking? Regards, Peter "Chris de Gelder" <[email protected]> wrote in message news:[email protected]... > Make two styles one for red and for green. > > use richview1.add('my log text', stylenumber) > > to add a line. > > "Peter" <[email protected]> schreef in bericht > news:[email protected]... > > Hi again. > > > > > > I have actually three questions but for 1 different applications but to > save > > time I will ask them here.... > > > > > > I would like to use a Richview as a display for log file. > > > > What i want to do is say insert a line of text in RED for a proble > > > > and say GREEN for a normal operation. > > > > > > So as the program runs, the richview slowly fills with green and red lines > > of info. > > > > So how can I do this programicly? Which example is th ebest to look at? > > > > > > When I use a normal memo and the display is say 200 lines long I simply > > delete lines at the begining to reduce size but also taking in mind my > next > > questions, how can I delete stuff form this method? > > RichView1.Clear; to clear all > > or > > procedure DeleteParas(FirstItemNo, LastItemNo: Integer); > > > > > > > > As I add a line, I would like to somehow tag it so the user can CLICK on > one > > of the red lines and it will pass the tag or whatever to my program so I > can > > call up extra info? Is that possible with all I want to do above? > > See the tutorials 2_7 (tags (integer)) > > procedure TForm1.RichView1Jump(Sender: TObject; id: Integer); > var ItemNo: Integer; > Tag: Integer; > begin > ItemNo := RichView1.GetJumpPointItemNo(id); > Tag := RichView1.GetItemTag(ItemNo); > Panel1.Caption := 'Clicked: Item with Tag='+IntToStr(Tag); > end; > > > > > > > > > I am sorry to ask the above but I like using the stuff even though I > haven't > > really understood everything about it yet.. > > Regards, Peter > > > > > > > > > > |
Powered by ABC Amber Outlook Express Converter