http://www.techzone360.com/topics/techzone/articles/2014/12/08/394794-single-use-tablets-thinking-differently-under-100-tablets.htm#
http://www.zdnet.com/article/understanding-the-dichotomy-between-single-use-and-multifunctional-tablets/
Posts from a Lotus Notes Client and Domino programmer from Sydney.
Tuesday, 1 November 2016
Sunday, 17 July 2016
Microsoft Word Macro to paste images Sub PasteImageCertainHeight()
Sub PasteImageCertainHeightOrText()
'
' PasteImageCertainHeight Macro
intDesiredWidth = 250
intDesiredHeight = 380
Selection.Paste
Selection.MoveLeft Unit:=wdCharacter, Count:=1, Extend:=wdExtend
ScaleValue = 1 ' default no change.
'atk 17/7/2016 created from web
' I like to add this code to be called on ctrl shift v
If Selection.InlineShapes.Count <> 0 Then
' if there is an inline shape, we are pasting picture
If Selection.InlineShapes(1).Height > intDesiredHeight Then
ScaleValue = intDesiredHeight / Selection.InlineShapes(1).Height
intNewHeight = Selection.InlineShapes(1).Height * ScaleValue
intNewWidth = Selection.InlineShapes(1).Width * ScaleValue
End If ' check height
'confirm we are not too wide either
If intNewWidth > intDesiredWidth Then
ScaleValue = intDesiredWidth / intNewWidth
intNewHeight = Selection.InlineShapes(1).Height * ScaleValue
intNewWidth = Selection.InlineShapes(1).Width * ScaleValue
End If ' check width
'Modify the values by the ScaleValue
Selection.InlineShapes(1).Height = Selection.InlineShapes(1).Height * ScaleValue
Selection.InlineShapes(1).Width = Selection.InlineShapes(1).Width * ScaleValue
Else
' pasting text,
Selection.PasteSpecial DataType:=wdPasteText
End If ' ' count of shapes to determine if pasting picture or tex
End Sub ' PasteImageCertainHeight
Sub PasteSpecial()
' I assign this to shortcut key ctrl-alt-v
Selection.PasteSpecial DataType:=wdPasteText
End Sub
'
' PasteImageCertainHeight Macro
intDesiredWidth = 250
intDesiredHeight = 380
Selection.Paste
Selection.MoveLeft Unit:=wdCharacter, Count:=1, Extend:=wdExtend
ScaleValue = 1 ' default no change.
'atk 17/7/2016 created from web
' I like to add this code to be called on ctrl shift v
If Selection.InlineShapes.Count <> 0 Then
' if there is an inline shape, we are pasting picture
If Selection.InlineShapes(1).Height > intDesiredHeight Then
ScaleValue = intDesiredHeight / Selection.InlineShapes(1).Height
intNewHeight = Selection.InlineShapes(1).Height * ScaleValue
intNewWidth = Selection.InlineShapes(1).Width * ScaleValue
End If ' check height
'confirm we are not too wide either
If intNewWidth > intDesiredWidth Then
ScaleValue = intDesiredWidth / intNewWidth
intNewHeight = Selection.InlineShapes(1).Height * ScaleValue
intNewWidth = Selection.InlineShapes(1).Width * ScaleValue
End If ' check width
'Modify the values by the ScaleValue
Selection.InlineShapes(1).Height = Selection.InlineShapes(1).Height * ScaleValue
Selection.InlineShapes(1).Width = Selection.InlineShapes(1).Width * ScaleValue
Else
' pasting text,
Selection.PasteSpecial DataType:=wdPasteText
End If ' ' count of shapes to determine if pasting picture or tex
End Sub ' PasteImageCertainHeight
Sub PasteSpecial()
' I assign this to shortcut key ctrl-alt-v
Selection.PasteSpecial DataType:=wdPasteText
End Sub
Tuesday, 21 June 2016
Greasemonkey/Tampermonkey to remove certain rows from a html table
// ==UserScript==
// @name ModifyUFCPageOnlyUltimateClasses
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match http://www.ufcgymsydney.com/home/programming/class_schedule.aspx
// @grant none
// @require http://code.jquery.com/jquery-latest.js
// ==/UserScript==
//===================================================================================
function ShowOrHideOthers(strShowOrHide) {
var tableOfClasses = document.getElementById('ctl00_phBody_gvClasses');
if (strShowOrHide == "hide") {
strDisplay="none";
} else {
strDisplay= "block";
alert("will show em");
}
var intPosOfClassType=3;
// loop through all rows in the class table - start at row 2
for(var i=2; i
// FIX THIS
try {
var strClassType=(tableOfClasses.rows[i].cells[intPosOfClassType].innerHTML);
if (strClassType!="Ultimate") {
//alert(strClassType);
tableOfClasses.rows[i].style.display = strDisplay;
} // alert for ultimate classes
}
catch(err) {
// this is if we can't read the innerHTML of rows with only 1 cell... ignore it. alert(err.message);
}
} // for each row
}
// end function show or hide others
//===================================================================================
if (confirm("Would you like to only show ultimate classes (tampermonkey script by atk)") === true) {
ShowOrHideOthers("hide");
}
// @name ModifyUFCPageOnlyUltimateClasses
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match http://www.ufcgymsydney.com/home/programming/class_schedule.aspx
// @grant none
// @require http://code.jquery.com/jquery-latest.js
// ==/UserScript==
//===================================================================================
function ShowOrHideOthers(strShowOrHide) {
var tableOfClasses = document.getElementById('ctl00_phBody_gvClasses');
if (strShowOrHide == "hide") {
strDisplay="none";
} else {
strDisplay= "block";
alert("will show em");
}
var intPosOfClassType=3;
// loop through all rows in the class table - start at row 2
for(var i=2; i
// FIX THIS
try {
var strClassType=(tableOfClasses.rows[i].cells[intPosOfClassType].innerHTML);
if (strClassType!="Ultimate") {
//alert(strClassType);
tableOfClasses.rows[i].style.display = strDisplay;
} // alert for ultimate classes
}
catch(err) {
// this is if we can't read the innerHTML of rows with only 1 cell... ignore it. alert(err.message);
}
} // for each row
}
// end function show or hide others
//===================================================================================
if (confirm("Would you like to only show ultimate classes (tampermonkey script by atk)") === true) {
ShowOrHideOthers("hide");
}
Subscribe to:
Posts (Atom)