use swift file into Objective-C project -
can tell me how can use swift file objective-c project?
i have swift file inherits uiviewcontroller instead of nsobject. trying use swift file not able figure out how.
when add swift file objective-c project, asks create bridging header. in header file importing swift file -
#import "slidecontroller.swift"
and bridging file name objctoswift-bridging-header.h
i read many answers asks import file
#import "myproductmodulename-swift.h"
into .m file, can't find such file in project.
i changed defines module = yes
shown in answer.
but still not able access swift file. missing? please tell me right steps figure out.
after created bridging header.
go build setting =>search "objective-c bridging header"
just below find ""objective-c generated interface header name" file
and import file in view controller.
ex.in case: "dauble-swift.h"
Comments
Post a Comment