Author Topic: creating formatted notes in VB skript  (Read 3024 times)

ilario

  • EA Novice
  • *
  • Posts: 1
  • Karma: +0/-0
    • View Profile
creating formatted notes in VB skript
« on: October 21, 2008, 10:29:45 pm »
I coded a piece of software, which happily produces classes and attributes at a fingertip.

The problems started, when I wanted to add formatted notes to the attributes.

My documentation is enriched with html tags and EA 7.1 renders them correctly - as long as I manually update t_attribute.StyleEx with volatile=0;

Unfortunately setting StyleEx within my VB-Skript produces errors.
Code: [Select]
Set newAttribute = newILBClass.Attributes.AddNew(name,EnumCodeElementType.ctAttribute)
newAttribute.styleex = "volatile=0;" ' <<<== this throws an error
newAttribute.Update
...
newAttribute.Notes = documentation
newAttribute.Update

Can anybody help me?

greetings

Ilario
« Last Edit: October 21, 2008, 10:31:52 pm by ilario »

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: creating formatted notes in VB skript
« Reply #1 on: October 21, 2008, 10:44:05 pm »
I think this is worth an immediate bug report. At the very least, the documentation for StyleEx still (as of build 831) says "...Not currently used." Something is wrong somewhere.

Surprising that this does not get reported more.
No, you can't have it!

ramhog69

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: creating formatted notes in VB skript
« Reply #2 on: October 22, 2008, 02:16:29 am »
Is it because of capitalization of styleex, should be StyleEx?

Kalvin

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: creating formatted notes in VB skript
« Reply #3 on: October 22, 2008, 09:08:44 am »
No.
No, you can't have it!

Dermot

  • EA Administrator
  • EA User
  • *****
  • Posts: 591
  • Karma: +7/-0
    • View Profile
Re: creating formatted notes in VB skript
« Reply #4 on: October 22, 2008, 04:46:44 pm »
I am not sure if I read the original post correctly - when reffering to formating in the notes is that EA rich text formating?  If so, try using the EA-SDK routines:
GetFieldFromFormat (string Format, string Text)
GetFormatFromField (string Format, string Text)
See the help for details.