fbpx
Welcome, Guest
Username: Password: Remember me
Please use this forum for suggestions to the XSharp Development Team
  • Page:
  • 1

TOPIC: Trying to run the default Vulcan sample

Trying to run the default Vulcan sample 2 years 8 months ago #331

  George's Avatar Topic Author George Offline Posts: 91
Hi,

today, I downloded the XSharp Public Beta 7 and I created a new VS2015 Project via 'Vulcan Application'.
The compilation was successful but trying to run the compiled App, the attached error appeared.

Alternatively, I changed the Start() function's code with this one:

FUNCTION Start() AS VOID
VulcanLoader.InitVulcan() // required for VO/Vulcan database support

LOCAL a := {} as ARRAY
AADD(a, "One")
AADD(a, "Two")

LOCAL n AS INT
FOR n:=1 upto ALen(a)
Console.WriteLine((string)a[n])
NEXT

Console.WriteLine("Press any key to continue...")
Console.ReadKey()

this code runs without problems.

1. I expected a compiler warning for mixing INT and DWORD (ALen function) in the statement:
FOR n:=1 upto ALen(a)
but finally, not.
Please note I didn't add any compiler switch.


2. Is-there a problem with the statement:
Console.WriteLine("Hello World today is " + (STRING) Eval(cbMacro))
?

regards
George
Attachments:

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #332

  robert's Avatar robert Away Posts: 994
George,

1) We suppress the errors that you are mixing INT and DWORD for this particular example. This happens a lot in user code

2) The Vulcan template was added "Last minute". There is a problem in the example. Change the codeblock from

cMacro := "{||Today()}"

to


cMacro := "{||DToC(Today())}"

and it should work

Robert
XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #333

  George's Avatar Topic Author George Offline Posts: 91
Thanks Robert

George

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #334

  George's Avatar Topic Author George Offline Posts: 91
Robert,

I guess the X# WinForm is not compatible with the Vulcan WinForm code.

The question is:

Is-there an easy way to import a Vulcan project to XSharp or to change the .vnproj file to .xsproj ?

thanks and regards
George

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #335

  robert's Avatar robert Away Posts: 994
George
I have a cery crude tool that does this. Give me a day or two to tidy that and i will upload iT.

Ok?

Robert
XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #338

  George's Avatar Topic Author George Offline Posts: 91
Thank you Robert

George

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #349

  George's Avatar Topic Author George Offline Posts: 91
Hi Robert,

first of all thank you for the quick response: the XPorter is already in the public download area.

I downloaded the XPorter and I tried it in 2 situations:

1. I created a new Vulcan WindowsForms sample then converted it to X#.
The new .xsproj opened without problem and the .sln file saved with a new filename.
Then I quit VS2015 and open it again using the new .sln file.
Tying to compile I got the error explained into the attached:
Compiling xsproj.PNG

2. I run the XPorter for a small sized Vulcan solution, but including 3rd party libraries like DevExpress and a Vulcan DLL created by me (all my programs share this DLL).
Trying to open the .xsproj, I got the error explained into the attached:
Opening xsptoj.PNG

The 2nd case solution file is also attached here.

Now another (3rd !) question:
After installing the X# 0.2.7, I realized that every time I try to press <Enter> at the end of a program's code line into the VS2015 Editor, the attached error appears:
Edit a Vulcan prg.PNG
Please note this side-effect appears only in Vulcan solutions (I tried 3 of my solutions).
Never on empty line nor at the start of any code line.

I already did:
C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE>devenv /setup
without any chance.

thanks and regards
George

File Attachment:

File Name: CustomersC...proj.TXT
File Size:17 KB
Attachments:

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #350

  robert's Avatar robert Away Posts: 994
George,

1) This seems to be a problem in your Assemblyinfo.prg. Can you show me that code ?
2) I can reproduce the problem. I will see if I can find the cause of it. That may be a challenge, since I do not have most of the external DLLs that are references in the project file.
3) I assume this is Vulcan 4? Are you also using the VulcanProductivity extension?
Is this a solution with only Vulcan projects or are there also X# projects in the solution?
And if Vulcan and X# are both in the solution, do these projects share the same source files ?

Robert
XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #352

  robert's Avatar robert Away Posts: 994
George,

I found the cause of the problem for #2: there is a bug in the Ms MPF code that sets dependencies between items and its children.

When a child item (a resx in this case) is located in subfolder (for example Edit Forms in your project) then it looks for the parent item in the main folder of the project and cannot find the parent.
The MPF code does not display a nice error message but simply throws an exception.

I have changed this for the next build:
- It looks in the right folder
- When it fails to find the parent it no longer produces an exception but shows an error message describing the problem.

This fix will be included in the next build.
For now you should be able to work around this by:
- either removing the RESX files from the XSProj file
- Moving all forms and their resx files into the root of the (Vulcan) project and then reconvert the project

Robert
XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #354

  George's Avatar Topic Author George Offline Posts: 91
Robert,

Case 2:

>For now you should be able to work around this by:
- either removing the RESX files from the XSProj file
- Moving all forms and their resx files into the root of the (Vulcan) project and then reconvert the project

