Till current moment I knew only one recipy to create form VC++ designer:
1. Add dialog resource and design what you want in designer.
2. Create MFC form by using designed dialog resources
But now I got project sample that has form and has no *.rs files with form information. Instead of that it has header file that has form icon. Header file contains many code that creates controls and sets style. It is also possible select from menu "View Designer". That makes me think that there is another way of creating form. Besides that looks that codes does't uses MFC.
How to create simple form application with designer that would generate header file (not resource) and not use MFC?
Unfortunately I can't "View Designer" because during this procedure error is generated:
C++ CodeDOM parser error: Line: 1520, Column: 42 --- Unknown type 'AxKgLib.AxKg'. Please make sure that the assembly that contains this type is referenced. If this type is a part of your development project, make sure that the project has been successfully built.
Correct me if I'm wrong. Looks like I need registered ActiveX for this project. I have registered ocx that was included in source, but this didn't helped.
How to solve this problem? How to get list of all ocx that system has to make sure there is no required AxKgLib.AxKg? How to make designer to show me form without required control?
Related
Trying to view source code related to a method that is being used in a Razor code block. However, when I right-click on method to view the definition, it takes me to the page where the source code is, but it doesn't actually show the code in the associated procedure. It only shows the procedure name. And, in that page's tab, it has a little pad lock next to it with the words "from metadata". How can I view the source code
I found that the padlock version was referring to the compiled dll file. For some reason the original removed all the code behind files to a different location and the application was only able to refer to the dll as a library reference. Had to rebuild all the references and that fixed the problem.
In the components section I selected a IMAGE VIEWER ACTIVEX CONTROL, which is a third party component. I tried to use it in my application, however, whenever I click on the object in the TOOLBOX window and drag it to my form, I get this message...
**License information for this component not found. You do not have an appropriate license to use this functionality in the design environment.**
Now the thing is, i actually do have a license for this component. Its in the folder with all my forms and modules, its titled imageviewer.lic
It seems as though the license is there, it does not get applied to the image viewer control. Not sure how to go about resolving this. Any ideas?
I would like to be able to include a screenshot of a control inside my code, this way making control identification easier for new members on my team, is such a thing possible?
Maybe even the ability to just have the image on a network share with the path in a comment, and then have a plugin that when hovering over the link brings up the image?
EDIT (More detail):
I'm creating a test project, the application under test has over 1000 controls, some of them are similar in name and purpose, this can make it difficult at times for developers to reuse the API I am creating because the control name is simply not enough for quick identification of the control in use.
I use the word API very loosely too, none of this stuff will be consumed in web services, and it will always be white box with developers including a project reference and have direct access to the source code.
For every form in my application (The test one), I have a controls.cs file where all the controls for that form in the application under test are listed - This is where I want the hover to screenshot ability in the control definitions.
Another sure factor is that all developers will be using VS2013 (For now the base version), later this could be update 1 or 2.
As the initial author and senior developer on this project, these hover / image references (in the code) will be as useful to me personally as any 3rd party developers, or any later developers to join the initiative.
Thanks again, and I added a bounty!
I believe you can use Whole Tomato's free SourceLinks Visual Studio extension to do what you want - or at least get pretty close to it.
Built-in Functionality:
Out of the box, the extension allows you to specify comment patterns you want users to be able to take an action on. Once the patterns are specified, SourceLinks will highlight any occurrences of those patterns in the text editor. You will be able to double click the highlighted items and perform a pre-configured action (such as opening a link in an internal/external browser, or launching an executable).
You can see an example in the SourceLinks configuration dialog shown below:
(source: wholetomato.com)
So you could use this feature pretty painlessly to define a keyword such as Control Image and then put comments like the following in your code:
// Control Image: my_smart_list.jpg
SourceLinks would allow you double click this text, and you could have that configured to launch the image (using a file:// or http:// url depending on how and where your images are stored) either inside Visual Studio in it's internal browser, or in an external browser.
Custom Tooltips!
Now, if you want to put in some more effort into this and actually write some code, then SourceLinks allows you to create API Extensions to display custom tooltips when the user hovers over the marked text in the editor. The default installation of SourceLinks comes with sample API extensions that you can copy to create your own. See the article linked at the very top of the answer for more details on these samples.
This post in the SourceLinks forum informs us that SourceLinks expects the custom API Extension to return the tooltip value as FlowDocument XAML text. This is awesome news for us, because a FlowDocument can contain many types of elements, including formatted text, hyperlinks, and images.
Imanges in a Flow document can be specified both inline as well as externally.
Hope this helps!
I would use doxygen -- create the images somewhere in the source tree and use doxygen comments. You can embed the \image command in source comments (see docs) and doxygen will generate all the HTML documentation from there. I think doxygen is a great tool for documenting a codebase as you can generate the documentation directly from comments in the source and distribute or host the HTML separately.
I am currently try to write a code generator and I would like the user to select the target type for a property on a class via a drop down, but to populate the drop down I need to know what types are available to the project.
How do I access via a VS extension the properties that have been loaded by the current project?
Check out my answer here:
How to access project code meta data?
You should be able to get the types from the code snippet I provided.
I have create a DocumentLibrary list using the SharePoint UI and export it using the SharePoint Solution Generator 2008 (VSeWSS 1.3) to a Visual Studio .NET project.
Then I have made a webpart to show items from the document library using the ListViewByQuery with som input parameters. I have put the ListViewByQuery into a Ajax UpdatePanel. The list item menu rase an error 'ctx' is undefined. ctx is defined in the schema.xml file.
Any ideas?
Work-around;
Had the same problem with a document library - to work-around I dragged the standard control part onto the page and made it non-visible (the doclibrary plugin )
Make sure that in this hidden control's view the "Name (linked to document with edit menu)" field is in the view.
That field will cause the creation of a ctx to support the edit drop-down.