Process description in VS 2010 - visual-studio-2010

I am writing a service in VB2010. Everything is working well, but when you look at the process in task manager, the description is: WindowsService1. I can't find where to change it. When I look at the project properties, the root namespace is WindowsService1, but if I change that it gives me an error: The string for the root namespace must be a valid identifier. I have looked at all the properties and can't find where to put a more descriptive description. It is not a show stopper, but I would like to be complete.
Any ideas?

What you want is to rename your assembly name and its display name when the process is installed.
You can rename your assembly name from property pages of the application, as in the pic below:
Secondly, when you write the installer for windows service, you can change the display name & description of the Windows Service, please refer the link below:
http://msdn.microsoft.com/en-us/library/system.serviceprocess.serviceinstaller.description(v=vs.110).aspx

Related

settingcontent-ms file tag meaning

Windows 8 has a feature: it can launch an application from the search panel (on the right side of the screen). It works like following:
Developer registers his or her application following this instruction. It is a bit legacy instruction, but the project I participate in uses this way to register its settings.
At user logon Windows creates (if none exists) a special .xml file in C:\User\<UserName>\AppData\Packages\windows.immersivecontrolpanel_cw5n1h2txyewy\LocalState\Indexed\Settings\en-US with content shown below. This file has extension settingscontent-ms
As soon as user clicked on this file, the system launches the specified application (actually explorer calls for it, as I discovered by ProcMon).
Xml file content:
<?xml version="1.0" encoding="UTF-8"?>
<PCSettings>
<SearchableContent xmlns="http://schemas.microsoft.com/Search/2013/SettingContent">
<ApplicationInformation>
<AppID>windows.immersivecontrolpanel_cw5n1h2txyewy!microsoft.windows.immersivecontrolpanel</AppID>
<DeepLink>%Canonical name or application path%</DeepLink>
<Icon>%App path%,-%Resource number%</Icon>
</ApplicationInformation>
<SettingIdentity>
<PageID>%GUID as in instruction above%</PageID>
<HostID>{7E0522FC-1AC4-41CA-AFD0-3610417A9C41}</HostID>
<Condition>shcond://v1#RegkeyExists;0;Regkey;HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel\NameSpace\%GUID as in instruction above%</Condition>
</SettingIdentity>
<SettingInformation>
<Name>#%App path%,-%Resource number%</Name>
<Description>#%App path%,-%Resource number%</Description>
<HighKeywords>%App decription%</HighKeywords>
</SettingInformation>
</SearchableContent>
</PCSettings>
We can see node with the name HostID. Windows writes specified in code GUID to this node, but it breaks the ability of my application to work. If I try to execute my app through this "shortcut" by clicking on xml file or chosing my app in search panel, the system shows me a message: "Unspecified error".
When I manually change the HostID value to {12B1697E-D3A0-4DBC-B568-CCF64A3F934D}, it starts to wrk fine.
I looked through registry in order to find something about these two GUIDs, but I didn't find anything. Also I looked for the difference between registry values corresponding to my app and to another, but working, app and didn't find any significand differences too.
Also I tried to delete this file and login into the system under ProcMon, I caught some moments: explorer tries to open the file and fails with ERROR_FILE_NOT_FOUND, explorer creates missing file, reads registry and writes something to created file, then it closes the file. But I didn't find anything interesting in between of these messages, that can help me to solve my problem.
I found out that registry key HKEY_CLASSES_ROOT\CLSID\%App GUID%\System.ApplicationName contains exactly the same with DeepLink tag (it was the first error in my app - specified key was empty), but the proble with "wrong" HostID remains.
Does anyone know, what it is and how to make Windows to write the rigth GUID to this tag, or at least some useful info about this tag? I just can't imagine anything else to change, but I think, that I need to change something in corresponding to my app registry keys.
I found the solution: just put app's GUID (the same as in PageID) into DeepLink.
To do this, you need to write this GUID as string value to HKEY_CLASSES_ROOT\CLSID\%App GUID%\System.ApplicationName.
That's the solution. However, I haven't found the meaning of HostID tag :(

Private extension galleries error "A connection to the server could not be established [...]"

Added a private VS extension gallery as described in
https://msdn.microsoft.com/en-us/library/hh266746.aspx
using an atom feed as described in
https://msdn.microsoft.com/en-us/library/hh266717.aspx
And got this error message:
"A connection to the server could not be established because the following error(s) occurred:
Could not determine the protocol used for this gallery. The URL must point to an Atom Feed or SharePoint List configured for hosting Visual Studio Extensions.
Please click here to retry the request."
This guy had the same problem but didn't bother to post his solution (and apparently you can't reply once it's "solved"), so here it goes:
Open up the atom.xml file with Notepad++ then check "Encode in UTF-8" under "Encoding".
In the two places where there's an id after the name of the extension and 2 dots replace that id with the one from your project's Guids class. It's the first GUID in there. Alternatively you could open up the vsix file with WinRar / 7Zip and open up the extension.vsixmanifest file there (the GUID is found on top of this file).
Edit: the 2nd id tag should just include the ID and not the name of the project and the two dots - otherwise updating the extension won't work
Remove all those hyphens - in the atom.xml file in the case that you copied that from the example in https://msdn.microsoft.com/en-us/library/hh266717.aspx
The first GUID on top of the atom.xml file (the one after uuid) can be any GUID you'd like to have (create one under Visual Studio's Tools->Create GUID).

