<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Save library item settings. in Archicad C++ API</title>
    <link>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249688#M3365</link>
    <description>&lt;BLOCKQUOTE&gt;Ralph wrote:&lt;BR /&gt;
Sorry, I'm still confused about what you want to achieve. Can you describe the intended workflow?
&lt;/BLOCKQUOTE&gt;

&lt;BR /&gt;
I apologize for the intrusiveness. But I found a similar topic that you had in mind?&lt;BR /&gt;
What are some ways?&lt;BR /&gt;
&lt;A href="https://archicad-talk.graphisoft.com/viewtopic.php?f=23&amp;amp;t=44981&amp;amp;p=225195&amp;amp;hilit=global&amp;amp;sid=0793479d82eeaa075789f9d53e586a39#p225195" target="_blank"&gt;&lt;LINK_TEXT text="viewtopic.php?f=23&amp;amp;t=44981&amp;amp;p=225195&amp;amp;hil ... 39#p225195"&gt;https://archicad-talk.graphisoft.com/viewtopic.php?f=23&amp;amp;t=44981&amp;amp;p=225195&amp;amp;hilit=global&amp;amp;sid=0793479d82eeaa075789f9d53e586a39#p225195&lt;/LINK_TEXT&gt;&lt;/A&gt;</description>
    <pubDate>Fri, 19 Oct 2018 11:46:55 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-10-19T11:46:55Z</dc:date>
    <item>
      <title>Save library item settings.</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249681#M3358</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;Hello&lt;BR /&gt;Help change and save library item settings.&lt;BR /&gt;I can change them for the required library element, it is not placed on the plan and not the default tool. From this element, the script GDL then has to get globals.
&lt;PRE&gt;void ModifyGlobParameters (const API_Guid &amp;amp;guid , const UInt32 index ,
	const double &amp;amp;valD1 , const double &amp;amp;valD2 )
{	
	API_ParamOwnerType   paramOwner;	
	API_ChangeParamType  chgParam;		
	API_GetParamsType    getParams;		
	GSErrCode            err;			
		
	BNZeroMemory (&amp;amp;paramOwner, sizeof (API_ParamOwnerType));	BNZeroMemory (&amp;amp;getParams, sizeof (API_GetParamsType)); 
	paramOwner.libInd = index; // !!!! default parameters of a Library Part itself !!!!
	paramOwner.typeID = API_ObjectID;      
	
	err = ACAPI_Goodies (APIAny_OpenParametersID, &amp;amp;paramOwner, NULL);
	if (err == NoError) {
		BNZeroMemory (&amp;amp;chgParam, sizeof (API_ChangeParamType));
		err = ACAPI_Goodies (APIAny_GetActParametersID, &amp;amp;getParams, NULL); 
		if (err == NoError) {
			chgParam.index = 0; 
			CHCopyC ("Global_ALL_SUMM_K", chgParam.name); 
			chgParam.realValue =  valD1;
			err = ACAPI_Goodies (APIAny_ChangeAParameterID, &amp;amp;chgParam, NULL); 
			if (err == NoError)
				err = ACAPI_Goodies (APIAny_GetActParametersID, &amp;amp;getParams, NULL); 
			chgParam.index = 0; 
			CHCopyC ("Global_kSum", chgParam.name); 
			chgParam.realValue = valD2;
			err = ACAPI_Goodies (APIAny_ChangeAParameterID, &amp;amp;chgParam, NULL); 
			if (err == NoError)
				err = ACAPI_Goodies (APIAny_GetActParametersID, &amp;amp;getParams, NULL); 
		}
		ACAPI_Goodies (APIAny_CloseParametersID, NULL, NULL);
		WriteReport ("All OK 1: %lf	2: %lf", (*getParams.params)[2].value.real , (*getParams.params)[3].value.real );
	}	
	if (err == NoError) {
		
		API_Element     element; 
		API_Element		mask;
		API_ElementMemo      memo;
		BNZeroMemory (&amp;amp;element, sizeof (API_Element));
		BNZeroMemory (&amp;amp;memo, sizeof (API_ElementMemo));
		ACAPI_ELEMENT_MASK_CLEAR (mask); 
		guid;
		element.header.typeID = API_ObjectID; 
		err = ACAPI_Element_GetDefaults (&amp;amp;element, &amp;amp;memo);
		ACAPI_ELEMENT_MASK_CLEAR (mask); 
		ACAPI_ELEMENT_MASK_SET (mask, API_ObjectType, libInd);					       
                element.object.libInd = index; 
		memo.params = getParams.params;	
		 //err =ACAPI_Element_ChangeDefaults (&amp;amp;element, &amp;amp;memo, &amp;amp;mask);
		//err = ACAPI_Element_Change (&amp;amp;element, &amp;amp;mask, &amp;amp;memo, );
               // SAVE ??????? unplaced library item parameters, not default tools

	}
	ACAPI_DisposeAddParHdl (&amp;amp;getParams.params);
	return;
}//ModifyLibParameters (void)
&lt;/PRE&gt;
&lt;/DIV&gt;</description>
      <pubDate>Wed, 05 Oct 2022 11:37:20 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249681#M3358</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-10-05T11:37:20Z</dc:date>
    </item>
    <item>
      <title>Re: Save library item settings.</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249682#M3359</link>
      <description>Just to clarify, are you trying to change the parameters of a library part (in the library – not an element instance placed in the project)?</description>
      <pubDate>Fri, 05 Oct 2018 12:08:51 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249682#M3359</guid>
      <dc:creator>Ralph Wessel</dc:creator>
      <dc:date>2018-10-05T12:08:51Z</dc:date>
    </item>
    <item>
      <title>Re: Save library item settings.</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249683#M3360</link>
      <description>Yes.  not an element instance placed in the project.&lt;BR /&gt;
