void DoIt() { int marker_index = 0, idx; bool isrgn; double pos, rgnend; char* name; while( EnumProjectMarkers(marker_index++, &isrgn, &pos, &rgnend, &name, &idx) > 0 ){ Sleep(10); //for breakpoint } }