[AccessD] MDE & Otter package installers

Robert Gracie robert at servicexp.com
Fri Jan 20 18:24:56 CST 2006


Rocky,
 You need to first delete the properties, then using an account that has
administrative privileges (Dev mdw.) recreate the properties, setting
the fourth property (DDL) to True.  This way, ONLY users with
Administrative (or dbSecWriteDef) can "set the properties". 

 If you are protecting the front end, then I would image that you are
shipping a an mdw file that has all administrative privileges removed.
You should ALWAYS build a "Dev" mdw to work with your object and ship
the FE with a user mdw.


Robert Gracie
www.gbsysnow.com



-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Rocky Smolin
- Beach Access Software
Sent: Friday, January 20, 2006 7:16 PM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] MDE & Otter package installers

Robert:

So if I change

Set prp = dbs.CreateProperty(strPropName, _
            varPropType, varPropValue)

to 

Set prp = dbs.CreateProperty(strPropName, _
            varPropType, varPropValue, True)

will that prevent users from deleting and changing the property?

However, the link says: " If /DDL/ is *True*, users can't change or
delete this *Property* object unless they have *dbSecWriteDef*
permission."

Do you know what dbSecWriteDef is and how a user gets it?

TIA

Rocky Smolin
Beach Access Software
858-259-4334
www.e-z-mrp.com





Robert Gracie wrote:
> Rocky
>  I'm fairly certain I could open your mde and expose at the very least

> the database container.
>
> >From Help...
>
> Optional. A Variant (Boolean subtype) that indicates whether or not 
> the Property is a DDL object. The default is False. If DDL is True, 
> users can't change or delete this Property object unless they have 
> dbSecWriteDef permission.
>
> Check this out also:
>
> http://www.mvps.org/access/general/gen0040.htm
>
>  
>
>
> Robert Gracie
> www.gbsysnow.com
>
> -----Original Message-----
> From: accessd-bounces at databaseadvisors.com
> [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Rocky 
> Smolin
> - Beach Access Software
> Sent: Friday, January 20, 2006 6:46 PM
> To: Access Developers discussion and problem solving
> Subject: Re: [AccessD] MDE & Otter package installers
>
> What?  What?!  What's the DDL property?  I wonder if I sent you my mde

> you could see if you could crack it?  I thought I was being so
careful.
>
> At worst it would expose the queries, yes?  The back end is an mdb and

> deliberately exposed. I'm just trying to protect the front end.
>
> TIA
>
> Rocky
>
>
> Robert Gracie wrote:
>   
>> Hey Rocky,
>>  Be careful, unless you set the DDL property to True when creating 
>> the
>>     
>
>   
>> property, It's fairly simple to bypass the properties.
>>
>>
>> Robert Gracie
>> www.gbsysnow.com
>>
>>
>> -----Original Message-----
>> From: accessd-bounces at databaseadvisors.com
>> [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Rocky
>>     
> Smolin
>   
>> - Beach Access Software
>> Sent: Friday, January 20, 2006 12:45 PM
>> To: Access Developers discussion and problem solving
>> Subject: Re: [AccessD] MDE & Otter package installers
>>
>> Joe:
>>
>> SOme of the objects, like queries, are still visible unless you do
>>     
> more
>   
>> locking:
>>
>> You can add some locking code like :
>>
>> Sub SetStartupProperties(TheOpeningForm As String)
>>
>> If boolTrapErrors = True Then On Error GoTo Err_SetStartupProperties
>>
>>
>>     ChangeProperty "StartupForm", dbText, TheOpeningForm
>>     ChangeProperty "StartupShowDBWindow", dbBoolean, False
>>     ChangeProperty "StartupShowStatusBar", dbBoolean, False
>>     ChangeProperty "AllowBuiltInToolbars", dbBoolean, False
>>     ChangeProperty "AllowFullMenus", dbBoolean, False
>>     ChangeProperty "AllowBreakIntoCode", dbBoolean, False
>>     ChangeProperty "AllowSpecialKeys", dbBoolean, False
>>     ChangeProperty "AllowBypassKey", dbBoolean, False
>>     ChangeProperty "MenuBar", dbBoolean, False
>>    
>>
>> Exit_SetStartupProperties:
>> Exit Sub
>>
>> Err_SetStartupProperties:
>>
>>     Select Case Err
>>     Case 0      '.insert Errors you wish to ignore here
>>         Resume Next
>>     Case Else   '.All other errors will trap
>>         Beep
>>         DoCmd.OpenForm "frmErrorMessage ", , , , , , "Error: " & 
>> Err.Number & " - " & Err.Description & vbCrLf & "In:
>> ezmrp-opener.SetStartupProperties"
>>         Resume Exit_SetStartupProperties
>>     End Select
>>
>>     Resume 0    '.FOR TROUBLESHOOTING
>>
>> End Sub
>>
>> where the change property function:
>>
>> Function ChangeProperty(strPropName As String, varPropType As 
>> Variant, varPropValue As Variant) As Integer
>>     Dim dbs As Object, prp As Variant
>>     Const conPropNotFoundError = 3270
>>
>>     Set dbs = CurrentDb
>>     On Error GoTo Change_Err
>>     dbs.Properties(strPropName) = varPropValue
>>     ChangeProperty = True
>>
>> Change_Bye:
>>     Exit Function
>>
>> Change_Err:
>>     If Err = conPropNotFoundError Then    ' Property not found.
>>         Set prp = dbs.CreateProperty(strPropName, _
>>             varPropType, varPropValue)
>>         dbs.Properties.Append prp
>>         Resume Next
>>     Else
>>         ' Unknown error.
>>         ChangeProperty = False
>>         Resume Change_Bye
>>     End If
>> End Function
>>
>> Not my code.  I cribbed it from somewhere - the ADH I think.  But you

>> also need unlocking code and a back door to get back into your mde.
>>
>>
>> Rocky
>>
>>
>> Joe Hecht wrote:
>>   
>>     
>>> How locked is my project when I make an MDE or use VSTO or other 
>>> install packages.
>>>
>>>  
>>>
>>> If I make a label for a text box and caption it auto, can they come 
>>> back & change the caption to car as an example?
>>>
>>>  
>>>
>>> Joe Hecht
>>>
>>> jmhecht at earthlink.net
>>>
>>>  
>>>
>>>   
>>>     
>>>       
>>   
>>     
>
>   

--
Rocky Smolin
Beach Access Software
858-259-4334
www.e-z-mrp.com

--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com





More information about the AccessD mailing list