I am building a POS software using visual basic and trying to display the customer screen on the customer facing screen.
device used is APT 200 series - touch screen POS
i have created a customer form and used the following code in the main form load event
Dim secondaryDisplay As Screen = Screen.AllScreens(1)
'Create a new form for the secondary display
Dim customerscreen As New Form()
'Set the form's properties to display on the secondary display
customerscreen.StartPosition = FormStartPosition.Manual
customerscreen.Location = secondaryDisplay.Bounds.Location
customerscreen.WindowState = FormWindowState.Maximized
customerscreen.FormBorderStyle = FormBorderStyle.None
'Show the form on the secondary display
customerscreen.Show()
but showing the following error in the following line
Dim secondaryDisplay As Screen = Screen.AllScreens(1)
Index was outside the bounds of the array.
can anyone help on this