It seems to me that you need to change the values that are set when creating the library element. The task as a whole is to transfer the values from the API -&amp;gt; GDL Global (LIBRARYGLOBAL)-&amp;gt; Gdl Object&lt;BR /&gt;
&lt;A href="https://ibb.co/fP7mwz" target="_blank"&gt;&lt;IMG src="https://thumb.ibb.co/fP7mwz/Global_noplaced.jpg" /&gt;&lt;/A&gt;</description>
      <pubDate>Fri, 05 Oct 2018 14:41:49 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249683#M3360</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-10-05T14:41:49Z</dc:date>
    </item>
    <item>
      <title>Re: Save library item settings.</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249684#M3361</link>
      <description>Sorry, I'm still confused about what you want to achieve. Can you describe the intended workflow?</description>
      <pubDate>Fri, 05 Oct 2018 15:07:23 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249684#M3361</guid>
      <dc:creator>Ralph Wessel</dc:creator>
      <dc:date>2018-10-05T15:07:23Z</dc:date>
    </item>
    <item>
      <title>Re: Save library item settings.</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249685#M3362</link>
      <description>From the API, you need to change the parameters of the biliotech element, this element will not be placed on the plan, and will not be the element of the tool by default.&lt;BR /&gt;
&lt;A href="http://archicadapi.graphisoft.com/documentation/api_paramovnertype" target="_blank"&gt;&lt;LINK_TEXT text="http://archicadapi.graphisoft.com/docum ... movnertype"&gt;http://archicadapi.graphisoft.com/documentation/api_paramovnertype&lt;/LINK_TEXT&gt;&lt;/A&gt;&lt;BR /&gt;
Library part default - so I get it, then change it, but I don’t know how to save&lt;BR /&gt;
&lt;BR /&gt;
Then through the GDL, LIBRARYGLOBAL ("Get_Global", "Global_kSum", kSum) in the desired element.</description>
      <pubDate>Fri, 05 Oct 2018 16:52:02 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249685#M3362</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-10-05T16:52:02Z</dc:date>
    </item>
    <item>
      <title>Re: Save library item settings.</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249686#M3363</link>
      <description>&lt;BLOCKQUOTE&gt;ufo_ru wrote:&lt;BR /&gt;