I confirm that the Project is correctly opened now after moving all the Forms (and other source code files) to the root.
Compiling the converted project (X# now), the following error appears:

C:\Users\George\Documents\Visual Studio 2015\Projects\XSharp\Project CustomersContractsLicenses\_GlobalVariables.prg(5,27): error XS0434: The namespace 'Softway' in 'Softway.Common, Version=1.5.1.1, Culture=neutral, PublicKeyToken=null' conflicts with the type 'Softway' in 'Softway.Common, Version=1.5.1.1, Culture=neutral, PublicKeyToken=null'

I suppose you already explained why:
> I can reproduce the problem. I will see if I can find the cause of it. That may be a challenge, since I do not have most of the external DLLs that are references in the project file.


Case 1:

>1) This seems to be a problem in your Assemblyinfo.prg. Can you show me that code ?

////////////////////////////////////////////////////////////////////////////////
// AssemblyInfo.prg

#using System.Reflection
#using System.Runtime.InteropServices

//
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
//
[assembly: AssemblyTitleAttribute( "WindowsFormsApplication1" )]
[assembly: AssemblyDescriptionAttribute( "" )]
[assembly: AssemblyConfigurationAttribute( "" )]
[assembly: AssemblyCompanyAttribute( "" )]
[assembly: AssemblyProductAttribute( "WindowsFormsApplication1" )]
[assembly: AssemblyCopyrightAttribute( "Copyright © 2016" )]
[assembly: AssemblyTrademarkAttribute( "" )]
[assembly: AssemblyCultureAttribute( "" )]

// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisibleAttribute( false )]

// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: GuidAttribute( "6335bf01-7915-4301-a27d-f98870e60f4b" )]

// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Revision and Build Numbers
// by using the '*' as shown below:
[assembly: AssemblyVersionAttribute( "1.0.*" )]
[assembly: AssemblyFileVersionAttribute( "1.0.*" )]


Case 3:

>3) I assume this is Vulcan 4? Are you also using the VulcanProductivity extension?

Yes, it is the last Vulcan 4.
No, I dont't use the VulcanProductivity extension. I remove-it almost since the installation of Vulcan 4 and VS2015 because I had (and still have) many problems (the VS2015 get stuck frequently and restarts) even after the unistallation of VulcanProductivity extension.

>Is this a solution with only Vulcan projects or are there also X# projects in the solution?

Yes. It contains a single Vulcan Project.

>And if Vulcan and X# are both in the solution, do these projects share the same source files ?

I load either the Vulcan or the X# Project. They are 2 different solutions sharing the same source.

thank you for your immediate action.

George

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #355

  George's Avatar Topic Author George Offline Posts: 91
Robert,

Case 2 again:

trying to open any Form into my X# Project, I get the attahed error.
Even in the (very simple) AboutDialog Form.

George
Attachments:

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #357

  robert's Avatar robert Away Posts: 994
George,

Can you mail me the solution and the dlls it depends on.

Robert at xsharp dot eu
XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #358

  robert's Avatar robert Away Posts: 994
George,

I will look into the other issues tomorrow.
XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #359

  George's Avatar Topic Author George Offline Posts: 91
Robert,

I will, tomorrow morning.
As we have 1 hour of difference, you will find it at coffee time.

George

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #360

  robert's Avatar robert Away Posts: 994
George,

Problem 1) is caused by the wildcard in the AssemblyFileVersion attribute.
For now I suggest you comment out that line. The X# compiler does not allow wildcards in the AssemblyFileVersion (the C# compiler does not like these as well). If you omit the AssemblyFileVersion, then the compiler will generate one based on the AssemblyVersion

Robert
XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

Last edit: by robert.

Trying to run the default Vulcan sample 2 years 8 months ago #362

  George's Avatar Topic Author George Offline Posts: 91
Robert,

thank you for answer.

I am ready to send you (to your eMail address) the sample to reproduce the problem.
I will send you one Vulcan project containing the referenced .DLL as well as the Vulcan/X# project for the CCL program.

I just made a 'light' version of the .DLL project.

Wich is largest attachment size I may sent you ?
Please note the .DLL project is about 20MB.

regards

George

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #363

  robert's Avatar robert Away Posts: 994
George,

20Mb may be a little bit too much. Why not upload it to OneDrive and send me a link ?

Robert
XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #364

  George's Avatar Topic Author George Offline Posts: 91
Robert,

I just sent you the .DLL Vulcan Project (without the DevExpress RunTime DLLs).

George

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #365

  robert's Avatar robert Away Posts: 994
George,

The problems with the Forms appears to be that the Forms do not have a BEGIN NAMESPACE ... END NAMESPACE
If you surround the form class with
BEGIN NAMESPACE CustomersContractsLicenses
// your original form code
END NAMESPACE

then it will open in the Form Designer without problems.

I have made fix to the Code Parser so it will not require this in the future.

Robert
XSharp Development Team
The Netherlands
This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

Trying to run the default Vulcan sample 2 years 8 months ago #366

  George's Avatar Topic Author George Offline Posts: 91
Robert,

>I have made fix to the Code Parser so it will not require this in the future.

Great!

George

Please Log in or Create an account to join the conversation.

  • Page:
  • 1