Click here to Skip to main content
15,925,661 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Help regarding search in SQL database Pin
Dave Kreskowiak1-Sep-09 1:23
mveDave Kreskowiak1-Sep-09 1:23 
AnswerRe: Help regarding search in SQL database Pin
Mycroft Holmes31-Aug-09 14:11
professionalMycroft Holmes31-Aug-09 14:11 
GeneralRe: Help regarding search in SQL database Pin
jeshra2795-Sep-09 3:50
jeshra2795-Sep-09 3:50 
GeneralRe: Help regarding search in SQL database Pin
Mycroft Holmes5-Sep-09 12:52
professionalMycroft Holmes5-Sep-09 12:52 
QuestionHow to send command to remote server.... Pin
Suresh Suthar31-Aug-09 1:51
professionalSuresh Suthar31-Aug-09 1:51 
AnswerRe: How to send command to remote server.... Pin
Dave Kreskowiak31-Aug-09 4:19
mveDave Kreskowiak31-Aug-09 4:19 
AnswerRe: How to send command to remote server.... Pin
LloydA11131-Aug-09 15:20
LloydA11131-Aug-09 15:20 
QuestionIsUserAdmin (Vista non-elevated) Pin
AB_dev30-Aug-09 23:55
AB_dev30-Aug-09 23:55 
Hi,

I need to get the information if the current user is in role Administrators!
I start the program non elevatet (because else the uac prompt always show) then I check if an update is available,
if an update is available then I restart the application elevated because i need to install a update!

My issue is how to check if the current user is in role Administrators when the program is started non-elevated??

This is my code to check if user is admin, this only works if program is started elevated! (Windows Vista)

  Public Function IsUserAdmin() As Boolean<br />
    Dim UserPrincipal As WindowsPrincipal<br />
<br />
    UserPrincipal = New WindowsPrincipal(WindowsIdentity.GetCurrent())<br />
    If UserPrincipal.IsInRole(WindowsBuiltInRole.Administrator) Then<br />
      Return True<br />
    Else<br />
      Return False<br />
    End If<br />
  End Function


Does anyone knows how to solve this??
AnswerRe: IsUserAdmin (Vista non-elevated) Pin
Luc Pattyn31-Aug-09 1:02
sitebuilderLuc Pattyn31-Aug-09 1:02 
GeneralRe: IsUserAdmin (Vista non-elevated) Pin
AB_dev31-Aug-09 2:09
AB_dev31-Aug-09 2:09 
GeneralRe: IsUserAdmin (Vista non-elevated) Pin
Luc Pattyn31-Aug-09 2:39
sitebuilderLuc Pattyn31-Aug-09 2:39 
AnswerRe: IsUserAdmin (Vista non-elevated) Pin
AB_dev31-Aug-09 4:09
AB_dev31-Aug-09 4:09 
GeneralQuery For Getting Last Child Note - Sourabh Das Pin
Dot Net Jantu30-Aug-09 22:54
Dot Net Jantu30-Aug-09 22:54 
GeneralRe: Query For Getting Last Child Note - Sourabh Das Pin
Mycroft Holmes30-Aug-09 23:12
professionalMycroft Holmes30-Aug-09 23:12 
QuestionAbout Crystal Report Viewer using Dataset Pin
drexler_kk30-Aug-09 21:31
drexler_kk30-Aug-09 21:31 
AnswerRe: About Crystal Report Viewer using Dataset Pin
Mycroft Holmes30-Aug-09 22:53
professionalMycroft Holmes30-Aug-09 22:53 
QuestionRe: About Crystal Report Viewer using Dataset Pin
drexler_kk30-Aug-09 23:25
drexler_kk30-Aug-09 23:25 
AnswerCrystal Report using Dataset Pin
David Mujica31-Aug-09 3:20
David Mujica31-Aug-09 3:20 
AnswerRe: About Crystal Report Viewer using Dataset Pin
εїзεїзεїз31-Aug-09 6:30
εїзεїзεїз31-Aug-09 6:30 
QuestionEditable DataGridViewComboBoxColumn Pin
C#Coudou30-Aug-09 19:37
C#Coudou30-Aug-09 19:37 
AnswerRe: Editable DataGridViewComboBoxColumn Pin
εїзεїзεїз30-Aug-09 21:18
εїзεїзεїз30-Aug-09 21:18 
GeneralRe: Editable DataGridViewComboBoxColumn Pin
C#Coudou30-Aug-09 21:48
C#Coudou30-Aug-09 21:48 
AnswerRe: Editable DataGridViewComboBoxColumn Pin
εїзεїзεїз30-Aug-09 21:20
εїзεїзεїз30-Aug-09 21:20 
GeneralRe: Editable DataGridViewComboBoxColumn Pin
C#Coudou30-Aug-09 21:53
C#Coudou30-Aug-09 21:53 
GeneralRe: Editable DataGridViewComboBoxColumn Pin
εїзεїзεїз30-Aug-09 22:02
εїзεїзεїз30-Aug-09 22:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.