-
FlexPro
- Zoom sur FlexPro
- Fonctionnalités & Options
- Domaines d’application
- Tous les avantages
- Nouveau dans FlexPro 2021
- Testez FlexPro gratuitement
- FlexPro View OEM Freeware
- Conseils d’achat
- Login
- Langue
- +49 6894 929600
- infoweisang.com
- Google Maps
- Produits
- News
- Support
- Société
- Emplois
- Contact
- Login
- Langue
- +49 6894 929600
- infoweisang.com
- Google Maps
Diagram name
Accueil > Community > Automation and VBA > Diagram name
- This topic has 2 replies, 2 voices, and was last updated 9 years ago by Anonymous.
-
AuthorPosts
-
November 19, 2015 at 11:27 am #12894AnonymousGuest
Hi,
I would like to create a variable into the VBA writter tool which can takes the name of the active diagram seleced.
For exemple, I have 4 curves plots on a diagram. This diagram, instead of the classic “2D Diagram” name, I choose to rename this by “Export00”.
How can I creat a variable which will be the name of this diagram called “Export00”?Thank you in advance,
Zelka.
November 19, 2015 at 11:27 am #8554AnonymousGuestHi,
I would like to create a variable into the VBA writter tool which can takes the name of the active diagram seleced.
For exemple, I have 4 curves plots on a diagram. This diagram, instead of the classic “2D Diagram” name, I choose to rename this by “Export00”.
How can I creat a variable which will be the name of this diagram called “Export00”?Thank you in advance,
Zelka.
November 23, 2015 at 9:06 am #9414Bernhard KantzParticipantTo access the database currently working on, use the global ActiveDatabase property. You may also use ThisDatabase to access the project database containing the VBA code.
The Database object has an ActiveObject property to use the FpObject which has the focus. There are also properties Selection and SelectedObject to get the object(s) chosen in the object list.
The name of an object can be obtained by the property Name, the full path (including extension) with Fullname.Dim oFpObj As FpObject Set oFpObj = ActiveDatabase.ActiveObject Select Case oFpObj.ObjectType Case fpObjectType2DDiagram MsgBox "Selected 2D-Diagram: " & oFpObj.Name & vbCrLf _ & "(Full path name: " & oFpObj.FullName & ")" Case fpObjectType3DDiagram MsgBox "Selected 3D-Diagram: " & oFpObj.Name & vbCrLf _ & "(Full path name: " & oFpObj.FullName & ")" Case Else MsgBox "Selected Object: " & oFpObj.Name & vbCrLf _ & "(Full path name: " & oFpObj.FullName & ")" End Select
-
AuthorPosts
- You must be logged in to reply to this topic.