Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Is there an alternative to argv[0]?

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
Hi, im trying to get the filename of my executable but seeing as im using WinMain I cant mange to get argv to work. Is there anything out there that i can get the filename of my executable from?

Also lpCmdLine doesnt work because my program is being spawned by the registry, lpCmdLine only contains the info after my filename.

any solutions?
 
I think you can get it from theApp.m_pszAppName. Not sure if this is what you are looking for tho

Matt
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top