AutoCAD Civil 3D General Discussion

AutoCAD Civil 3D General Discussion

Reply
*Expert Elite*
sboon
Posts: 2,226
Registered: ‎11-08-2005
Message 21 of 34 (157 Views)

Re: very tricky question (at least for me!)

04-09-2014 09:10 PM in reply to: Hidden_Brain
<meta http-equiv="Content-Type" content="text/plain;" />
CAD file is at home and I'm not until tomorrow night. The point name would be a new column in Excel using concatenate to join the panel id with the post id. You would need another import format to bring this back into the drawing 

Sent from my BlackBerry 10 smartphone on the Bell network.
*Expert Elite*
sboon
Posts: 2,226
Registered: ‎11-08-2005
Message 22 of 34 (134 Views)

Re: very tricky question (at least for me!)

04-10-2014 10:24 PM in reply to: sboon

Followup - with pictures, and the files attached. 

 

Clipboard01.png

 

I used your block as a starting point and added cogo points.  #1 is at the center/insertion point of the block.  #2-3 are at the posts and 4-8 are along the edge.  All of the components are joined into a Group, and copied to build rows and columns.  Note - the array command doesn't work in this case; no idea why but the cogo points were erased when I used it.

 

Clipboard02.png

 

Once the array of panel groups was complete I applied the surface elevations to the points and exported them all to csv.  I then used Data Extraction to get the block data out to another csv file.  My blocks don't have any attributes with individual identification, so I created dummy panel names in Excel.

 

Clipboard03.png

 

I also used formulas in Excel to calculate the top of post elevation and to create names for the Panel &  Post cogo points based on matching to the coordinate of the block.

There are several options at this point.  You could add the calculated post height to the point description, erase all of the point in the dwg and re-import only the post points.

 

Steve
Please use the Accept as Solution or Kudo buttons when appropriate

*Expert Elite*
sboon
Posts: 2,226
Registered: ‎11-08-2005
Message 23 of 34 (133 Views)

Re: very tricky question (at least for me!)

04-10-2014 10:28 PM in reply to: sboon

More attachments.

 

Steve
Please use the Accept as Solution or Kudo buttons when appropriate

*Pro
fcernst
Posts: 1,170
Registered: ‎01-07-2011
Message 24 of 34 (118 Views)

Re: very tricky question (at least for me!)

04-11-2014 05:20 AM in reply to: Hidden_Brain

I would use a Corridor. Then you could get the points from the point codes and have the panel raise itself a min 24" above ground if needed automatically, instead of having to check for that clearance manually.

Fred Ernst, PE
C3D 2015 SP2
Ernst Engineering
www.ernstengineering.com
Valued Mentor
Hidden_Brain
Posts: 713
Registered: ‎03-24-2009
Message 25 of 34 (111 Views)

Re: very tricky question (at least for me!)

04-11-2014 08:10 AM in reply to: sboon
this is all great stuff Steve, thanks for posting. the part I am not sure is how did you get the panel numbers? i actually tried it with cogo points inside a block before, but could not make it work for elevations. now that i am thinking, i could probably have gotten it to work essentially doing what i ended up doing.

here's what I ended up doing:
1. created three attributes in the panel block, one at the mid point of the lower side edge (PANEL), two others at the center of each post in plan view (LPOST and RPOST)
2. arrayed the block to lay out the panels
3. exploded the array to regain the blocks
4. increment the attributes for each block so that they are incremented as PANEL1-LPOST1-RPORT1, PANEL2-LPOST2-RPOST2 etc and so on
5 dataextracted to get the N-E and El of all the attributes. from there on, used formulas in Excel to calculate the elevations for LPOST and RPOST locations based on distance from PANEL and elevation of PANEL (as obtained from EG).
Avishek Chhibber, P.E., CFM
Civil 3D 2014 SP2, Win 7-64 bit
8GB RAM
Valued Mentor
Hidden_Brain
Posts: 713
Registered: ‎03-24-2009
Message 26 of 34 (109 Views)

Re: very tricky question (at least for me!)

04-11-2014 08:12 AM in reply to: fcernst
I will be interested in knowing your workflow using a corridor. below is what i need out of all this:
1. N-E and El of the sloped bottom edge of each panel (by panel number)
2. N-E and El for each post (tow post for each panel).
Avishek Chhibber, P.E., CFM
Civil 3D 2014 SP2, Win 7-64 bit
8GB RAM
*Expert Elite*
sboon
Posts: 2,226
Registered: ‎11-08-2005
Message 27 of 34 (107 Views)

Re: very tricky question (at least for me!)

04-11-2014 08:16 AM in reply to: Hidden_Brain

I didn't have your lisp for incrementing the panel numbers in the blocks, so I cheated a bit and created some dummy numbers in Excel.  The only real difference between your method and mine is that you put the cogo points inside a block where I used a group instead. 

 

Steve
Please use the Accept as Solution or Kudo buttons when appropriate

Valued Mentor
Hidden_Brain
Posts: 713
Registered: ‎03-24-2009
Message 28 of 34 (100 Views)

Re: very tricky question (at least for me!)

04-11-2014 08:30 AM in reply to: sboon

here it is below, i cannot take full credit for it, found one online that i manipulated to fit my needs. do't ask why i called it "alltogether" lol.

 

