Normal Topic Prevent certain Users from adding new records (Read 3476 times)
Hammer
YaBB Administrator
Lanticans
*****
Offline


Fire bad. Tree pretty.

Posts: 3436
Location: Ohio
Joined: Nov 22nd, 2002
Prevent certain Users from adding new records
Mar 30th, 2004 at 2:40pm
Print Post Print Post  
Code
Select All
// Prevent users who cannot add records
// from advancing to new blank record.

var vGroup as String

If @IsNew
{
	vGroup = @Group
	If ((vGroup = "Lowlifes") Or (vGroup = "PondScum"))
	{
		@MsgBox("You are not permitted to add new records.", "", "")
		If @Add
		{
				// Kick them out
			@Exit
		}
		Else If @Update
		{
				// Retreat to the last existing record
			ResultSetCurrentPosition(@ResultSetTotal() - 1)
		}
	}
} 

  

- Hammer
The plural of anecdote is not data.
Back to top
IP Logged
 
Steve_in_Texas
Senior Member
*****
Offline


No personal text

Posts: 893
Location: San Antonio
Joined: Feb 21st, 2004
Re: Prevent certain Users from adding new records
Reply #1 - Mar 30th, 2004 at 8:23pm
Print Post Print Post  
Cool.

Thanks,
Steve
Smiley
  
Back to top
IP Logged