PEHeaders.TryGetDirectoryOffset(DirectoryEntry, Int32) 方法    
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
获取从映像开头到给定目录数据的偏移量(以字节为单位)。
public:
 bool TryGetDirectoryOffset(System::Reflection::PortableExecutable::DirectoryEntry directory, [Runtime::InteropServices::Out] int % offset);public bool TryGetDirectoryOffset (System.Reflection.PortableExecutable.DirectoryEntry directory, out int offset);member this.TryGetDirectoryOffset : System.Reflection.PortableExecutable.DirectoryEntry * int -> boolPublic Function TryGetDirectoryOffset (directory As DirectoryEntry, ByRef offset As Integer) As Boolean参数
- directory
- DirectoryEntry
PE 目录项。
- offset
- Int32
方法返回时,包含从映像开头到给定目录数据的偏移量。
返回
如果找到目录数据,则为 true;否则为 false。