(defun c:alltogether (/ tagname addno ss en an ad ch)

  (setq tagname "PANELNUM")

  (or def_addno (setq def_addno 1))
  (initget 6)
  (setq addno (getint (strcat "\nStarting Panel Number <"
                                 (itoa def_addno)
                              ">:   ")))
  (or addno (setq addno def_addno))

  (and (setq ss (ssget '((0 . "INSERT")(66 . 1))))
       (while (setq en (ssname ss 0))
              (setq an (entnext en)
                    ad (entget an)
                    ch nil)
              (while (and (= "ATTRIB" (cdr (assoc 0 ad)))
                          (not ch))
                     (and (= (strcase tagname)
                             (strcase (cdr (assoc 2 ad))))
                          (setq ch T)
                          (entmod (subst (cons 1 (strcat "PANEL " (itoa addno)))
                                         (assoc 1 ad) ad))
                          (setq addno (1+ addno)))
                     (setq an (entnext an)
                           ad (entget an)))
              (if ch (entupd en)
                     (progn
                       (redraw en 3)
                       (alert "PANELNUM Tag Not Found In This Insert")
                       (redraw en 1)))
              (ssdel en ss)))
  (setq def_addno addno)
  (prin1)

(setq tagname "LPOST")

  (or def_addno (setq def_addno 1))
  (initget 6)
  (setq addno (getint (strcat "\nStarting LPOST Number <"
                                 (itoa def_addno)
                              ">:   ")))
  (or addno (setq addno def_addno))

  (and (setq ss (ssget '((0 . "INSERT")(66 . 1))))
       (while (setq en (ssname ss 0))
              (setq an (entnext en)
                    ad (entget an)
                    ch nil)
              (while (and (= "ATTRIB" (cdr (assoc 0 ad)))
                          (not ch))
                     (and (= (strcase tagname)
                             (strcase (cdr (assoc 2 ad))))
                          (setq ch T)
                          (entmod (subst (cons 1 (strcat "LPOST " (itoa addno)))
                                         (assoc 1 ad) ad))
                          (setq addno (1+ addno)))
                     (setq an (entnext an)
                           ad (entget an)))
              (if ch (entupd en)
                     (progn
                       (redraw en 3)
                       (alert "LPOST Tag Not Found In This Insert")
                       (redraw en 1)))
              (ssdel en ss)))
  (setq def_addno addno)
  (prin1)

(setq tagname "RPOST")

  (or def_addno (setq def_addno 1))
  (initget 6)
  (setq addno (getint (strcat "\nStarting RPOST Number <"
                                 (itoa def_addno)
                              ">:   ")))
  (or addno (setq addno def_addno))

  (and (setq ss (ssget '((0 . "INSERT")(66 . 1))))
       (while (setq en (ssname ss 0))
              (setq an (entnext en)
                    ad (entget an)
                    ch nil)
              (while (and (= "ATTRIB" (cdr (assoc 0 ad)))
                          (not ch))
                     (and (= (strcase tagname)
                             (strcase (cdr (assoc 2 ad))))
                          (setq ch T)
                          (entmod (subst (cons 1 (strcat "RPOST " (itoa addno)))
                                         (assoc 1 ad) ad))
                          (setq addno (1+ addno)))
                     (setq an (entnext an)
                           ad (entget an)))
              (if ch (entupd en)
                     (progn
                       (redraw en 3)
                       (alert "RPOST Tag Not Found In This Insert")
                       (redraw en 1)))
              (ssdel en ss)))
  (setq def_addno addno)
  (prin1))

 

i noticed that after data extraction, the xls file comes out a little strange (see attached). i was trying to dataextract them in the order:

PANELNUM    LPOST  RPOST   ELEV   NORTH    EAST

 

could not make it come out quite that way. ended up having the attribute names in the same line. the PANELNUM attribute lines up with the correct northing-easting, the N-E for LPOST is two rows up, and for RPOST is one row down.   let me know if you are interested in test running it at your end, and i will upload the CAD file.

Avishek Chhibber, P.E., CFM
Civil 3D 2014 SP2, Win 7-64 bit
8GB RAM
*Pro
fcernst
Posts: 1,170
Registered: ‎01-07-2011
Message 29 of 34 (99 Views)

Re: very tricky question (at least for me!)

04-11-2014 08:34 AM in reply to: Hidden_Brain
When looking at that grid, I see a meandering alignment of panels at some frequency along the tangents. The panel ID 's could be the stationing.

Sent from my iPhone
Fred Ernst, PE
C3D 2015 SP2
Ernst Engineering
www.ernstengineering.com
Valued Mentor
Hidden_Brain
Posts: 713
Registered: ‎03-24-2009
Message 30 of 34 (96 Views)

Re: very tricky question (at least for me!)

04-11-2014 08:41 AM in reply to: fcernst
you are correct, at one point, i did look at doing it by alignments. cut alignments along centerline of panels and an offset alongment at the sloped edge, created a EG profile and a EG+24" profile, then created a design profile tracing the top of the posts in profile view, and ran a profile elevation difference report at the end to get:
STA EG FG(posts top)

i found it easier to do it with blocks and attributes.
Avishek Chhibber, P.E., CFM
Civil 3D 2014 SP2, Win 7-64 bit
8GB RAM
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.