Friday, December 15th 2017, 7:03pm UTC+1

You are not logged in.

  • Login
  • Register

Dear visitor, welcome to SEGGER Forum. If this is your first visit here, please read the Help. It explains how this page works. You must be registered before you can use all the page's features. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

atices

Beginner

Date of registration: Aug 28th 2015

Posts: 1

1

Tuesday, May 17th 2016, 8:19am

MULTIPAGE

GUI_KEY_PGUP Switches to the next page.
GUI_KEY_PGDOWN Switches to the previous page.


According to emwin document . I use GUI_SendKeyMsg(GUI_KEY_PGUP , 1 ) but I cant switch to next page
.
I have 6 sub-page same as in ->>>>> https://www.segger.com/cms/admin/uploads…GET_Multipage.c


You can switch between pages in sample demo , but ı cant switch my multipage.




SEGGER - Schoenen

Super Moderator

Date of registration: Aug 13th 2015

Posts: 443

2

Wednesday, May 18th 2016, 3:44pm

Hello,

I have overwritten the last lines of the WIDGET_Multipage.c sample:

C/C++ Source code

1
2
3
  while (1) {
	GUI_Delay(100);
  }


With these ones:

C/C++ Source code

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
  MULTIPAGE_SelectPage(hMultiPage, 0);
  while (1) {
	GUI_SendKeyMsg(GUI_KEY_PGUP, 1);
	GUI_Delay(200);
	GUI_SendKeyMsg(GUI_KEY_PGUP, 0);
	GUI_Delay(200);
	GUI_SendKeyMsg(GUI_KEY_PGUP, 1);
	GUI_Delay(200);
	GUI_SendKeyMsg(GUI_KEY_PGUP, 0);
	GUI_Delay(200);
	GUI_SendKeyMsg(GUI_KEY_PGDOWN, 1);
	GUI_Delay(200);
	GUI_SendKeyMsg(GUI_KEY_PGDOWN, 0);
	GUI_Delay(200);
	GUI_SendKeyMsg(GUI_KEY_PGDOWN, 1);
	GUI_Delay(200);
	GUI_SendKeyMsg(GUI_KEY_PGDOWN, 0);
	GUI_Delay(200);
  }


it works as intended.

Has your multipage the focus?

you can set the focus with WM_SetFocus().

Regards,
Sven