Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't Access Local BCL Using C# Bindings #2211

Closed
pflaumingo opened this issue Apr 29, 2016 · 4 comments
Closed

Can't Access Local BCL Using C# Bindings #2211

pflaumingo opened this issue Apr 29, 2016 · 4 comments

Comments

@pflaumingo
Copy link
Collaborator

Accessing the local BCL doesn't seem to work with 64-bit c# bindings. I'm not very sure of the source of the issue however I tried creating a simple console application in Visual Studio and accessing the local BCL:

var localBCL = LocalBCL.instance();

I then tried calling the prodAuthKey, components and measures methods but none of them return anything. The libraryPath returned the correct path though. I inspected the components.sql file and there is a prodAuthKey set and a series of components and measures. I then tried the same process with the Ruby bindings using Notepad++ and it worked fine - I double checked my C# reference and openstudio path for Ruby were the same bundled release.

This is as far as I've gotten and I'm not sure whether it has something to do with SWIG or something else, but I can't seem to access the local BCL with the C# bindings.

@macumber
Copy link
Contributor

@pflaumingo can you verify if this is still an issue?

@jmarrec
Copy link
Collaborator

jmarrec commented Apr 21, 2020

@pflaumingo Is this still an issue?

@pflaumingo
Copy link
Collaborator Author

No idea, haven't looked at the C# bindings in forever.

@jmarrec
Copy link
Collaborator

jmarrec commented Apr 22, 2020

at 3.0.0-rc3, Built the C# bindings, and taken the csharp example ModelCreateExample, tweak the config so it builds and runs, then added this code:

var localBCL = OpenStudio.LocalBCL.instance();
var prodAuthKey = localBCL.prodAuthKey();
MessageBox.Show("Your LocalBCL prodAuthKey is: " + prodAuthKey);

It does show my prodAuthKey just fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants