how do i flip a TMemo over like a post-it note

Go down

how do i flip a TMemo over like a post-it note

· #1

i have a TMemo and i wrote stuff on it

i want to flip it over and write on the back

i checked the object inspector and there is no Flip property. is it in a different package

Re: how do i flip a TMemo over like a post-it note

· #2

I'm new too, so forgive me, but... the back?

Re: how do i flip a TMemo over like a post-it note

· #3

yes the back. a post-it has two sides. i paid for the whole memo

Re: how do i flip a TMemo over like a post-it note

· #4

I admire the consumer-rights angle.

A TMemo has one side. It is a rectangle of text on a screen, and the screen is where the back would be. What you want is two memos that take turns:

pascal
procedure TForm1.FlipButtonClick(Sender: TObject);
begin
  FrontMemo.Visible := not FrontMemo.Visible;
  BackMemo.Visible := not FrontMemo.Visible;
end;

Put both memos in the same place with the same size, start with BackMemo.Visible := False, and the button "flips" the note.

A tidier way is a TPageControl with two pages and ShowTabs := False. Then flipping is one line:

pascal
Note.ActivePageIndex := 1 - Note.ActivePageIndex;

Read the error message. Then read it again.

Re: how do i flip a TMemo over like a post-it note

· #5

i tried flipping it for real. turned my monitor around

there is nothing on the back. just a sticker and some dust

Re: how do i flip a TMemo over like a post-it note

· #6

For the record, that sticker is the only thing in this thread that actually has two sides.

Re: how do i flip a TMemo over like a post-it note

· #7

the two memos thing works!! i flipped it 40 times

follow up: can i crumple it and throw it away

Re: how do i flip a TMemo over like a post-it note

· #8

BackMemo.Free. Do not ask about the trash can.

Forum rules 1 to 10 apply. Yes, to you.

Go up

Sign in to reply