AWS SDK for .NET Documentation
DetachVpnGateway Method (request)
AmazonAmazon.EC2AmazonEC2DetachVpnGateway(DetachVpnGatewayRequest) Did this page help you?   Yes   No    Tell us about it...
Detaches a VPN gateway from a VPC.
Declaration Syntax
Parameters
request (DetachVpnGatewayRequest)
Detach Vpn Gateway request
Return Value
Detach Vpn Gateway Response from the service
Remarks
You do this if you're planning to turn off the VPC and not use it anymore. You can confirm a VPN gateway has been completely detached from a VPC by describing the VPN gateway (any attachments to the VPN gateway are also described). You must wait for the attachment's state to switch to detached before you can delete the VPC or attach a different VPC to the VPN gateway.
Exceptions

Assembly: AWSSDK (Module: AWSSDK) Version: 1.5.60.0 (1.5.60.0)