Tuesday, July 20, 2004

Tools I've used recently

Wrote my first Fortran Program!
My nephew is taking a course in it and was having trouble.
I found an online Fortran 90 reference and quickly had the program working.
 
I even pulled a Unix command line tool out of my rear-end to kill a couple of processes (ps).
 
When done, he called me a 'Programming God'.
 
Boy, am I now all puffed up.
 
 
Successfully debugged a VB / Windows Scripting Host app.  
 
cscript.exe

How to Debug Classic ASP in VS.NET

Make the following configuration mods:
 
 
In VS.NET:    
 
     project - properties        
            configuration properties            
                    debugging
                         - enable ASP debugging
                         - enable ASP.NET debugging
 
 
 
In the IIS snap-in:    
 
      default website - properties        
             home directory tab            
                  configuration                
                        app debugging                    
                                - enable ASP server-side script debugging    
 
 
Add IIS process account to Debugger Users group:    
 
       In Computer Management snap-in:        
                       System Tools            
                               Local Users and Groups                
                                      Groups                    
                                           Debugger Users - properties                        
                                                  Add user IWAM_machine-name (the "Launch IIS process  account")

Wednesday, July 07, 2004

Making a Web Apps Browser Window Maximized at Start Up

Finally figured out (first time I tried) how to make the browser maximize upon application start:

in html HEAD add this script/function block:

script lang="javascript"
function doOnLoad()
{
window.resizeTo(window.screen.availWidth, window.screen.availHeight);
window.moveTo(0, 0);
}
/script

Then in the BODY tag add this:

onload="javascript:doOnLoad()"

poof! works.

Tuesday, July 06, 2004

Hooking up Client Side Jave Script with MyButton.Attributes.Add()

The Session[MadeChangesIndex] stores a boolean indicating if any changes have been made to the lists/data grids.


In the Page_Load() Handler added:


if((bool)Session[MadeChangesIndex])
Cancel_PB.Attributes.Add("onClick", "return(HandleCancel(true));");
else
Cancel_PB.Attributes.Add("onClick", "return(HandleCancel(false));");


In the HEAD tag of the HTML added:

function HandleCancel(ListChanged)
{

if(ListChanged)
return(confirm("Are you sure you want to Discard ALL of your Edits? This includes any changes to the Work Item, Participant and Client Lists."));
else
return(confirm("Are you sure you want to Discard ALL of your Edits?"));

}

Works Great!

What I'd like to do is figure out how to walk the elements of the form and determine if any of the controls have been modified and exit without confirmation if nothing has changed.

C# Sucks!

JK!! Seriously, though, somewhere around C#-3 we should have inculcated ourselves with the question: "Does 'CAN' == 'SHOULD...