PORTS Forum

Ports and Interfaces => Serial Ports => Topic started by: titan2020 on October 07, 2011, 09:59:11 am

Title: Setting Parity via combo box drop down list in VB 2010
Post by: titan2020 on October 07, 2011, 09:59:11 am
Hello,

I'm writing an application that will use the SerialPort class. It will have a com port setup form that will have combo boxes for the port properties. Setting the PortName, BaudRate and DataBits are no problem. How can I set the SerialPort.Parity, SerialPort.StopBits, and SerialPort.Handshake to the selected values in their respective combo boxes.

Thank you,
Title: Re: Setting Parity via combo box drop down list in VB 2010
Post by: Jan Axelson on October 07, 2011, 10:33:37 am
Use your existing combobox code as a model. Replace DataBits with Parity, StopBits, or Handshake and edit the combobox data as appropriate. My ComPortTerminal application has a Handshake example.

http://www.lvr.com/serport.htm#my_example_code

Jan
Title: Re: Setting Parity via combo box drop down list in VB 2010
Post by: titan2020 on October 07, 2011, 03:34:36 pm
Thank you. I'm up and running