|
Darren Webb Summary: This article () shows the layout of the WebSite Requires
Contents
User Help User Help
Pressing the link Location changes the site view from Frames to a Single Page Program Code Introduction
The basis of this css and html WebSite is a page with three frame locations.
JavaScript window.document.referrer (not always reliable) or whether window.self.location equals window.top.location and so forth can help with this determination.
<script language=JavaScript>
// Along with self==top Catching the exception can test the Frames existance
function isFrameSite()
{
var b=0;
var s;
try
{
/*
x = 0x01|0x02|0x04|0x08|0x10|0x20;
00000001 0x01 1
00000010 0x02 2
00000100 0x04 4
00001000 0x08 8
00010000 0x10 16
00100000 0x20 32
01000000 0x40 64
10000000 0x80 128
x &= ~
*/
s = top.fraToolbar.location; b |= 0x01;
s = top.fraWestFrame.fraSearchTab.location; b |= 0x02;
s = top.fraWestFrame.fraDTBar.location; b |= 0x04;
s = top.fraWestFrame.fraDeeptree.location; b |= 0x08;
s = top.fraContentFrame.fraContentBar.location; b |= 0x10;
s = top.fraContentFrame.fraContent.location; b |= 0x20;
}
catch(exception)
{
// alert('Not Using FRAME Version')
s="";
}
return b;
}
</script>
The table below shows the frame names and directory path of the pages:
If you wish to see this Frame layout as JavaScript Windows (target=_top). Detail On The Major Files
JScriptMain.htm
// this page should never load inside of another frame
if (top.location != self.location)
{
top.location = self.location;
}
frameToolbar.htm
<SCRIPT language=JavaScript>
function clickOnLocation(c,t)
{
//alert(top.location);alert(top.fraWestFrame.location);alert(top.fraWestFrame.fraDeeptree.location)
if ( isFrameSite() )
{
if ( !(c==""||c==null||c=="undefined") )
{
top.fraContentFrame.fraContent.location=c;
}
if (t==""||t==null||t=="undefined"){return;}
top.fraWestFrame.fraDeeptree.location=t;
}
else if ( !(c==""||c==null||c=="undefined") ) window.location=c;
}
</SCRIPT>
The above function shows the main navigation for altering the content frame and optionally the tree anchor frame. This frame page does not have a body. Its height is determined by the FRAMESET rows=64,* syntax in JScriptMain.htm There is a problem with this if the user selects the right mouse and Open In New Window frameWest.htm and frameContent.htm These two frame pages are really wrappers for the action pages within the frames.
Directory frameWest Note The Toolbar can be used to update the pages in the West tree and the right content page
Directory frameContent
Directory jscript
Directory footerCOMPANY
Directory images
Directory Location JavaScript Syntax
The following represent the object syntax for the Frames. top.fraToolbar.location top.fraWestFrame.fraSearchTab.location top.fraWestFrame.fraDTBar.location top.fraWestFrame.fraDeeptree.location top.fraContentFrame.fraContentBar.location top.fraContentFrame.fraContent.locationFrom any of the left or west frame pages they can access their own sets by: parent.frames[0].document.bgColor='slateblue' /* frameWest\search.htm */ parent.frames[1].document.bgColor='slateblue' /* frameWest\dtbar.htm */ parent.frames[2].document.bgColor='slateblue' /* frameWest\deeptree.htm */ Cascading Style Sheets (css)
hkey_local_machine/SOFTWARE/Microsoft/Windows/CurrentVersion/run
/SYSTEM/CurrentControlSet/Services/W3SVC/Parameters/Virtual Roots C:\Program Files\Microsoft Visual Studio .NET 2003\SDK\v1.1\GuiDebug>dbgclr.exe http://localhost/quickstart/ASPPlus/ C:\develop\company\Brochure\*.* c:\Program Files\Microsoft Visual Studio .NET 2003\ SDK\ v1.1\ QuickStart\ winforms\ samples\ axhosting\ cs\ document.cs
"The project location is not fully trusted."
Problem: A user is unable to develop programs with Visual Studio .NET, getting the error message "The project location is not fully trusted."
This typically happens when using a network drive or a roaming user environment.
It may also happen when running a compiled .NET program.
Solution: The computer needs to be told that network drives are safe places on which to run .NET code.
Log in as administrator on the affected PC. C:\program files\navnt\activity.log {strings activity.log} The file was authorized.z Script Blocking detected suspicious activity. File: devenv.exe Object: FileSystem Object Activity: GetSpecialFolder The file TAKEON.DOC in compressed file C:\floppy\2\TAKEON.ZIP was infected with the WM.Concept (Damaged) virus. C:\floppy\2\TAKEON.ZIP This script was stopped. Script Blocking detected suspicious activity. File: C:\Program Files\Web Code Expert\codeex.hta Object: Windows Script Host Shell Object Activity: RegWrite The file was authorized. Script Blocking detected suspicious activity. File: C:\Program Files\Microsoft Visual Studio .NET 2003\SDK\v1.1\Samples\Technologies\Interop\Applications\ComServices\ BankAdmin\installSamplebank.Vbs Object: Windows Script Host Shell Object Activity: Run STARTUP ? "C:\Program Files\Microsoft Office\Office\OSA9.EXE" -b -l
%comspec% /k "C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\Tools\vsvars32.bat"
// --- ---------------------------------------------------------------------------------------------------------------- You can use the OleDbConnection, OleDbCommand, and OleDbDataAdapter classes to manage database connections. These classes are part of the System.Data.OleDb namespace, one of the constituents of ADO.NET. Mike, To get detailed events you need to cast the axWebBrowser. Document to an mshtml.HTMLDocument. To do this takes a small bit of work:
private void axWebBrowser1_DocumentComplete(object sender,
AxSHDocVw.DWebBrowserEvents2_DocumentCompleteEvent e)
{
mshtml.HTMLDocument doc = (mshtml.HTMLDocument)axWebBrowser1.Document;
mshtml.HTMLDocumentEvents2_Event iEvent = (mshtml.HTMLDocumentEvents2_Event) doc;
iEvent.onclick += new mshtml.HTMLDocumentEvents2_onclickEventHandler(ClickEventHandler);
}
private bool ClickEventHandler(mshtml.IHTMLEventObj e) // you can get this declaration syntax at the link below
{
MessageBox.Show(e.srcElement.getAttribute("href", 0).ToString()); // displays the full link clicked..."href" being the element of the link we want to know about
return true; // returning true allows the event to be handled by the browser...which means it will try to load the page. If it's false, it does nothing (which means you can handle it personally)
}
This should get you started. If I had more time, I'd post a better sample.msdn.microsoft.com/workshop/browser/mshtml/reference/reference.asp HTH, ShaneB
// Create a simple package containing a class with a single field (President).
package USA {
class Head {
static var President : String = "Bush";
}
};
// Create another simple package containing two classes.
// The class Head has the field PrimeMinister.
// The class Localization has the field Currency.
package UK {
public class Head {
static var PrimeMinister : String = "Blair";
}
public class Localization {
static var Currency : String = "Pound";
}
};
// Use another package for more specific information.
package USA.Florida {
public class Head {
static var Governor : String = "Bush";
}
};
// Declare a local class that shadows the imported classes.
class Head {
static var Governor : String = "Davis";
}
// Import the USA, UK, and USA.Florida packages.
import USA;
import UK;
import USA.Florida;
// Access the package members with fully qualified names.
print(Head.Governor);
print(USA.Head.President);
print(UK.Head.PrimeMinister);
print(USA.Florida.Head.Governor);
// The Localization class is not shadowed locally,
// so it can be accessed with or without a fully qualified name.
print(Localization.Currency);
print(UK.Localization.Currency);
Loading Assemblies
When you specify /autoref- at the jsc.exe compilation command, there is no automatic association between namespaces and assemblies. You need to specify the assembly names explicitly. Use the /reference switch to do this. The syntax is simple:
/reference:file[;file2]
Since only one .exe file can be associated with a single application, your assemblies should be .dll files. In any case, when you compile with /target:winexe or /target:exe, do not pass to the /reference switch any assemblies created with /target:winexe or /target:exe.
When you reference an Assembly A which references another assembly (B), you may need to reference Assembly B as well, if Assembly B inherits from Assembly A, or if Assembly A implements an interface from Assembly B.
In order for the compiler to recognize types in an assembly, it needs to resolve these types first. You need to force the compiler to resolve these types by creating instances of these types, or by inheriting from these types.
Here is an example for using the /reference switch:
jsc /reference:metad1.dll;metad2.dll /out:out.exe input.js | ||||||||||