AVAX-software.com Forums: DXF w/ Layers (HELP) - AVAX-software.com Forums

Jump to content

Page 1 of 1

DXF w/ Layers (HELP) Importing a dxf with layers

#1 User is offline   Rplp4 Icon

  • Member
  • PipPip
  • Group: Members
  • Posts: 19
  • Joined: 21-May 08

Posted 10 August 2008 - 05:09 PM

I am having an issue with importing a dxf file. The drawing is imported and displayed but the layers are not. I am using GetLayers to add the layer names to a combo box. This works on my development computer but does not on any other computer. GetLayers does return a value of 256 but the all the layer names = “”. What am I doing wrong? I have included all the file required stated in the readme.rtf

#2 User is offline   Athanasios Gardos Icon

  • Administrator
  • Icon
  • Group: Admin
  • Posts: 333
  • Joined: 21-March 05
  • Gender:Male

Posted 10 August 2008 - 06:01 PM

Is this happening for all the DXF files or for someone? Can you please send me the DXF file by e-mail?
Athanasios Gardos
Avax-Software.com

#3 User is offline   Rplp4 Icon

  • Member
  • PipPip
  • Group: Members
  • Posts: 19
  • Joined: 21-May 08

Posted 10 August 2008 - 06:35 PM

It happens with all dxf files I have tested with. Some created by me and with other cad packages.
You have mail.

#4 User is offline   Athanasios Gardos Icon

  • Administrator
  • Icon
  • Group: Admin
  • Posts: 333
  • Joined: 21-March 05
  • Gender:Male

Posted 11 August 2008 - 08:15 AM

Can you make a small test project with the following code:

Private Sub Form_Load()
    Dim sLayers() As String, iLayStatus() As Integer
    Dim lMax As Long, lCnt As Long
    Call cAvax1.StartAvax
    Call cAvax1.Add_DXF(App.Path & "\Cpart_1_LeftSide.dxf", "", 0, 0, 0)
    lMax = cAvax1.GetLayers(sLayers(), iLayStatus())
    Combo1.Clear
    For lCnt = 1 To lMax
        Combo1.AddItem Format$(lCnt - 1) & " : " & sLayers(lCnt - 1)
    Next lCnt
End Sub

Private Sub Form_Unload(Cancel As Integer)
    Call cAvax1.EndAvax
End Sub


I don't think that it is an installation problem or a problem of the dxf files.

This post has been edited by Gemalde: 11 August 2008 - 11:31 AM

Athanasios Gardos
Avax-Software.com

#5 User is offline   Rplp4 Icon

  • Member
  • PipPip
  • Group: Members
  • Posts: 19
  • Joined: 21-May 08

Posted 11 August 2008 - 11:11 AM

The code above is how I am trying to add the layers but I have a check to make sure the layer is there as in below example. I will Try your code above and email you the code I am using

For lCnt = 1 To lMax
     If sLayers(lCnt - 1) > "" Then
          Combo1.AddItem Format$(lCnt - 1) & " : " & sLayers(lCnt - 1)
     End If
Next lCnt

This post has been edited by Gemalde: 11 August 2008 - 11:31 AM


#6 User is offline   Rplp4 Icon

  • Member
  • PipPip
  • Group: Members
  • Posts: 19
  • Joined: 21-May 08

Posted 11 August 2008 - 02:50 PM

I ran your above example and the issue is still there. I think the problem is in the installation. I have emailed you explaining what files I am installing. Will you look at it and see what I might be doing wrong?

#7 User is offline   Athanasios Gardos Icon

  • Administrator
  • Icon
  • Group: Admin
  • Posts: 333
  • Joined: 21-March 05
  • Gender:Male

Posted 11 August 2008 - 09:53 PM

You have e-mail. I believe I found the solution.
Athanasios Gardos
Avax-Software.com

#8 User is offline   Rplp4 Icon

  • Member
  • PipPip
  • Group: Members
  • Posts: 19
  • Joined: 21-May 08

Posted 11 August 2008 - 11:18 PM

Yes, once I change the way the files are installed it works.
Thank you for the quick help.

Page 1 of 1


Fast Reply

  

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users