Bool getFramesource (CString & Refstring, long frameIndex = 0)
FrameIndex is the serial number of the frame set
0 Represents the main frame, return FALSE if FrameIndex is greater than the total frame number
BOOL CHtmlView :: GetFrameSource (CString & refString, long frameIndex) {BOOL bRetVal = FALSE; if (frameIndex == 0) {bRetVal = GetSource (refString);} else if (frameIndex> 0) {frameIndex = frameIndex - 1; CComQIPtr < Idispatch> pdisp = gethtmlDocument ();
IF (pdisp! = null) {ccomqiptr
IF (phtmldoc! = null) {ccomqiptr
IF (pframes! = null) {long framecount = 0; pframes-> get_length; & framecount;
IF (framecount> frameindex) {Colevariant Varindex (FrameIntex, VT_i4); Colevariant Varpdisp; Pframes-> Item (VarIndex, Varpdisp); ccomqiptr
IF (pdispdoc! = null) {ccomqiptr
IF (phtmlwnd! = null) {ccomqiptr
IF (phtmldocf! = null) {hglobal hmemory; hmemory = GlobalAlloc (GMEM_MOVEABLE, 0);
IF (hmemory! = null) {ccomqiptr
if (spPSI = NULL!) {CComPtr
Return Bretval;}