Set a variable to the selected path name Photoshop
I am trying to assign the name of the currently selected Photoshop (like, normal) route to a variable.
I can do it for an artLayer as follows app.activeDocument.activeLayer.name; but I searched the web a way to isolate the active path.
Could someone help with this?
Thank you
Limey
Ah, I misunderstood.
This might help:
determine the path selected, set to day 09.2015.
function selectedPath2015 () {}
try {}
Var ref = new ActionReference();
ref.putProperty (stringIDToTypeID ("property"), stringIDToTypeID ("targetPathIndex"));
ref.putEnumerated (charIDToTypeID ("Dcmn"), charIDToTypeID ("Ordn"), charIDToTypeID ("Trgt"));
var docDesc = executeActionGet (ref);
return app.activeDocument.pathItems [docDesc.getInteger (stringIDToTypeID ("targetPathIndex"))]
}
catch (e) {return undefined}
};
Tags: Photoshop
Similar Questions
-
Set the Variable in the select statement
Hello
Can we define a variable in the select statement.
Example:
Select firstname, lastname
employees;
in this simple select statement we can define x as number?select fname,lname from employees where rownum <= 30;
-
Set a variable to the result of an instruction select
I create a list view of the numbers that I have in the system. I'm doing a table with only a list of numbers from 1 to whatever number max is in view. IIf 89 324 is so the last number in the system, so I want a table with 1 thru 89324. Then I can use the NOT EXIST to determine what numbers are miissing in the system. so, if 1 to 200 are not used, but by 89 324 201 is used, then I want the output to 1,2,3... 200.
The code to make the display works and the code to create the table is good, the loop works when I use a number defined for example 100. I just have problems affecting a variable in the number max.
Here's what I have (which of course does not)
Published by: james3302 on August 11, 2010 15:59CREATE OR REPLACE PROCEDURE test IS n number := 1; maxNum number; BEGIN execute immediate 'create view check_numbers as select num from table1 union select num from table2 union select num from table3'; maxNum := EXECUTE IMMEDIATE 'select max(num) from check_numbers'; --I also tried taking out the EXECUTE IMMEDATE here and it still did not work WHILE n <= maxIpid LOOP insert into numList values(n); n := n + 1; END LOOP; --Here I will put in the code to compare the two and display the numbers that are in numList but not in Check_numbers END; /
James,
The solution to your immediate problem to get the result of the immediate execution in a variable is to use
EXECUTE IMMEDIATE 'select max(num) from check_numbers' into maxNum;
You can also do without running to the immediate assistance
select max(num) into maxNum from check_numbers;
Of course, you should definitely consider using one of the other solutions already provided.
Depending on what you ultimately trying to reach, another option to consider is to get the list of discrepancies between the numbers to help
Method of Tabibitosan of Aketi ({: identifier of the thread = 1005478}).with t as ( select 1 as n from dual union all select 2 as n from dual union all select 7 as n from dual union all select 8 as n from dual union all select 11 as n from dual ) select * from ( select grp, n1, n2, 1+lag(n2,1,0) over(order by n1) as gap_n1, n1-1 as gap_n2 from ( select grp, min(n) as n1, max(n) as n2 from ( select n, n - row_number() over(order by n) as grp from t ) group by grp ) ) where grp>0 order by grp ; GRP N1 N2 GAP_N1 GAP_N2 ---------------------- ---------------------- ---------------------- ---------------------- ---------------------- 4 7 8 3 6 6 11 11 9 10
Kind regards
BobPublished by: BobLilly on August 11, 2010 15:00
-
set a variable to the sum of 2 variables
Hello
How can I set the value of the variable is the sum of a + b in a package
I get on the error message
java.lang.NumberFormatException...
Thank you
EyalHello
You need to "Refresh" the variable. You can only 'Set' constant. For example, I have variables a, b. In a package 'Set' a = 1, b = 2. Then 'Refresh' variable c as
Select #a + #b double
Checks if the value variable historized c = 3
See you soon
BOS
-
How to set a variable in the main timeline of in a symbol?
Just get started with Animate and coming from Flash, it may be apparent to my question. How do you define a variable for the main timeline of in a symbol?
I have 24 pairs of clickable elements, each in their own symbols, and 24 of these symbols to sit inside another symbol. I want every 24 to set the global variable even when you click on it. I do not find that this question is anywhere, which makes me think that I can be stuck in a mentality from Flash and approaching the task in a bad way. (However, there are MANY discussions address showing how objects to different levels in the hierarchy.) Which is well covered).
By the way, how to access a function on the main timeline of in a symbol?
Adobe should consider putting on foot (or pages) support just for people migration form Flash. In the documents that I've met so far there seems to be a studied effort to refrain from mentioning Flash somehow. I imagine that there are many people out there like me who have a deep background in coding Flash, but start with Animate. We don't need help with most of the basic concepts, but we still have some pretty basic questions on how to achieve certain things in Animate because our knowledge of Flash gets in the way.
Hi Bill,
There are a lot of discussions here on the scope, but here's a way to create a global variable:
code on Stage.compositionReady
sym.myGlobalVar = 1;
Then, anywhere in your project, you can check/set this var as follows:
sym.getComposition () .getStage () .myGlobalVar = 2;
And here is a way to create a global function:
code on Stage.compositionReady
sym.myGlobalFunction = function() {}
Console.log ('myGlobalFunction');
}
Then, anywhere in your project, you can call this function as follows:
sym.getComposition () .getStage () .myGlobalFunction ();
-
File name of the Image displayed in PSE 8 does not match the file path name in Windows 7
I recently got a new computer. I've updated on my computer Windows XP of PSE 5.0 to 8.0 PSE. Then, I moved my files to the new computer that is running Windows 7, following the instructions that I have received on a previous post. I copied the catalog file and the image files on the C drive of the old computer to the new computer (file catalog to the specified location in the information system; images of my images). Everything seems to have worked beautifully without having to go through a great struggle to reconnect. The organzer seems to have found all of the images and I can put them in the editor as well. However, when I look at the properties of a given image displayed full file name is that it was on XP: C:\Documents and Settings\ < username > \My Documents\My Pictures\ < folder name >-< Filename > rather than the path as it is in Windows 7, i.e. C:\Users\ < username > \My Pictures\ < file name >-< Filename >. I am new to Windows 7 then maybe miss me something unique to Windows 7 but I'd like information.
You are using the alias of the special folder that Vista and Windows 7 create to maintain backward compatibility (Microsoft continues to change how and where are stored the documents of users). On Windows 7:
C:\Documents and Settings\
\My Documents\My photos is a special type of alias in the file:
C:\Users\
\Pictures (And
C:\Users \My Pictures is yet another kind of Windows 7 special alias, a 'library', which includes the folder C:\Users \Pictures.) Whenever an application like PES refers to the old location, C:\Documents and Settings\
\My Documents\My photos, Windows that automatically converts backstage in C:\Users\ \Pictures. But Windows Explorer is configured to prevent you to access C:\Documents and Settings\ interactively - only programs like PES are able to do. Microsoft wants users of Windows Explorer to always use the name of 'new', C:\Users\ \Pictures. In your case, your catalog contained the old paths of XP folder, and Windows is automatically translate on the fly for new paths, unbeknownst to PSE.
Like most of the backward compatibility hacks, this does not work perfectly. PSE believe that the old road and new road are two completely different cases. I'm not positive, but I think that there are opportunities for PSE to get confused by that. When you import new pictures, they get recorded in the Catalog under the new folder paths.
In my previous recommendation about how to move to the new computer, I had assumed you would probably change user names and locations of photo and so you would have to make a reconnection, and you would not have met it. If I thought that you were not have need to reconnect, I would have recommended not not using this method, but rather using Backup/Restore (my first recommended method) - my bad.
It would be nice if your current catalog and the PES works pretty well. But there is at least a small risk that the road of PSE will get confused by old and new folder names. The best way to avoid this would be to start again and use the backup/restore method to move your catalogue, which is more effort on your part. But because I do not understand the risk, I can't tell you if you should be worried about it. No doubt do tests: editing, import and edition of new photos, use view > view of the location of the folder, try to rename and move the old photos and the new folders, try the Photo Downloader, etc.
-
using variable in the select statement (php)
I have trouble using a variable in a select statement.
The following query to manually (using a static date) works very well:
$query_Recordset1 = "SELECT * from academyClasses WHERE the classDate > ' 2006-06-01' ';"
However, if I use the following:
$dateVar = date('Y-m-d');
@mysql_select_db ($database_mw, $mw);
$query_Recordset1 = "SELECT * from academyClasses WHERE the classDate > $dateVar";
All records are returned, which means that the $dateVar variable is not recognized. I compared the values of $dateVar <? PHP echo $datetime;? > against the real value of my date field <? PHP echo $row_Recordset1 ["classDate"];? > in my results to the table and it seems that the values are indeed accurate regarding a date 2006-06-04 for example.
My date field 'classDate' is of type 'date' in the mysql database. I use Dreamweaver MX 2004 with Mac OSX 10.3.9.
I'm sure it's just a syntax problem, at least, I hope it is.
Any help is greatly appreciated.
It worked:
$query_Recordset1 = "SELECT * from academyClasses WHERE the classDate > = CURRENT_DATE;
Thank you
MW -
How to set a Variable with the data Srouce store data
Hello ODI Experts.
I created a physical & logical schema and a Data Source store collection data to a database table.
On the other hand, I have a little variable I'll pass in a web service call (ODIInvokeWebService tool).
Yo please guide how do I set up my store of data source variables.
Thank you and best regards,
ArfaouiHello
You can close this thread you opened another for your question.
To answer you second point, it depends on what you select. You can use the function list_agg of values separated by commas if you wish. Or add/edit you WHERE to ROWNUM = 1 to clause example
See you soon
BOS
-
Hi all
I'm using Oracle 11 g R2 and Linux.
I'm working on a code in which I need to dynamically pass values to 'IN' clause in a select statement.
A short demonstration of my question is as below: -.
Set serveroutput on
/
declare
NUM varchar2 (100): = 1, 2';
number of v_inst_id;
Start
dbms_output.put_line (' value of num before :-'||) (NB);
Select INST_ID select
in v_inst_id
GV $ session
where username = 'SYS '.
and to_char (inst_id) in (num) - 1, 2
order of INST_ID select;
exception
while others then
dbms_output.put_line (SQLERRM);
end;
/
anonymous block filled
Before value of num:-1, 2
ORA-01403: no data found
------------------------------------------------------------------------------------------------------------------------------------------------------------------
Select INST_ID select
-by v_inst_id
GV $ session
where username = 'SYS '.
and to_char (inst_id) in (1,2)
order of INST_ID select;
INST_ID SELECT
----------
1
1
1
2
2
2
Please let me know why my request does not work in plsql but works perfectly in sql.
Thanks in advance.
VJ4 wrote:
Hello
Thanks for your reply.
Can you please give a brief explanation on the example you showed?
with this request
SELECT to_number (REGEXP_SUBSTR (num ' [^,] +', 1, ROWNUM)) p_id
OF THE DOUBLE
WHERE to_number (REGEXP_SUBSTR (num ' [^,] +', 1, ROWNUM)) IS NOT NULL
CONNECTION BY INSTR (num, ',', 1, LEVEL - 1) > 0
I shared your (digital) channel of n number of rows in the table
SQL > set serveroutput on;
SQL >
SQL >-created the 11.06.2014 by RAMIN. H
SQL > declare
2 num varchar2 (100): = '1.2'.
3. start
4 r in (SELECT to_number (REGEXP_SUBSTR (num, ' [^,] +', 1, ROWNUM)) p_id)
5 DOUBLE
6. WHERE to_number (REGEXP_SUBSTR (num ' [^,] +', 1, ROWNUM)) IS NOT NULL
7 CONNECT BY INSTR (num, ',', 1, LEVEL - 1) > 0) loop
8 dbms_output.put_line (r.p_id);
9 end of the loop;
10 end;
11.
1
2
PL/SQL procedure successfully completed
SQL >
SQL >-created the 11.06.2014 by RAMIN. H
SQL > declare
2 num varchar2 (100): = "1,2,3,4,5,6";
3. start
4 r in (SELECT to_number (REGEXP_SUBSTR (num, ' [^,] +', 1, ROWNUM)) p_id)
5 DOUBLE
6. WHERE to_number (REGEXP_SUBSTR (num ' [^,] +', 1, ROWNUM)) IS NOT NULL
7 CONNECT BY INSTR (num, ',', 1, LEVEL - 1) > 0) loop
8 dbms_output.put_line (r.p_id);
9 end of the loop;
10 end;
11.
1
2
3
4
5
6
PL/SQL procedure successfully completed
SQL >
SQL >
SQL > SELECT to_number (REGEXP_SUBSTR ('& num', ' [^,] +', 1, ROWNUM)) p_id
2 FROM TWO
3. WHERE to_number (REGEXP_SUBSTR ('& num', ' [^,] +', 1, ROWNUM)) IS NOT NULL
4 CONNECT BY INSTR ("& num', ',', 1, LEVEL - 1") > 0
5.
P_ID
----------
1
2
3
4
5
6
SQL >
----
Ramin Hashimzade
-
Export PDF to the selective path
Hello world
I tried this code to export my PDF in a specific location that is defined in the script below.
"But I could only receive the error 'Cannot find the location of the folder'~C:\\Documents and Settings\Wande\Desktop\Wander_2.pdf '.
When I tried to use the same script for Mac, it works, but in Windows, it is not.
myFolder = "~C:\\Documents and Settings\Wande\Desktop\Wander_2\";
myDoc var = app.activeDocument;
var myPath = myDoc.filePath;
I want to save the PDF file to my specific location (MyAccount) and not in the path of the document (myDoc.filePath).
var myDocname = myDoc.name.split (".indd");
app.activeDocument.exportFile (ExportFormat.PDF_TYPE, file (new file (MyFolder + "\" + myDocname.join (".pdf")));)
Please help on this forum.
Hi wander,
Try the code js modifed below.
//If you want to choose the folder location and save the file. Use the below line. var myFolder = Folder.selectDialog(); //You want default location use the below line. var myFolder = "~\Desktop"; var myDoc = app.activeDocument; var myDocname = myDoc.name.split(".indd"); myDoc.exportFile(ExportFormat.PDF_TYPE, File(new File(myFolder+"\\" + myDocname.join(".pdf"))));
THX,
csm_phil
-
How to remove the file/path name using the SDK
I have a program that uses the Acrobat SDK from Adobe kit. It creates the aPDF file from a HTML file that is created after the jugs of program data. It can create PDF very well, but how can he do with on the file name and path in the lower left corner. Insert us the PDF file created in another document and that you do not want to display the data on these pages created.
Sought through this site and can not see mentioned. Help!
How do you convert from HTML to PDF format?
-
I tried many ways to create a custom PS CC brush (2015), and all my efforts give the same error identified in the subject. I copied the shape layer in PS CC (2014) and everything worked fine. As a solution, I saved the brush set out and transferred to 15. I can't understand what is wrong. Is there a bug in 15 w 'set preset shape' specifically? Greatly appreciate suggestions and knowledge. Thank you!
See you soon,.
-DK
Which will not. There's nothing a brush without bristles of brush 100% white. There is nothing to set.
-
How can I select the objects and remove the other objects by using the selection path
I know that I am able to do this in photoshop. Select an object, lets say a group of letters just by ctrl clicking on the thumbnail of the layer, then put another layer of more selected a group of letters, then go on the other layer (not the Group of letters) and pressing DELETE. I hope I explained it well, otherwise, here is a video that made a good explanation of it. Gyazo - 015091c2a0a6d2da038901dfb16c0a7f.gif I just need to know if there is something similar to that offered in illustrator, thank you!
What you're trying to re-create the Photoshop is called: less prominent of the Pathfinder Panel.
-
ODI error - no value to set this variable when the scenario planning
Hi all
I will carry out the PIP of accounting revenue to load XML BRM for Oracle GL data. When I run the package by using a local agent, the data is loaded successfully by ODI gl_interface table. However, when I schedule the script to load the data of gl BRM to GL_interface table of ODI I get the following error. Kindly help
java.lang.Exception: error: no value to assign to this variable for DefDate:2007 - 05-17 14:21:47.0
DefN:null
DefV:null
IndStore:L
ITxtDefT:4141200
ITxtVar:null
SessNo:215200
VarDatatype:T
VarName:PORTAL_TO_ORACLE_GL_PROJECT. PVV_SOB_ID
at com.sunopsis.dwg.dbobj.SnpSessTaskSqlV.execStdOrders (SnpSessTaskSqlV.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTaskTrt (SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSqlV.treatTaskTrt (SnpSessTaskSqlV.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask (SnpSessTaskSql.java)
at com.sunopsis.dwg.dbobj.SnpSessTaskSqlV.treatTask (SnpSessTaskSqlV.java)
at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep (SnpSessStep.java)
at com.sunopsis.dwg.dbobj.SnpSession.treatSession (SnpSession.java)
at com.sunopsis.dwg.cmd.DwgCommandScenario.treatCommand (DwgCommandScenario.java)
at com.sunopsis.dwg.cmd.DwgCommandBase.execute (DwgCommandBase.java)
at com.sunopsis.dwg.cmd.e.i (e.java)
at com.sunopsis.dwg.cmd.g.y (g.java)
at com.sunopsis.dwg.cmd.e.run (e.java)
at java.lang.Thread.run(Thread.java:595)
Thank you
AnandOk
If you get more problems, let know us.
Please, remember to close the request if the problem is solve and also, to assing status each answer which was useful or appropriate for you.
Thank you
Cezar
-
Assign the values of the two variables in a select statement
I'm trying to set two variables in a select statement in my definition of the procedure. I get the error identifier not valid "ATTRIBUTE" running the following code.
Can I not connect two different values to two different variables in the same select?create or replace procedure tbl_auth ( Email in varchar2, UserLevel out number) as v_Email varchar2(100) := lower(Email); v_login_chk number := 0; begin select UserLevel into p_UserLevel, v_login_chk into v_login_chk from tbl_User where eMail=v_Email exception when no_data_found then UserLevel := 0; end tbl_auth;
Thank you
Published by: jerry8989 on August 22, 2011 07:06
Published by: jerry8989 on August 22, 2011 07:06change as follows:
select UserLevel, v_login_chk into p_UserLevel, v_login_chk
IN ONE ALONE is enough.
BTW, don't you have "login Check" column in the "tbl_user"? If you do, your selection should be like this:
... select UserLevel, loginChk into /* check the column name in your table */ p_UserLevel, v_login_chk from tbl_User ...
Maybe you are looking for
-
Cannot access admin or safe mode...
Hi, I have a HP Pavilion dv2500 with a screen broken or burned. (My step grandson accidentally shot of the stool on which I got). I hung it on a monitor so that it can still be used and have since bought another. I put the password on the admin acco
-
I bought 2 ink cartrides black and each of them bled the cartridge ink in the printhead to the printer on the stand. Finally, I got an error message that says oxc18a0406. Then, I get a message of failure print on the display window. I tried to clean
-
I am running Vista 32-bit SP2 and my sound card is a Creative Soundblaster X - Fi 2 days ago, that everything worked well yesterday there was no noise. The sound worked perfectly before and nothing is no indication that the card may be faulty. When I
-
BlackBerry Smartphones Messages folder displays only e-mails not SMS messages.
Hello, I just changed a Pearl to a Curve 8900 and I'm having a bit of trouble getting the same functuionality. My messages folder only shows emails I sent and received and not SMS or MMS messages that I've sent and received. This means that when I r
-
Bluetooth application for pc windows 7 64 bit
is there a bluetooth for windows 7 64 bit pc application? need download link