You should call this method with inline C:
WiFi.softAPdisconnect(true);
Thanks That worked great.
I was trying to find details on the web but couldn't, is there a good URL?
for reference this is what I used (not being a C programmer):
public Sub StopAP
Log("Stop AP")
RunNative("stopAP", Null)
End Sub
#if C
#include <ESP8266WiFi.h>
void stopAP (B4R::Object* u) {
WiFi.softAPdisconnect(1);
}
#end if
For information I'm using it to allow multiple 8266s to be configured (using something similar to your configurator). If all are powered up at the same time then the B4a end selects one which is configured to the wifi. Then the AP is disable. The B4a then selects another which can be configured. I send a command to flash the LED on the 8266 to identify which one is currently connected.