Method or data member not found compile issue

I have a VB6 project that I didn't create but I have to update, when I go to make the exe I get a compile error: Method or data member not found, and it points too "SCom1.FileReceive" in the code below. When I look at the Main form, the SCom1 control is a PictureBox.
This code has been working for the last 5 years but I don't know why SCom1 is a picturebox, or why I'm getting the error, is it a reference? SCom1 to me looks like a MSComm function? Let me know if anyone has any ideas, I just don't know VB enough to know how to troubleshoot this. Thanks
If SCom1.FileReceive = True Then
WriteToLog (Now() & " FileReceive was true, now false")
SCom1.FileReceive = False
End If
The machine which you have opened the code doesn't have the mscomm32.ocx file or the ocx file not registered properly.
When vb cannot reference an ocx, it'll convert the relevant control to a picture box control.
What you have to do is, close the project without saving. Then open system32 folder and check for mscomm32.ocx file. If the file is not there then you have to download that from the intenet. The register the file using regsvr32 command in command prompt.
After this you can open the vb6 project and start working.
=========================================================
EDIT : Included the update in the comments to the answer, this will help other users in the future... :-)
if the method name doesn't look familiar to a known ocx file (in this case the SCom1.FileReceive), the missing component can be a custom ocx file.
So check on the working machine or in project folder whether there are any ocx file exists in the relevant name (in this case SCom.ocx).
if there is a file exists in such name, register that file using regsvr32 (if not registered), then add that to toolbox, then replace the picture box control with the relevant control (make sure the name tally).

Reporting Services Action Go To Report issue finding report in different folder

I'm using Visual Studio 2010 to write SSRS reports on my PC (Win 7 32-bit, if relevant?) for deployment to a standalone SSRS (non-Sharepoint).
I have written a report in "Report Project1" folder and when the user clicks on a textbox I would like to open a report that exists in a different folder (let's call it "Live").
In the Text Box Properties dialog box I have selected Action and clicked the Go to report button. I'm not to sure what to put under Specify a report?
If I put /Live/report2 then I get error "Could not find a part of the path 'H:\Visual Studio 2010\Projects\Report Project1\Report Project1\bin\Debug\Live\report2.rdl'."
If I put ../Live/report2 (Live and Report Project1 are at same level) then I get the same error.
If I put http://< servername >/ReportServer/Live/report2 then I get the error "The given path's format is not supported."
Can anybody put me right?
Try /Reports/Live/report2
If you specify a full path on a report server running in native mode, you must give it the path from the Home folder.
Here's a helpful link: http://msdn.microsoft.com/en-us/library/dd220423.aspx
Otherwise, you can achieve the same goal by using the go to url action. Just provide it the url to the subreport and send your parameters as part of the url.

How to get the updated argument(s) of a build process template refreshed in 'Process' section of a build definition?

For a build process template, we can add/remove/edit the argument list of it and use it as variables within the build/work-flow steps. I reading the nice guide here
I'm cloning the template DefaultTemplate.11.1.xaml to sayHello-DefaultTemplate.11.1.xaml and edit it via Visual Studio 2012. I first added one argument, called TestMessage. I check in my changeset to the Source Control.
Then I create a build definition sayHelloBuild based on this template. And when I go to the Process tab, I can see TestMessage in the Misc section. I save the build definition. Trying to queue it and it gets succeeded.
Here comes the issue. I added another argument for the template named ABBCCC and checkin the source code. But when I edit the build definition sayHelloBuild, I cannot see ABBCCC in the Process tab as MyArugment01 does.
How can I get the argument list refreshed?
Within the arugments there is a property called "Metadata" as shown in the picture below. Click on the button at the right end and a window should pop up as shown in the second picture. Enter the name of the new variable in the Parameter Name and enter the other details (Display name etc). Save and check-in the build definition and you should be good to go.
Use the below script to delete the registed build process template in Database:
use Tfs_YourTeamCollectionName;
delete from tbl_BuildProcessTemplate where ProcessTemplateID = 'Your ProcessTemplateID';
Create new build definition again.
The database name is your TFS team collection name e.g. Tfs_YourTeamCollection in the backend SQL Server of your TFS server. I'm using TFS 2012.
Hope it helps!

Resources