Hi Tariq,
If you return .F. from the forms init the form won't be created.
Also, couldn't you just not run the form from the code that calls it?
If VrLoged
Do Form MySuperSecretForm
else
wait window 'You don't have acces to this form'
Endif
hth
>HI! Fox Lovers!
>
>I have a problem using VFP form. I have created a variable having the user logined on my system. Now I want to check that variable Before running a form that user can run this form or not. Now where to place a code that.
>If not VrLoged
> &&& I don't want to run this form
> && and i want to call form Release event
>Endif
>
>I have placed the code in init & load events but they have to effect execpt checking this condition. Its work if i placed this code in Forms Activate event. But the form flash first before releasing.
>I dont want that the user feels that the form was called and the access to his is denied.
>
>Lookig for a positive response!
>
>
>Thanks
Roi
'MCP' Visual FoxPro
In Rome, there was a poem.
About a dog, who found two bone.
He lick the one, he lick the other.
He went pyscho, he drop dead!