Select the location,
Insert tab ?(ribbon?),
Quick Parts,
field,
Under Field Names, Select Filename ,
Check add path to filename , ( not sure what that would look like for sharepoint stored documents?)
ok.
Here is a longer write up:
http://tortoiseshell.net/coffeebreak/blog/index.php/67/how-to-add-the-filename-and-path-to-a-word-2007-document.html
Thursday, April 23, 2009
Ammo with flavor
For some reason the marketing at this site interest me.
Season Shot - Ammo with flavor.
www.seasonshot.com
tags: hunter funny
Season Shot - Ammo with flavor.
www.seasonshot.com
tags: hunter funny
Wednesday, March 18, 2009
timestamp - dos batch files
below is a link to a nice doc batch timestamp
http://ings.ca/jim/2008/02/10/adding-timestamps-in-a-dos-batch-file/
http://ings.ca/jim/2008/02/10/adding-timestamps-in-a-dos-batch-file/
Monday, March 09, 2009
svn add via batch
problem
files get added to svn, running a svn commit does not add them to the repro, since I am working to automate pulling config files from servers, etc. I want all the new files to go into the repro.
Here are my research notes and answer.
SVN batch commands for adding or deleting multiple files (Linux)
http://blog.gilluminate.com/2008/10/16/svn-batch-commands/
I am using Windows XP, VisualSVN.
took the svn file from http://unxutils.sourceforge.net/.
"c:\Program Files\VisualSVN Server\bin\svn.exe" status | sed -e "/^?/ !d" -e "s/^?//g" > filestoadd.txt
FOR /F "eol=;" %%i in (filestoadd.txt) do "c:\Program Files\VisualSVN Server\bin\svn.exe" add %%i
files get added to svn, running a svn commit does not add them to the repro, since I am working to automate pulling config files from servers, etc. I want all the new files to go into the repro.
Here are my research notes and answer.
SVN batch commands for adding or deleting multiple files (Linux)
http://blog.gilluminate.com/2008/10/16/svn-batch-commands/
I am using Windows XP, VisualSVN.
took the svn file from http://unxutils.sourceforge.net/.
"c:\Program Files\VisualSVN Server\bin\svn.exe" status | sed -e "/^?/ !d" -e "s/^?//g" > filestoadd.txt
FOR /F "eol=;" %%i in (filestoadd.txt) do "c:\Program Files\VisualSVN Server\bin\svn.exe" add %%i
Thursday, February 26, 2009
Powershell Encoding - Grep
I was writing something where powershell ran on the remote host and copied files to a second box. On the second box I would run a perl script and take any any lines containing "Time:" "Finished zone:", had trouble.
Found out that
cmd - "dnscmd /zoneprint zonename.com > zone-zonename.com.txt "
powershell - "dnscmd /zoneprint zonename.com > zone-zonename.com.txt "
give files with different encoding.
I ended up using | Out-file -Encoding utf8 zone-zonename.com.txt
Found out that
cmd - "dnscmd /zoneprint zonename.com > zone-zonename.com.txt "
powershell - "dnscmd /zoneprint zonename.com > zone-zonename.com.txt "
give files with different encoding.
I ended up using | Out-file -Encoding utf8 zone-zonename.com.txt
Vmware ESX 3.5 unable to mount DVD ISO
I was trying to mount a Windows 2008 DVD ISO file that someone else had downloaded, it was giving an error.
Found one some other blog the answer could be one of two things, shorten the name (MS downloads have really long names, or change the .ISO to lowercase .iso.( this is what worked for me.)
Found one some other blog the answer could be one of two things, shorten the name (MS downloads have really long names, or change the .ISO to lowercase .iso.( this is what worked for me.)
Monday, February 02, 2009
custom command prompt
Found a great article.
How to Create a Custom Windows Command Prompt
http://www.wikihow.com/Create-a-Custom-Windows-Command-Prompt
I went searching for this as the path is too long and then the command line is hard to read.
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment]
"PROMPT"="$P$_$G"
How to Create a Custom Windows Command Prompt
http://www.wikihow.com/Create-a-Custom-Windows-Command-Prompt
I went searching for this as the path is too long and then the command line is hard to read.
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment]
"PROMPT"="$P$_$G"
Tuesday, January 27, 2009
error with ms excel and powershell 0x800A03EC
Searched for answer and found other people who had the issue but no answer.
Answer for me was I needed to use qoutes, I guess that way powershell does not send a blog but just the qouted string.
here are more details.
$strextensionattribute1 = $objUser.extensionattribute1
$strextensionattribute12 = $objUser.extensionattribute12
$strextensionattribute13 = $objUser.extensionattribute13
$strextensionattribute14 = $objUser.extensionattribute14
Exception setting "Item": "Exception from HRESULT: 0x800A03EC"
At C:\code\ps-examples\list-proxy-search-samaccountname.ps1:55 char:15
+ $c.Cells.Item <<<< ($strExcelRow,6) = $strextensionattribute1
Exception setting "Item": "Exception from HRESULT: 0x800A03EC"
At C:\code\ps-examples\list-proxy-search-samaccountname.ps1:56 char:15
+ $c.Cells.Item <<<< ($strExcelRow,7) = $strextensionattribute12
Exception setting "Item": "Exception from HRESULT: 0x800A03EC"
At C:\code\ps-examples\list-proxy-search-samaccountname.ps1:57 char:15
+ $c.Cells.Item <<<< ($strExcelRow,8) = $strextensionattribute13
Exception setting "Item": "Exception from HRESULT: 0x800A03EC"
At C:\code\ps-examples\list-proxy-search-samaccountname.ps1:58 char:15
+ $c.Cells.Item <<<< ($strExcelRow,9) = $strextensionattribute14
answer was to use qoutes , I guess that way it gets passed as a string rather then a blob?"
$c.Cells.Item($strExcelRow,6) = "$strextensionattribute1"
$c.Cells.Item($strExcelRow,7) = "$strextensionattribute12"
$c.Cells.Item($strExcelRow,8) = "$strextensionattribute13"
$c.Cells.Item($strExcelRow,9) = "$strextensionattribute14"
Answer for me was I needed to use qoutes, I guess that way powershell does not send a blog but just the qouted string.
here are more details.
$strextensionattribute1 = $objUser.extensionattribute1
$strextensionattribute12 = $objUser.extensionattribute12
$strextensionattribute13 = $objUser.extensionattribute13
$strextensionattribute14 = $objUser.extensionattribute14
Exception setting "Item": "Exception from HRESULT: 0x800A03EC"
At C:\code\ps-examples\list-proxy-search-samaccountname.ps1:55 char:15
+ $c.Cells.Item <<<< ($strExcelRow,6) = $strextensionattribute1
Exception setting "Item": "Exception from HRESULT: 0x800A03EC"
At C:\code\ps-examples\list-proxy-search-samaccountname.ps1:56 char:15
+ $c.Cells.Item <<<< ($strExcelRow,7) = $strextensionattribute12
Exception setting "Item": "Exception from HRESULT: 0x800A03EC"
At C:\code\ps-examples\list-proxy-search-samaccountname.ps1:57 char:15
+ $c.Cells.Item <<<< ($strExcelRow,8) = $strextensionattribute13
Exception setting "Item": "Exception from HRESULT: 0x800A03EC"
At C:\code\ps-examples\list-proxy-search-samaccountname.ps1:58 char:15
+ $c.Cells.Item <<<< ($strExcelRow,9) = $strextensionattribute14
answer was to use qoutes , I guess that way it gets passed as a string rather then a blob?"
$c.Cells.Item($strExcelRow,6) = "$strextensionattribute1"
$c.Cells.Item($strExcelRow,7) = "$strextensionattribute12"
$c.Cells.Item($strExcelRow,8) = "$strextensionattribute13"
$c.Cells.Item($strExcelRow,9) = "$strextensionattribute14"
Friday, January 23, 2009
Microsoft Access 2007 Unknown Errror
I had a database with several tables, all linked to Excel xlsx files.
It was csv converted to xlxs files from the adfind tool, issue was trying to use a like with wildcard when running vbcript, then I found same issue existinged when I tried to query the database from within access. I am not sure if this was a no primary key issue or something else, however I know that once I imported the data and give a primary key the error didn't return.
SELECT [adfind-users].*, [adfind-smg].proxyAddresses
FROM [adfind-users]
WHERE ((([adfind-users].proxyAddresses) Like "*math*"));
It was csv converted to xlxs files from the adfind tool, issue was trying to use a like with wildcard when running vbcript, then I found same issue existinged when I tried to query the database from within access. I am not sure if this was a no primary key issue or something else, however I know that once I imported the data and give a primary key the error didn't return.
SELECT [adfind-users].*, [adfind-smg].proxyAddresses
FROM [adfind-users]
WHERE ((([adfind-users].proxyAddresses) Like "*math*"));
Friday, December 12, 2008
Advanced Registry Tracer
Advanced Registry Tracer
http://www.elcomsoft.com/art.html
Stores registry to database to allow for changes and review.
Seems interesting.
http://www.elcomsoft.com/art.html
Stores registry to database to allow for changes and review.
Seems interesting.
Wednesday, November 19, 2008
pop3 and MS Exchange 2007
Looked here to see how to test via telnet
file:///c:/leddymj/research/exchange2007/testing-pop3-access-using-telnet.html
Got error
"Command is not valid in this state" after supplying credentials.
found answer here:
http://msexchangetips.blogspot.com/2007/11/exchange-2007-pop3-err-command-is-not.html
need to use exchange shell command
Set-PopSettings -LoginType PlainTextLogin
then restart the service.
I used
Get-PopSettings -LoginType PlainTextLogin | fl > before.txt
and
Get-PopSettings -LoginType PlainTextLogin | fl > after.txt
file:///c:/leddymj/research/exchange2007/testing-pop3-access-using-telnet.html
Got error
"Command is not valid in this state" after supplying credentials.
found answer here:
http://msexchangetips.blogspot.com/2007/11/exchange-2007-pop3-err-command-is-not.html
need to use exchange shell command
Set-PopSettings -LoginType PlainTextLogin
then restart the service.
I used
Get-PopSettings -LoginType PlainTextLogin | fl > before.txt
and
Get-PopSettings -LoginType PlainTextLogin | fl > after.txt
when did a Active Directory User Last Logon
first let me say I think Novel Netware user login, I think Windows users Logon.
With several DCs it used to be a bear to get the real last logon, as you would have to check the lastlogon timestamp on each DC, with Windows 2003 Native mode this has been changed.
Details:
lastLogon – old style not replicated to other DCs
lastLogonTimestamp – replicated for each user if the user’s lastlogonTimestamp is older then 14 days ( This is the one to go by for the report. )
http://www.microsoft.com/technet/scriptcenter/topics/win2003/lastlogon.mspx
http://addicted-to-it.blogspot.com/2008/09/ad-how-to-determine-last-logon-time-of.html
I included a hist01.txt which has the command line used to generate the report. The adfind tool is a command line utility, already on corpadmints1.
Also found at http://www.joeware.net/freetools/tools/adfind/.
adfind -b "base dn"
-f filter - all user objects except disabled accounts
-csv csv export
-tdc time date change - changed ldap time date into readable format
then attributes DisplayName samaccountname lastLogon lastLogonTimestamp
With several DCs it used to be a bear to get the real last logon, as you would have to check the lastlogon timestamp on each DC, with Windows 2003 Native mode this has been changed.
Details:
lastLogon – old style not replicated to other DCs
lastLogonTimestamp – replicated for each user if the user’s lastlogonTimestamp is older then 14 days ( This is the one to go by for the report. )
http://www.microsoft.com/technet/scriptcenter/topics/win2003/lastlogon.mspx
http://addicted-to-it.blogspot.com/2008/09/ad-how-to-determine-last-logon-time-of.html
I included a hist01.txt which has the command line used to generate the report. The adfind tool is a command line utility, already on corpadmints1.
Also found at http://www.joeware.net/freetools/tools/adfind/.
adfind -b "base dn"
-f filter - all user objects except disabled accounts
-csv csv export
-tdc time date change - changed ldap time date into readable format
then attributes DisplayName samaccountname lastLogon lastLogonTimestamp
Thursday, November 13, 2008
Godo site with Lots of AD info and vbscript examples
good site they have vbscript examples and more
http://www.computerperformance.co.uk/vbscript/
they have great pages on using ldifde and csvde
http://www.computerperformance.co.uk/vbscript/
they have great pages on using ldifde and csvde
Sunday, September 21, 2008
hid security app
ossec is a host based intrusion detection. The sever only runs on unix, there is a windows agent.
Free helpdesk apps
rt and otis. Otis looks great, what can I say it seems like all you would want. A customer interface, ldap , email built in.
http://otrs.org/index/
http://otrs.org/index/
Thursday, August 14, 2008
Multi-Value attributes and Exchange 2007
Some notes, I am putting up . After search I some one guy delete with a lines and another one say you had to loop through everything.
To set a multi-value attribute with the Exchange Management Shell
Set-ContentFilterConfig -BypassedSenderDomains "faker1.com","faker2.com"
Get-ContentFilterConfig
You will see both "faker1.com" and "faker2.com" listed.
*************************************************
to remove one item at a time:
$foo = Get-ContentFilterConfig
$foo.BypassedSenderDomains -="faker2.com"
$foo | Set-ContentFilterConfig
*********************************************************
To clear the entries:
Set-ContentFilterConfig -BypassedSenderDomains $Null
Get-ContentFilterConfig
**************************************************
You can also add an value
$foo = Get-ContentFilterConfig
$foo.BypassedSenderDomains +="faker4.com"
$foo | Set-ContentFilterConfig
To set a multi-value attribute with the Exchange Management Shell
Set-ContentFilterConfig -BypassedSenderDomains "faker1.com","faker2.com"
Get-ContentFilterConfig
You will see both "faker1.com" and "faker2.com" listed.
*************************************************
to remove one item at a time:
$foo = Get-ContentFilterConfig
$foo.BypassedSenderDomains -="faker2.com"
$foo | Set-ContentFilterConfig
*********************************************************
To clear the entries:
Set-ContentFilterConfig -BypassedSenderDomains $Null
Get-ContentFilterConfig
**************************************************
You can also add an value
$foo = Get-ContentFilterConfig
$foo.BypassedSenderDomains +="faker4.com"
$foo | Set-ContentFilterConfig
Wednesday, August 13, 2008
Active Directory Last Logon
Good info and scripts on Last Logon time, seems like the Windows 2003 DC replicate some info if the logon date is less then 14 days old.
http://www.rlmueller.net/Last%20Logon.htm
http://www.rlmueller.net/Last%20Logon.htm
Tuesday, August 05, 2008
Perl Encode Decode strings
So I a file SetACL dump that I was trying to parse with Perl, found that the file encoding was UCS2-Little Endian. I was reading the file into perl and wanted to standardize the formatted output I would generate.
$line = decode('UCS-2LE',$oldline);
#answers found here
#http://perldoc.perl.org/Encode.html
#and
#http://coderepos.org/share/browser/lang/perl/Encode/trunk/t/Unicode.t
#also saw possible answers here
#perl -MEncode -le "print for Encode->encodings(':all')"
$line = decode('UCS-2LE',$oldline);
#answers found here
#http://perldoc.perl.org/Encode.html
#and
#http://coderepos.org/share/browser/lang/perl/Encode/trunk/t/Unicode.t
#also saw possible answers here
#perl -MEncode -le "print for Encode->encodings(':all')"
Thursday, July 31, 2008
cacls and subinacl
I am trying to work with cacls and got this error:
The data area passed to a system call is too small.
I saw a post that said to use subinacl instead. The syntax is different.
Also working on getting the SetACL command to work, so far I have it dumping the info.
The data area passed to a system call is too small.
I saw a post that said to use subinacl instead. The syntax is different.
Also working on getting the SetACL command to work, so far I have it dumping the info.
Subscribe to:
Comments (Atom)