1
Answer

Get the name of shortcut

A J

A J

14y
1.9k
1
I have a scenario where I have 2 shortcuts for the same exe (3rd party exe). Say S1 and S2. When they are running I have 2 processes in task manager say app.exe and app.exe

I can get the PID, handle of the process but what I want to get is the name of the shortcut that is attached to the launch of the process. Is it possible to get the name of shortcut which launched the process somehow?

Note, this is a 3rd party app so I have no control over it. Had it been my app, I could have coded it to accept some argument etc etc and tracked it.
Answers (1)
1
Jignesh Trivedi

Jignesh Trivedi

NA 61k 14.2m 10y
hi,

Agree with Anupam Singh, you forgot the close braces before @res variable.
1
Ranjit Powar

Ranjit Powar

NA 8.1k 496.5k 10y
Closing bracket is missing correct it.

Create Proc SP_Login(@Mode Varchar(50),@Name Varchar(50),@PassWord Varchar(50),@Res INTEGER Output)
1
Anupam Singh

Anupam Singh

NA 5.8k 886.9k 10y
Hi selva,,

Try this :
Create Proc SP_Login(@Mode Varchar(50),@Name Varchar(50),@PassWord Varchar(50),@Res INTEGER Output)
as 
if exists(Select Mode,UserName,[PassWord] From Tbl_Login Where Mode=@Mode and UserName=@Name and [PassWord]=@PassWord)
set @Res=1
else 
set @Res=0
go

I have highlighted where you were wrong.