Windows Workflow 4.0 Activities not being added to the toolbox - .net-4.0

I've created a class project in VS 2010 Beta 2. I've added one Activity to it. Saved it. Created another Activity. I would expect the first Activity to appear in the toolbox so I could drag it into my workflow, but it's not. Any ideas?

I had this problem with Visual Studio 2010 RTM as well. I wrote a blog post with a potential solution here.
Essentially, the toolbox doesn't load your custom activities if you have two projects in your solution that share the same folder.

Make sure your Custom Activity class is marked as public.

I experienced this issue too. My workflow service project was part of a solution with other projects. I removed the workflow service project from the main solution and created a new solution only containing the workflow service project. After a build, the custom activities were generated and listed in the toolbox.

I don't know if this is still relevant for you but I had the same problem.
I could solve it like this:
Right click on the Toolbox to open context menu.
Select Choose Items...
Select the tab System.Activities Components
Click on browse and select the dll that contains the custom activity
Make sure that the activity shows in the list and is checked
Click OK

Not really the same question but in Visual Studio 2012, on a 64 bit windows, I had a 64 bit application with CodeActivity and NativeActivity and they were not showing up in the toolbox. I changed the application to AnyCPU and built it, and the activities are now displayed...
I hope it will help someone :)

I resolved this by creating a Windows Workflow 4.0 Console application and then removing out the Program.cs. Very odd, but it worked.

Related

Visual Studio 2022: prevent collapsing folders in solution explorer (2)

This is a follow-up on the problem reported in this question with this same name.
I am having the same issue in Visual Studio 2022 of objects collapsing after a few seconds or when clicking on another object. The answer provided was changing a setting in CodeMaid, but I have not loaded CodeMaid and am having the same issue.
I have tried multiple variations of checking and unchecking Tools/Options/Projects and Solutions/General options "Track Active Item in Solution Explorer" and "Restore Solution Explorer project hierarchy state on solution load" and nothing works. As I code, I will open Controllers to see the list of methods inside or a data model to view the variables for reference while I am working on other aspects of the code. It is very frustrating to have them close after a few seconds, forcing me to reopen them again, over and over, throughout the day. Any help would be appreciated on this matter.
Update: A Microsoft Solution was posted here. They included a fix in Visual Studio version 17.3.5 supposedly. Update your IDE and the issue should hopefully be resolved.
This seems to be a known issue under investigation as reported in the bug tracker for Visual Studio. Using version 17.3.0 Preview 2.0 I too have observed this buggy behavior.
A few other users have mentioned on the same thread they are having the same problem. One user posted steps to reproduce which is similar to what I have tried to reproduce the issue myself:
I expand Blazor project, I expand Pages folder, I lookup and expand a particular .razor file which has a nested .razor.cs file with code, I expand it, see the class node, expand class node, click on a property and usually in this moment, after less than a second or so the branch collapses and the focus in on the razor.cs node.
The ticket says that it "worked-in:Visual Studio 2022 17.0" - perhaps try rolling back to this version if you can. Otherwise, you may have to wait for a fix.
I had the same problem and I think I found the cause and a solution. The problem is the preview tab, which opens automatically on the right side of the tab area when an element is selected in the solution explorer. I unchecked the Preview Tab option under Options->Environment->Tabs and Windows and haven't had any problems since.
greets...

I upgraded a Visual Basic 6 project to Visual Basic 2008 project and got unknown errors

I've recently upgraded my project to Visual Basic 2008 and I'm getting the following errors which I cannot identify, I hope someone can help:
AxThreed.AxSSCommand is not defined
AxActiveInput.AxSSDropDownEdit is not defined
AxPVTEXT3DLib.AxPVText3D is not defined
Any idea what this is and how to fix it?
It looks these are references to 3rd Party ActiveX controls. ActiveThreed, Protoview Date Control, etc
You may need to Add/Re-Add the relevant control to your project. Right click on the toolbox so select the items to want to use. If you don't see them in the list to may need to register/re-register them on that machine
Have a look at this page for more info: http://msdn.microsoft.com/en-us/library/ms973200.aspx
Number 3 here seems to indicate how to fix the problem... I believe some of your controls are not loading.

Adding DLL reference to VB.NET project

