Get a witness
It is important that you establish a record of denials. Therefore, at the time that visitation is denied, you should have an independent party witness the denial. The best witness is the local police department. They are guaranteed to assist if there is a custody/visitation order in place. Even if there isn't an order, it still benefits you to have a report of the incident.
Establish a custody order
Legal custody gives the right to access (to the child and the child's records). Physical custody is your time with the child. If you are the putative father (i.e., do not already have legal custody), you will need to file a Legitimation action. If you are the legal father or mother and there is no court order for visitation, you will need to file a Custody action. Either action will be filed in the Superior Court of the county that the child lives in.
Hold them in contempt
If there is a court order in place that the other parent is violating, you can file a Motion for Contempt with the court responsible for your case. A Contempt Motion is your way of asking the judge to remind the other parent that they are required to abide by the order, or to punish the parent for their failure to do so.
Modify your existing custody order
Especially if you have initiated contempt proceedings in the past, you may find it necessary to modify your existing custody order to increase your visitation, put additional requirements or restrictions in place, or become the primary custodian. Modification of custody can be done in conjunction with a contempt action.
Keep up with your responsibilities
Regardless of the other parent's behavior, you must keep up your own responsibilities. Continue to pay child support either as ordered (if there is a court order), agreed upon, or reasonably required for your child's necessities. You should also continue to reach out to your child. Do not give up on attempts to visit, even getting the assistance of other family members if possible. Also use other means of contacting your child, such as placing telephone calls and writing letters. It may be helpful to your continued relationship with your child that they know you never gave up on them.