There are some samples programs for VB and VC that are shipped with NIDAQ 6.9.1 or later. If you have one of those versions, you can check in your Measurement Studio folder to see if you can find the VB and VC folders. If not, you can update NIDAQ by going to Control Panel>>Add/Remove Programs, find the NI-DAQ entry, and you can update it.
Otherwise, I am attaching the two shipping examples of NIDAQ for VB.
When using the digital I/O lines of your E-Series board, first you need to configure them (as inputs or outputs) and then you can either write or read from them.
When using component works, the first thing that you will need to do would be to drag the DI, DO or DIO component to the form, right click on it and go to Properties. Right here you will configure the digital ports for the type of operation: input or output.
Once you have configured the ports, all you have to do is write or read from the port/lines. This task has to be implemented with code.
The following example was implemented for the PCI-DIO-96, you can take a look at it, modify it so that the program only access one port and run it!