Just to start off, this question does seem very similar to another post Add the DLL (lame_enc.dll) reference to my project, but I haven't been able to successfully apply that answer. I am pretty new to VB.NET so it is very possible I'm simply missing something obvious.
I am trying to link a DLL to a VB.NET 2010 project to allow my VB app to play *.ogg files. I followed some other advice here on the forums and downloaded FMOD's FMOD Ex Programmers API. I am trying to now reference that functionality. These appear to be the files I need to somehow reference.
C:\Program Files (x86)\FMOD SoundSystem\FMOD Programmers API Windows\api\fmodex64.dll.
C:\Program Files (x86)\FMOD SoundSystem\FMOD Programmers API Windows\api\libfmodex64_vc.lib.
I haven't discovered how to add a *.lib reference (or the equivalent), but selecting the DLL as a reference gives the following error.
A reference to 'C:\Program Files (x86)\FMOD SoundSystem\FMOD
Programmers API Windows\api\fmodex64.dll' could not be added. Please
make sure that the file is accessible, and that it is a valid assembly
or COM component.
I'm not sure what I could be missing. Any ideas? Thanks!
In Solution Explorer, double-click the My Project node for the project.
In the Project Designer, click the References tab.
Click the Add button to open the Add Reference dialog box.
In the Add Reference dialog box, select the tab indicating the type of component you want to reference.
Select the components you want to reference, then click OK.
Another approach I was trying is working for me. I found a site with a working example of a LibZPlay VB.NET sample ( http://planetsourcecode.com/vb/scripts/ShowCode.asp?txtCodeId=7789&lngWId=10 ). It runs under VS 2008 and I was able to adapt my project to use LibZPlay (open source library http://libzplay.sourceforge.net/WELCOME.html ) under VS 2008.
That is sufficient for me for now. Thanks for your advice. It was likely some configuration issue or misunderstanding on my end.
Using VB.net 2015 I (could not add or even find a System32 dll) as a reference using Solution Explorer, Tab References. Going to the MAIN Menu, Projects/Add References...
Used Browse and All the System32 dll were visible. Then I was able to load the needed dll.

Can't see or add Website Data Sources in RDLC report in ASP.NET MVC

In the RDLC report, in Design view in Visual Studio 2008, we don't see anything in the Website Data Sources tab and the button to Add New Data Source is grayed out. Only the Refresh button is enabled, and clicking it doesn't do anything. Our business logic layer returns Lists of business objects and the business logic and business object projects are both referenced by the MVC project. This is an MVC app, so there is no App_Code folder.
How do we get our business objects to appear in the Website Data Sources list so we can drag and drop fields from the object onto our RDLC report?
I think I suffered the same problem as this.
I solved this by closing all open VS windows, cleaning, rebuilding the solution then adding a new WebForms page (yes I know its MVC) but it then seemed to trigger a refresh in something and the data sources showed up when we reopened and editted the rdlc file.
I have also been frustrated by this, using VB.NET, but this should fix it:
In addition to the reference to:
Microsoft.ReportViewer.Winforms or
Microsoft.ReportViewer.WebForms
You need to also add a reference to:
Microsoft.ReportViewer.Common
The Data Sources panel is still blank, but when you select Add Dataset, you'll see the correct options.
Try this...
https://msdn.microsoft.com/en-us/library/yft2c9ad.aspx
On the menu bar, choose View, Other Windows, Data Sources (or choose the Shift+Alt+D
I had the same problem in Visual Studio 2008. The solution I accidently found was to do the following:
1 - Launch VS 2008
2 - Open Solution
3 - Open report file (rdlc) and make sure "Website Data Sources" pane is showing
4 - Close VS 2008 (with the rdlc "having focus"
5 - Launch VS 2008
6 - Open Solution
You should now see the data in the Website Data Sources pane
One of the problems I had was that my DataSource class didn't have a parameterless constructor...after the parameterless constructor was added "the class" showed up in the DataSource list.
Small detail, but lost some time to figure it out. :)

Different style on buttons in messagebox in different projects

I have a problem with the style of the button in a messagebox.
If I call the following line of code in a current project the button get one type of visual apperance/style. And If I create a new VB.NET Windows Application project it gets a standard Windows apperance/style.
Windows.Forms.MessageBox.Show("Yaay", "Yaay!", Windows.Forms.MessageBoxButtons.OK)
See the difference between the buttons below.
I suspect they inherit the visual apperance from it's parent or maybe from some project settings. But I have not been able to find out from where.
Both projects are created in VB.NET 2.0, and both have same System.Windows.Forms - dll as reference (c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\System.Windows.Forms.dll).
http://www.freeimagehosting.net/uploads/2a956b0675.jpg
Screenshot can be found here.
Thanx in advance for your help!
I cannot see the image from where I am so I'm not sure if this will help you.
Open the Project Properties for each solution and look at the Application tab.
Is the "Enable Applicaton Framework" item ticked? And if so, is the "Enable XP Visual Styles" item also ticked?
That may the difference in the two solutions.