cancel
Showing results for 
Search instead for 
Did you mean: 

pb12.5 Classic - .net assembly issue

Former Member
0 Kudos

hello,

i'm trying to create a .net assembly using pb12.5.2 classic.  the compile is fine, however, when i try to consume the dll in either pb12.5.NET or VS2010, any reference to the dataobjects does not work.  my understanding is that the dataobjects are contained within the pbd files, which do exist, however it appears that the dll is not able to reference the pbd files.

creating the same .net assembly in pb11.2 does work for me...and i can see that when the dll is referenced in VS that the pbd files are also included.

any help would be appreciated

thanks

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Dylan;

  FWIW:  This works OK for me using PB 12.1. So I wonder if its a 12.5.2 issue?

Regards ... Chris

Former Member
0 Kudos

hi Chris...thanks for the response

we are currently setting up a pb12.0 environment.  i will try creating a .net assembly using pb12.0 classic and let you know what happens.

thanks...dylan

Former Member
0 Kudos

hi Chris,

we set up 2 virtual environments, one with pb12.1 and another with pb12.5.2, and both environments have the same issue as i'm experiencing on my local computer.

basically, my process is as follows:

  • in pb11.2 i created a .net assembly target with a simple routine to retrieve via a datastore
  • created a project object, choose the method i wish to expose, then deploy the project which creates a dll and pbd file in the output folder.
  • then in VS, i add the dll as a reference.  i verify that the dll and pbd file are copied to the app's bin folder
  • using the assembly within VS works fine

then...

  • i migrate the target to pb12.5 Classic
  • compile the assembly as before and verify the dll and pbd exist in the output folder.
  • however, in my VS app when i add the dll as a reference, i only see the dll file copied to the bin folder
  • the assembly does not work for any routine requiring a dataobject

if you, or anyone has any idea's as to what i am missing..or steps i can try....i would appreciate it.

thanks

Former Member
0 Kudos

Hi Dylan;

1) PB 11.x would have created a .Net 2.0 based Assembly

2) PB 12.x will create a .Net 3.5 based Assembly

3) PB 12.5.x PB 12.x will create a .Net 4.0 based Assembly

Now, you need to make sure that your development PC has the correct .Net run-times installed plus the version of VS you are using is compatible with the .Net version of the assembly you are trying to consume.

Regards ... Chris

Former Member
0 Kudos

Hi Dylan,

You need to add the PBD files generated in your VS project and set the option "Always copy to output folder".

Also you have to check that your VS project targets the .NET 4 platform, not the ".NET 4 Client Profile".

And maybe you are missing some Sybase assemblies, have a look at theses thread :

I could use a PB classic assembly using a dataobject, in Pb12.5.1, but it was a very simple case.

HTH

Guillaume