Questions tagged [lnk]

Use this tag for questions about Windows .lnk files representing Shortcuts (or Shell Links). For questions about link errors after compilation (of for example C/C++ code) use the tag [linker-error]

Use this tag if your question is about working with the .lnk (Shell Links) files from a programming perspective.

This can include:

  • the creation of such .lnk files,
  • the required registry keys,
  • its installation by means of a setupprogram,
  • its binary format
  • the relation with IShellLink

Notice that in Unix variants those files are sometimes called .Desktop files.

Wikipedia reference

128 questions
0
votes
1 answer

GStreamer linker error LNK2019 and LNK2001 in Qt C++

I'm having some trouble correctly linking the gstreamer library in qmake. So, I have library I wrote which uses gstreamer, I added this lines to the .pro file: INCLUDEPATH += ../OtherLibs/GStreamer/Include INCLUDEPATH +=…
Pedro Leal
  • 183
  • 1
  • 10
0
votes
1 answer

Get from a started program path to .lnk file that started it

Is there a way in Windows OS to detect whether you program has been started from .bat or .lnk file and obtain the full path to it? I know I can get the parent process, but how to detect... for the lack of a better term let's name it 'way'... the way…
noober
  • 4,819
  • 12
  • 49
  • 85
0
votes
1 answer

Determine if a .lnk points to a metro app

How to determine by .lnk (or its target), whether it points to a metro (Windows 8) application? For instance, the shop link shortcut points to %windir%\WinStore\WinStore.htm. How should I know, that it's not an ordinal page, but a metro style app?
noober
  • 4,819
  • 12
  • 49
  • 85
0
votes
1 answer

Windows Shortcut lnk parser for Java

I am trying to grab the target value in a .lnk file and have tried using the methods specified in an older post here on StackOverflow: Unfortunately the code does not seem to work on some lnk files. The sample of the .lnk I am testing this on is…
Tester
  • 1
0
votes
1 answer

IShellLink GetArguments is only returning executable

I have a wrapper application that needs to identify all the XP Mode applications published; these all reside within a single folder, and I'm using Qt to obtain all the .lnk files. This bit works - the trouble is, all the Virtual PC applications use…
ZXcvbnM
  • 611
  • 7
  • 16
0
votes
3 answers

How To Fix " Error LNK2019 : unresolved external symbol ... "

I tried to make a calculator for midterm and final grades of 5 students. 40% of Midterm and 60% of finals in an array a[5][3]. a[5][3] because 5 students, 3 lines because 1 for midterm another for finals and last one for overall grade(40% of Mid. +…
Dux
  • 13
  • 2
0
votes
2 answers

Open shortcut (.lnk) with parameter lines Java

I'd like to start a shortcut with parameter-lines How could I execute this shortcut with parameters in Java? (As this doesn't work with ProcessBuilder I'm stuck once again...) "C:/Program Files/MyPrograms/MyShortcut.lnk" -s 3 -n 100 (what ever these…
michael
  • 165
  • 1
  • 2
  • 11
0
votes
2 answers

OpenCV246 and Qt LNK1104 cannot open file lib.obj

I have this strange error in Qt: LNK1104: cannot open file 'C:\OpenCV246PC\build\x86\vc10\lib.obj' Settings in Qt are all the same as in VS2010 (where they work fine), but here Qt is complain about the file it can't find even that I see no obvious…
Nenad Bulatović
  • 7,238
  • 14
  • 83
  • 113
0
votes
2 answers

C++ LNK1561 error (when main() is included)

For some reason, even though I have a main() function defined, I am receiving a LNK1561 error. My search.h file: #pragma once #include #include using namespace std; namespace standard{ class Search { public: bool…
RedBeardedOwl
  • 95
  • 1
  • 4
0
votes
2 answers

Passing a shortcut to a batch script

My bat script accepts a filepath as a parameter, which allows me to drag-and-drop a file onto it from Explorer. Unfortunately when I drop a shortcut onto it, I simply get the filepath of the .lnk file itself, rather than the file that it refers to.…
Chris Noe
  • 36,411
  • 22
  • 71
  • 92
0
votes
2 answers

C++ : Why am i getting Linker errors?

Note that i am using Windows Forms Applications with the .NET Here is my code: #pragma once #include #include #include #include #include #include #include #include…
FreelanceCoder
  • 596
  • 2
  • 8
  • 12
0
votes
0 answers

Trying to compile C++ code and getting error LNK1104 cannot open file ifwin.lib

My problem is "Error LNK1104: cannot open file "ifwin.lib" " I've tried going to the properties -> Linker -> Input -> Additional dependencies and adding it that way. I've tried properties -> Linker-> input-> Ignore specific default libraries and…
user2023068
  • 435
  • 1
  • 6
  • 14
0
votes
1 answer

Link-Error LNK2020 & 2001 Visual C++ in VS2012 with PCL-Libraries

I´m trying to use the Open Point Cloud library for aligning point-clouds. I use Visual Studio 2012 and created a new Visual c++ project. The Directory where all the .libs of PCL are stored is added in the properties of the project (Properties ->…
0
votes
2 answers

Custom Vector Types

Are there any restrictions on creating vectors with custom classes? Recently, my compiler has been sending a 'LNK1120' warning whenever I attempt the statement: vector teamList; If this is illegal, is there a workaround that would allow me to…
Michael Hang
  • 199
  • 2
  • 2
  • 15
0
votes
1 answer

Why are my calculations off?

I'm practically done with this program. My only issue is my calculations, I guess. My numbers are completely off. I am too new to post an image, so here is the link to my output. Example:…
1 2 3
8
9