GGS-DDU  
 
 
[program development]Apostrophe
[ 2007-12-5 18:58:00 | By: LT ]
 
Have you ever tried to send a string variable to MS Access that had apostrophes embedded within an SQL Statement? If YES you will get a run time ERROR. Here is your solution, a function that formats the variable before sending it to the database.


Code: ( text )
Public Function Apostrophe(sFieldString As String) As String
If InStr(sFieldString, "'") Then
Dim iLen As Integer
Dim ii As Integer
Dim apostr As Integer
iLen = Len(sFieldString)
ii = 1

Do While ii <= iLen
If Mid(sFieldString, ii, 1) = "'" Then
apostr = ii
sField
……
 
 
 
[program development]Access Denied While Signing Assembly
[ 2007-12-3 21:48:00 | By: LT ]
 
Access Denied While Signing Assembly
Description as following,
Cryptographic failure while signing assembly '....' Access is denied.

Solution:
To remedy the problem I simply opened an Explorer window as an administrator and altered the ACLs on the necessary directory. I granted my user Full Control on %ALLUSERSPROFILE%\Application Data\Microsoft\Crypto\RSA\MachineKeys. Simply restart Visual Studio (if it was open) and you should be off and rolling.
 
 
 
[program development]Asp.net MachineKey
[ 2007-11-8 17:58:00 | By: LT ]
 
ASP.NET 1.1
In ASP.NET 1.1, the element appears in the Machine.config file as shown here:

validationKey="xxxx"
decryptionKey="xxxx"
validation="SHA1|MD5|3DES" />

The attributes are as follows:

validationKey. This specifies the key that the HMAC algorithm uses to make ViewState tamper proof. The validationKey is used when either of the following attributes are set to true:

……
 
 
 
[program development]Asp.net MachineKey
[ 2007-11-8 17:58:00 | By: LT ]
 
ASP.NET 1.1 {machineKey}
In ASP.NET 1.1, the {machineKey} element appears in the Machine.config file as shown here:

{machineKey
validationKey="xxxx"
decryptionKey="xxxx"
validation="SHA1|MD5|3DES" /}

The {machineKey} attributes are as follows:

validationKey. This specifies the key that the HMAC algorithm uses to make ViewState tamper proof. The validationKey is used when either of the following attributes are set to true:
{pages enableViewStateMAC="true"}
{@Page EnableViewStateMac="true"}

decryptionKey. This specifies the key used to encrypt and decryp
……
 
 
 
[program development]Asp.net MachineKey
[ 2007-11-8 17:58:00 | By: LT ]
 
When you want to encrypt ViewState, you must make sure the Validation be set to "AES" or "3DES", and the decryption is set to the corresponding value.
 
 
 
[program development]SOA architecture skeleton diagram
[ 2007-7-5 12:29:00 | By: LT ]
 
 
 
 
[miscellanea]My Resume
[ 2007-7-3 16:13:00 | By: LT ]
 

73795747.zip(点击浏览该文件)
 
 
 
[program development]OOD
[ 2007-7-2 11:25:00 | By: LT ]
 
OOD Method
72206330.zip(点击浏览该文件)
 
 
 
[program development]Web Service and .Net Remoting
[ 2007-7-2 11:04:00 | By: LT ]
 
Web Service
-- asmx
.Net Remoting
-- WS_Tcp_Binary
-- WS_Tcp_Soap
-- WS_Http_Binary
-- WS_Http_Soap
-- IIS_Http_Binary
-- IIS_Http_Soap
 
 
 
[program development]A sample that showing how to do xml validation in .net2.0
[ 2007-7-2 11:02:00 | By: LT ]
 

72261358.zip(点击浏览该文件)
 
 
首页 上一页 下一页 尾页 页次:1/13页  10篇日志/页 转到:
 
Have a remebrance of time.

Time remembrance

Lastest comments

Lastest logs

Lastest leave word

Search

User Login

Link