Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - qwerty

Pages: 1 ... 529 530 [531] 532 533 ... 653
7951
You'd better be served on StackOverflow with that kind of question. I guess there is some lib for base64 decode as well as unzip.

q.

P.S.: http://techslides.com/extract-zip-and-rar-files-with-html5

7952
Back to business :)

The record actually contains the time stamp:
Quote
User="Adam" DateTime="2015-01-19 10:13:51"
Just decode Bincontent1 using base64 (you can do that with Notepad++) and unzip the result. Inside is a str.dat file which contains the information in XML format.

q.

7953
Good grief :( My brain doesn't seem to be what it used to be. Actually there is no time stamp inside. I'd have made an oath that there is :-[

Now, there's always a way around. Once you found the modification entry for a connector just find the previous and next one for a normal element which have not been changed successively and inspect their modification date. A rather awkward deviation.  ::)

Can you tell us the intention for finding the modification date of connectors?

q.

7954
The API only supports Clear and Save for the audit. So SQLQuery is the way to go here.

q.

7955
Automation Interface, Add-Ins and Tools / Re: Update is not a function
« on: March 30, 2015, 11:51:10 pm »
Well, two statements from experienced EA users against one from a rookie. That sounds like a good base for discussions.

q.

7956
Automation Interface, Add-Ins and Tools / Re: Update is not a function
« on: March 30, 2015, 11:04:10 pm »
You can not update the collection. You can call update only on newly generated elements/connectors/... Maybe you mean refresh(), but that's superfluous in most cases.

q.

7957
@Tehila1: As you can see there are a couple of smart guys here too ;-) I had something like that in mind but it was buried under a pile of other stuff.

q.

7958
Automation Interface, Add-Ins and Tools / Re: Users logged in to EA
« on: March 23, 2015, 06:11:26 pm »
Maybe you can write a trigger in the database? I'm not a DBA. So just a guess.

q.

7959
GUIDs have a fixed length so you can use the simple substring. The approach is a compromise. If you want to list all items you need to create an add-in search that uses the API (like Aaron's approach) to return the items as search result.

q

7960
From my Inside book (once provided by Helmut Ortmann):


Code: [Select]
SELECT DISTINCT o.ea_guid as CLASSGUID, o.Object_Type as CLASSTYPE,
  o.name As Item, o.Object_Type As ItemType,
  o.stereotype As 'ItemStereotype', "Connector" As ConnectorType,
  c.Name, c.Stereotype
 
FROM t_object o, t_xref xCon, t_xref xFlow, t_connector c, t_connector flow

WHERE
  c.connector_ID = <Search Term> AND c.ea_guid = xCon.Client AND
  flow.ea_guid = xFlow.client AND xCon.Behavior = 'abstraction' AND
  flow.ea_guid IN (
#DB=SQLSVR#s
  substring(x.description,0,39),
  substring(xCon.description,39,39),
  substring(xCon.description,78,39),
  substring(xCon.description,117,39),
  substring(xCon.description,156,39),
  substring(xCon.description,195,39),
  substring(xCon.description,234,39),
  substring(xCon.description,273,39),
  substring(xCon.description,312,39),  
  substring(xCon.description,351,39)
#DB=SQLSVR#    
#DB=Other#
  left(xCon.description,38),
  mid(xCon.description,40,38),
  mid(xCon.description,79,38),
  mid(xCon.description,118,38),
  mid(xCon.description,157,38),
  mid(xCon.description,196,38),
  mid(xCon.description,235,38),
  mid(xCon.description,274,38),
  mid(xCon.description,313,38),  
  mid(xCon.description,352,38)
#DB=Other#  
) AND o.ea_guid IN (
#DB=SQLSVR#s
  substring(x.description,0,39),
  substring(xCon.description,39,39),
  substring(xCon.description,78,39),
  substring(xCon.description,117,39),
  substring(xCon.description,156,39),
  substring(xCon.description,195,39),
  substring(xCon.description,234,39),
  substring(xCon.description,273,39),
  substring(xCon.description,312,39),  
  substring(xCon.description,351,39)
#DB=SQLSVR#    
#DB=Other#
  left(xCon.description,38),
  mid(xCon.description,40,38),
  mid(xCon.description,79,38),
  mid(xCon.description,118,38),
  mid(xCon.description,157,38),
  mid(xCon.description,196,38),
  mid(xCon.description,235,38),
  mid(xCon.description,274,38),
  mid(xCon.description,313,38),  
  mid(xCon.description,352,38)
#DB=Other#  
)

UNION
SELECT DISTINCT o.ea_guid , o.Object_Type ,
  o.name,  o.Object_Type, o.stereotype, "Information Flow",
  c.Name, c.Stereotype
 
FROM t_object o, t_xref x, t_connector c

WHERE
  x.client = c.ea_guid AND
  x.Behavior = 'conveyed' .and
  c.connector_ID = <Search Term> .and
  o.ea_guid IN (
#DB=SQLSVR#s
  substring(x.description,0,39),
  substring(xCon.description,39,39),
  substring(xCon.description,78,39),
  substring(xCon.description,117,39),
  substring(xCon.description,156,39),
  substring(xCon.description,195,39),
  substring(xCon.description,234,39),
  substring(xCon.description,273,39),
  substring(xCon.description,312,39),  
  substring(xCon.description,351,39)
#DB=SQLSVR#    
#DB=Other#
  left(xCon.description,38),
  mid(xCon.description,40,38),
  mid(xCon.description,79,38),
  mid(xCon.description,118,38),
  mid(xCon.description,157,38),
  mid(xCon.description,196,38),
  mid(xCon.description,235,38),
  mid(xCon.description,274,38),
  mid(xCon.description,313,38),  
  mid(xCon.description,352,38)
#DB=Other#  
)

order by 3,4,5

To create the script follow these steps:
• Open the scripting window via View/Scripting.
• Create a new normal group (left icon) and name it e.g. ‘Searches’.
• Add a new VB script (2nd icon) and name it e.g. ‘Information Flow’.
• Double click the new entry to open the editor.
• Copy/Paste the following script into the editor and save the result (the famous diskette5
symbol).
Now when you select the appropriate connector in a diagram just click the run button (4th icon) to execute the script. This will open the search window with the listed resulting conveyed classes.

Code: [Select]
option explicit

!INC Local Scripts.EAConstants-VBScript

sub main()
  dim selectedConnector as EA.Connector
  set selectedConnector = Repository.GetContextObject()

  if selectedConnector is nothing OR
     selectedConnector.ObjectType <> otConnector then
    Session.Prompt "You must select an Information Flow", promptOK
    exit sub
  end if
  dim id
  id = CStr(selectedConnector.ConnectorID)
  Repository.RunModelSearch "Elements on Flow", id, "", ""
end sub

main()
q.

7961
He wants to add a conveyed item, not a new connector. There are several threads with SQL how to find conveyed items. That should give you a clue how to create them.

q.

7962
You might want to look in my Inside book. I've collected a bit of my wisdom when searching for those tidbits over a couple of years.

q.

7963
Yes, Simon. I wasn't reading carefully and now see that the OP want to hide attributes, not elements itself.

q.

7964
You can not suppress elements in a diagram. You need to remove them. EA_DiagramObjects lists all objects that appear on a specific diagram (they have an association with the relevant element). Just loop thoug EADiagram.DiagramObjects and remove everything you need.

q.

7965
Thanks, Simon. I was not aware of that.

q.

Pages: 1 ... 529 530 [531] 532 533 ... 653