From the API, you need to change the parameters of the biliotech element, this element will not be placed on the plan, and will not be the element of the tool by default.&lt;BR /&gt;
&lt;A href="http://archicadapi.graphisoft.com/documentation/api_paramovnertype" target="_blank"&gt;&lt;LINK_TEXT text="http://archicadapi.graphisoft.com/docum ... movnertype"&gt;http://archicadapi.graphisoft.com/documentation/api_paramovnertype&lt;/LINK_TEXT&gt;&lt;/A&gt;&lt;BR /&gt;
Library part default - so I get it, then change it, but I don’t know how to save&lt;BR /&gt;
&lt;BR /&gt;
Then through the GDL, LIBRARYGLOBAL ("Get_Global", "Global_kSum", kSum) in the desired element.
&lt;/BLOCKQUOTE&gt;

So, then is it a library global that appears in the model view options?&lt;BR /&gt;
&lt;BR /&gt;
Akos</description>
      <pubDate>Tue, 09 Oct 2018 11:34:15 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249686#M3363</guid>
      <dc:creator>Akos Somorjai</dc:creator>
      <dc:date>2018-10-09T11:34:15Z</dc:date>
    </item>
    <item>
      <title>Re: Save library item settings.</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249687#M3364</link>
      <description>Yes it is, in the first version of my addon there was a global library element whose parameters were changed through the parameters of the model view. And all this can be implemented without addon with pure GDL properties. But as it turned out, the use of model view parameters in the event that it is not a graphical display that depends on it, but quantitative measurements are not the best solution. It is difficult to track the parameters of the model view, especially in interactive catalogs. Therefore, I decided to develop a second version of the addon where the global element will be changed not through GDL, but through the API, especially since I still created a modal window for the addon parameters. As can be seen from the code, I found this global library element made a change in its parameters, but I can not save it.&lt;BR /&gt;
&lt;BR /&gt;
In short, it is necessary to change the parameters of the global library element from the API, after which the GDL script of library elements considers them.</description>
      <pubDate>Tue, 09 Oct 2018 12:48:43 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249687#M3364</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-10-09T12:48:43Z</dc:date>
    </item>
    <item>
      <title>Re: Save library item settings.</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249688#M3365</link>
      <description>&lt;BLOCKQUOTE&gt;Ralph wrote:&lt;BR /&gt;
Sorry, I'm still confused about what you want to achieve. Can you describe the intended workflow?
&lt;/BLOCKQUOTE&gt;

&lt;BR /&gt;
I apologize for the intrusiveness. But I found a similar topic that you had in mind?&lt;BR /&gt;
What are some ways?&lt;BR /&gt;
&lt;A href="https://archicad-talk.graphisoft.com/viewtopic.php?f=23&amp;amp;t=44981&amp;amp;p=225195&amp;amp;hilit=global&amp;amp;sid=0793479d82eeaa075789f9d53e586a39#p225195" target="_blank"&gt;&lt;LINK_TEXT text="viewtopic.php?f=23&amp;amp;t=44981&amp;amp;p=225195&amp;amp;hil ... 39#p225195"&gt;https://archicad-talk.graphisoft.com/viewtopic.php?f=23&amp;amp;t=44981&amp;amp;p=225195&amp;amp;hilit=global&amp;amp;sid=0793479d82eeaa075789f9d53e586a39#p225195&lt;/LINK_TEXT&gt;&lt;/A&gt;</description>
      <pubDate>Fri, 19 Oct 2018 11:46:55 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Save-library-item-settings/m-p/249688#M3365</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-10-19T11:46:55Z</dc:date>
    </item>
  </channel>
</rss>

