Open "Attach file" dialog by scripting
Hi,
Is it posible to open the "Attach file dialog" by scripting?
Thanks in advance, Oliver
Hello,
It is possible by using Acrobat scripting API.
You can do it by the following code:
event.target.importDataObject("name");
Similar Messages
-
How to prompt user to select multiple files in file dialog using scripts
Hi, is there a way to allow user to select multiple files inside the file dialog using scripts? So not just something like "*.ai" or "*.eps" but where the user can actually use their shift key to select a batch of files inside the file dialog and then the script would process each one.
Thanks!// Main Code [Execution of script begins here]
here's what I have so far. it would also be nice to not have illustrator stop at errors.. right now, it skips dialogs but on errors, it still stops.
// uncomment to suppress Illustrator warning dialogs
app.userInteractionLevel = UserInteractionLevel.DONTDISPLAYALERTS;
var destFolder, sourceFolder, files, fileType, sourceDoc, targetFile, pdfSaveOpts, folderName;
var fullPath = "";
var finalSlash;
// Select the source folder.
sourceFolder = Folder.selectDialog( 'Select the folder with Illustrator .ai files you want to convert to PDF');
f = find_files(sourceFolder);
function find_files (dir)
return find_files_sub (dir, []);
function find_files_sub (dir, array)
var f = Folder (dir).getFiles ("*.*");
for (var i = 0; i < f.length; i++)
if (f[i] instanceof Folder)
find_files_sub (f[i], array);
else
if (f[i].name.slice (-3).toLowerCase() == ".ai" || f[i].name.slice (-4).toLowerCase() == ".eps")
//convert the array-listing to a string so we can manipulate it
fullPath = String(f[i]);
//find the position of the last / to indicate where the filename starts
finalSlash = fullPath.lastIndexOf("/");
//get the foldername by "slicing" from start to where finalSlash is located
folderName = fullPath.slice(0, finalSlash).toLowerCase();
sourceDoc = app.open(f[i]); // returns the document object
// Call function getNewName to get the name and file to save the pdf
targetFile_PNG = getNewName(".png");
if(targetFile_PNG.exists) {
} else {
pngExportOpts = getPNGOptions();
sourceDoc.exportFile(targetFile_PNG, ExportType.PNG24, pngExportOpts );
targetFile_PDF = getNewName(".pdf");
pdfSaveOpts = getPDFOptions();
sourceDoc.saveAs(targetFile_PDF, pdfSaveOpts );
targetFile_SVG = getNewName(".svg");
svgSaveOpts = getSVGOptions();
sourceDoc.exportFile(targetFile_SVG, ExportType.SVG, svgSaveOpts );
sourceDoc.close();
array.push (f[i]);
getNewName: Function to get the new file name. The primary
name is the same as the source file.
function getNewName(ext)
var ext, docName, newName, saveInFile, docName, finalDot
var loop = 0;
docName = sourceDoc.name;
ext = ext; // new extension for pdf file
newName = "";
finalDot = sourceDoc.name.lastIndexOf(".");
while(loop < finalDot)
newName += docName[loop];
loop = loop + 1;
newName += ext; // full pdf name of the file
newName = newName.replace(" [Converted]","");
// Create a file object to save the pdf
saveInFile = new File( folderName + '/' + newName );
return saveInFile;
getPDFOptions: Function to set the PDF saving options of the
files using the PDFSaveOptions object.
function getPDFOptions()
// Create the PDFSaveOptions object to set the PDF options
var pdfSaveOpts = new PDFSaveOptions();
// Setting PDFSaveOptions properties. Please see the JavaScript Reference
// for a description of these properties.
// Add more properties here if you like
pdfSaveOpts.acrobatLayers = false;
pdfSaveOpts.colorBars = false;
pdfSaveOpts.colorCompression = CompressionQuality.AUTOMATICJPEGHIGH;
pdfSaveOpts.compressArt = true; //default
pdfSaveOpts.embedICCProfile = false;
pdfSaveOpts.enablePlainText = false;
pdfSaveOpts.generateThumbnails = false; // default
pdfSaveOpts.optimization = true;
pdfSaveOpts.pageInformation = false;
pdfSaveOpts.preserveEditability = true;
return pdfSaveOpts;
function getSVGOptions()
var svgSaveOpts = new ExportOptionsSVG();
//just using defaults aside from what's written below
//see http://cssdk.host.adobe.com/sdk/1.0/docs/WebHelp/references/csawlib/com/adobe/illustrator/ ExportOptionsSVG.html
svgSaveOpts.embedRasterImages = true;
svgSaveOpts.sVGTextOnPath = true;
return svgSaveOpts;
function getPNGOptions()
// Create the PDFSaveOptions object to set the PDF options
var pngExportOpts = new ExportOptionsPNG24();
// Setting PNGExportOptions properties. Please see the JavaScript Reference
// for a description of these properties.
// Add more properties here if you like
pngExportOpts.antiAliasing = true;
pngExportOpts.artBoardClipping = false;
pngExportOpts.horizontalScale = 100; // scaling to 350%
pngExportOpts.saveAsHTML = false;
pngExportOpts.transparency = true;
pngExportOpts.verticalScale = 100; // scaling to 350%
return pngExportOpts; -
My Safari quits unexpectedly while trying to open attached files or download?
I had that problems once. My friend reinstalled My IMac for me. It worked. But now it is happening again. Safari quits unexpectedly while I am trying to open attached files or download anything. I hate that. I want that to never happen again. And I don't actually know how to reinstall the system. I am afraid of doing smthing wrong. So I have to call apple or my friend. What is the easiest way and solution for that? What is the reason for this problem?
Thank you.Try the following:
1. Shutdown the computer and then start it up again, see if Safari repeats the problem.
2. Consider the source file, if it is just one or the same ones all the time but other open, the files are the problem and not Safari.
3. Run a permissions repair on the mac. Do this via Applications > Utilities > Disk Utility and select the hard drive (Second Icon with the Hard Drive Name, not the one showing the drive size above it) in the left pane and in the bottom middle click on permissions repair, don'yt worry you won't break the computer. -
Automation Question: How do I work with an open 'upload file' dialog?
Preamble:
Was a very experienced VBS automation guy, this is my first emersion into the wonderful world of C# automation. Using Selenium WebDiver, I have successfully logged into a web page, filled out a few web forms, clicked on the 'add image' button and am
now faced with an open 'upload file' dialog. Pretty sure the namespace I need is system.windows.forms.OpenFileDialog so added the reference to my project.
Question:
All the examples on the web seem to relate to app development and not test automation. But, I need to automate this web application and all that's left is the image upload. What do I do when faced with an
already opened 'upload file' dialog? I know the image and path, how do I automate the process of placing the full path into the dialog and clicking the OK button or alternately, enter key?
Thank you!I doubt that you need System.Windows.Forms.OpenFileDialog, the browser isn't written using WinForms and that dialog is a Win32 native dialog.
Maybe you should post this in the Selenium Users
group? It has little to do with C#, it's more about how Selenium interacts with the browser. -
'Open a File' dialog box doesn't show 'Favorites'
InDesign CS6, Windows 7:
File/Open gives me this:
Notice there are no 'Favorites' on the left. I have to 'browse' for my file each time. I have a ton of files on the network, and it takes several clicks to get to them. Annoying when I'm opening several files a day. The 'Recent Places' isn't too helpful here either.
Now look at what happens in InDesign CC, Windows 7 with a File/Open:
Look at all the 'Favorites' and easy browsing on the left side. Why are the 'Open a File' dialog boxes so different in CS6 and CC? I want the CS6 'Open' dialog to be just like the CC one. (I prefer to use CS6, CC is buggy on my system.)Not helpful.
What it is... is cumbersome and un-necessary. Every other program in Windows (even Word Pad) opens with the 'standard' dialog with Favorites on the left. Why did Adobe program it differently? There has to be a fix in Preferences or something... -
Open a File Dialog Box to browse through image files
Hi all
I need to develop a code to open a File Dialog Box to browse through Image Files in Oracle 10g.
Once the Image File is selected i need to save the file in a Table Column in the Backend Table.
Please help me.
Thanks
Nakul VenkatramanHi
Thanks for your prompt response on this.
I came across a Sample Form File which would allow the User to browse through files from local PC.
Following is the code :
declare
dirname varchar2(255);
v_filename varchar2(255);
begin
message('1');
tool_env.getvar('E:\', dirname);
message('2');
dirname := dirname || '\project';
message('3');
v_filename := get_file_name(dirname,NULL,
'All Files (*.*)|*.*|' ||
'JPEG Files (*.jpg)|*.jpg|' ||
'Bitmap Files (*.bmp)|*.bmp|' ||
'TIFF Files (*.tif)|*.tif|' ||
'CompuServe Files (*.gif)|*.gif|' ||
'PC Paintbrush Files (*.pcx)|*.pcx|' );
message('4');
if v_filename is not null then
read_image_file(v_filename,'ANY','pp_foto.foto');
end if;
end;
The code is written inside WHEN-BUTTON-PRESSED Trigger.
When i run the form it is not opening the dialog box.
Please help.
Regards
Nakul -
How to change "Date Added" to "Date Modified"in Open a File dialoge
Ever since updating IOS to the latest version the option to sort by "Date Modified" in the open a file dialog has been changed to "Date Added". How can I change this back to "Date Modified"?
Hmm, in OpenSolaris and Solaris Express, the date format is a preference in the Nautilus Preferences dialog. But I don't see it back in JDS 3.
One way (assuming you're using a bash shell) is:
% gnome-session-remove nautilus
% LANG=de_DE nautilus &
which works, but also switches the rest of the nautilus UI into German.
Setting LC_TIME rather than LANG in the second command should work better, because it changes only the dates/times into German. But it still uses the 12 hour clock, with "vorm." and "nachm." instead of "am" and "pm". I suppose that might be considered a bug... -
Windows live 1.00 (6141): can't open attached file...
I updated latest firmware of My Nokia E71.
After updating Windows live mail doesnt run properly.
When I try to open attached files
After a few seconds , showing message "retriving attacment" . gives this error " Failed to fetch this attacchment,Please resyncronise your inbox"
Any solution??
Thanks
Haldun AYDIN
Turkiye
Solved!
Go to Solution.Go to phone book > place Windows LIVE> Options > About
you will see:
For support :
http://support.live.com
If you need my help or I late with an answer you need, send me a private message
P.S.
Please before doing that, be sure you have already searched the topict on this site about the issue you have. Read Help sections before asking. Describe yor issue step by step with complete details. -
In PowerPoint 2013 on Windows 7 - 64 bit, when
File / Save as is selected, an error message comes up stating, "An error occurred while opening the file dialog. Please save your presentation, exit, and restart PowerPoint." This is an intermittent issue and also
affects Excel 2013. I have tried repairing it, done windows update and also uninstalled and reinstalled but no luck. I have researched this issue but it relates to Office 2007 and 2010 and the resolution does not support 2013.
Has anyone come across this issue? If so how did you resolve it?
Many thanks….Hi,
You mentioned you tried some steps but I'm not sure what they are, you may try my suggestion to resolve this issue, follow these steps:
Click Start, right-click Computer, click
Properties, and then click Advanced system settings.
On the Advanced tab, click Environment Variables.
Locate and select the __COMPAT_LAYER variable, and then click Edit.
Set the value of the __COMPAT_LAYER variable to EnableThemes. Or, delete the __COMPAT_LAYER variable.
If the issue persists, we can troubleshoot this problem in Clean Boot to determine whether background programs are interfering with PowerPoint:
http://support.microsoft.com/kb/929135
Regards,
Melon Chen
TechNet Community Support -
Open a file dialog box using java
Duncan & Frank or anyone
Can you please tell, or give me a link, which explains how to open a file dialog box using java, and not webutil.
I'm trying to read a file on the desktop and update a database table.
ThanksSee Open File Dialog on the WEB... If you can get me the full version numbers I can tell you your supported position.
Regards
Grant -
Hi,
could somebody help me with how to open a file dialog box.
I have 1 class which has a window with the relevant widgets on it, I want to be able to click a button on the form and pop up a file chooser form then select a file or type in a new filename and then use the selected filename path in the original form to write data out to the chosen file.
i understand that i need to use JFileChooser and it will need to be in a new class (like a dialog box would be).
So basically what i have is 2 classes (the main app and a class called FileOpen.class) so how would i display the fileopen class with the JFileChooser component in it and return what ever is chosen into a string.
e.g.
String fileName = <what would go here?>
kind regardsthats the example filechooser i have working
yet when i try and implement it in my program i just get countless exception errors, im not sure if its because my program extends Jframe and not JPanel
here is my code:-
package as4;
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
import javax.swing.border.*;
import java.util.*;
import javax.swing.filechooser.*;
import java.io.*;
* <p>Title: </p>
* <p>Description: </p>
* <p>Copyright: Copyright (c) 2003</p>
* <p>Company: </p>
* @author unascribed
* @version 1.0
* <p>Title: </p>
* <p>Description: </p>
* <p>Copyright: Copyright (c) 2003</p>
* <p>Company: </p>
* @author unascribed
* @version 1.0
public class Readap extends JFrame {
JPanel contentPane;
GridLayout gridLayout1 = new GridLayout();
JPanel jPanel3 = new JPanel();
GridLayout gridLayout3 = new GridLayout();
JPanel jPanel1 = new JPanel();
JTextArea txtaStatus = new JTextArea();
JLabel jLabel1 = new JLabel();
JTextField txtCon = new JTextField();
JButton btnConnect = new JButton();
JTextField txtPort = new JTextField();
JTextField txtUser = new JTextField();
GridLayout gridLayout2 = new GridLayout();
JLabel jLabel6 = new JLabel();
JPasswordField ptxtPass = new JPasswordField();
JLabel jLabel5 = new JLabel();
JLabel jLabel4 = new JLabel();
JLabel jLabel3 = new JLabel();
JLabel jLabel2 = new JLabel();
JTextField txtHost = new JTextField();
JPanel jPanel2 = new JPanel();
JPanel jPanel4 = new JPanel();
GridLayout gridLayout4 = new GridLayout();
GridLayout gridLayout5 = new GridLayout();
JCheckBox chbOracle = new JCheckBox();
JCheckBox chbOdbc = new JCheckBox();
JScrollPane jScrollPane1 = new JScrollPane();
JRadioButton rbtnComma = new JRadioButton();
JRadioButton rbtnTab = new JRadioButton();
JRadioButton rbtnSpace = new JRadioButton();
ButtonGroup delChoice = new ButtonGroup();
JPanel delPanel = new JPanel();
JFileChooser fc;
int dbChoice = 1;
int conStatus = 0 ;
String delimiter=",";
String output="";
JButton btnClear = new JButton();
Dbfuncs mydb=new Dbfuncs();
JPanel jPanel7 = new JPanel();
JPanel jPanel6 = new JPanel();
JPanel jPanel5 = new JPanel();
FlowLayout flowLayout1 = new FlowLayout();
JButton btnExecute = new JButton();
JTextField txtQuery = new JTextField();
JLabel jLabel7 = new JLabel();
JButton btnOutput = new JButton();
JLabel jLabel8 = new JLabel();
GridLayout gridLayout7 = new GridLayout();
BorderLayout borderLayout1 = new BorderLayout();
JButton btnExit = new JButton();
TitledBorder titledBorder1;
TitledBorder titledBorder2;
JCheckBox chbQuotes = new JCheckBox();
JPanel jPanel8 = new JPanel();
JCheckBox chbHeading = new JCheckBox();
JPanel jPanel9 = new JPanel();
ButtonGroup fileChoice = new ButtonGroup();
JRadioButton rbtnOverwrite = new JRadioButton();
JRadioButton rbtnAppend = new JRadioButton();
//Construct the frame
public Readap() {
fc = new JFileChooser();
fc.setFileSelectionMode(JFileChooser.FILES_AND_DIRECTORIES);
enableEvents(AWTEvent.WINDOW_EVENT_MASK);
try {
jbInit();
catch(Exception e) {
e.printStackTrace();
//Component initialization
private void jbInit() throws Exception {
//setIconImage(Toolkit.getDefaultToolkit().createImage(Readap.class.getResource("[Your Icon]")));
contentPane = (JPanel) this.getContentPane();
titledBorder1 = new TitledBorder("");
titledBorder2 = new TitledBorder("");
contentPane.setLayout(gridLayout1);
this.setSize(new Dimension(448, 434));
this.setTitle("Read Database");
gridLayout1.setColumns(1);
gridLayout1.setHgap(2);
gridLayout1.setRows(2);
gridLayout1.setVgap(2);
jPanel3.setLayout(gridLayout3);
gridLayout3.setColumns(2);
gridLayout3.setHgap(5);
gridLayout3.setVgap(5);
txtaStatus.setFont(new java.awt.Font("Dialog", 0, 10));
txtaStatus.setBorder(BorderFactory.createLoweredBevelBorder());
txtaStatus.setEditable(false);
txtaStatus.setText(">>Program Loaded...");
txtaStatus.setLineWrap(true);
txtaStatus.setRows(5);
txtaStatus.setWrapStyleWord(true);
jLabel1.setFont(new java.awt.Font("Dialog", 1, 12));
jLabel1.setToolTipText("");
jLabel1.setHorizontalAlignment(SwingConstants.CENTER);
jLabel1.setText("Please choose a database...");
txtCon.setText("Access");
btnConnect.setText("Connect");
btnConnect.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(ActionEvent e) {
btnConnect_actionPerformed(e);
txtPort.setEnabled(false);
txtPort.setToolTipText("");
txtPort.setText("1521");
gridLayout2.setColumns(2);
gridLayout2.setHgap(5);
gridLayout2.setRows(6);
gridLayout2.setVgap(2);
jLabel6.setHorizontalAlignment(SwingConstants.RIGHT);
jLabel6.setText("Password");
jLabel5.setHorizontalAlignment(SwingConstants.RIGHT);
jLabel5.setText("Username");
jLabel4.setHorizontalAlignment(SwingConstants.RIGHT);
jLabel4.setText("ODBC Bridge");
jLabel3.setHorizontalAlignment(SwingConstants.RIGHT);
jLabel3.setText("Port");
jLabel2.setHorizontalAlignment(SwingConstants.RIGHT);
jLabel2.setText("Host");
txtHost.setEnabled(false);
txtHost.setText("alfgar.coventry.ac.uk");
jPanel2.setLayout(gridLayout2);
contentPane.setMinimumSize(new Dimension(100, 110));
jPanel4.setLayout(gridLayout4);
gridLayout4.setColumns(1);
gridLayout4.setHgap(2);
gridLayout4.setRows(3);
gridLayout4.setVgap(2);
jPanel1.setLayout(gridLayout5);
gridLayout5.setColumns(1);
gridLayout5.setHgap(5);
gridLayout5.setRows(2);
gridLayout5.setVgap(5);
rbtnComma.setText("Comma");
rbtnComma.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(ActionEvent e) {
rbtnComma_actionPerformed(e);
rbtnTab.setText("Tab");
rbtnTab.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(ActionEvent e) {
rbtnTab_actionPerformed(e);
rbtnSpace.setText("Space");
rbtnSpace.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(ActionEvent e) {
rbtnSpace_actionPerformed(e);
rbtnComma.setSelected(true);
jLabel8.setFont(new java.awt.Font("Dialog", 1, 12));
jLabel8.setHorizontalAlignment(SwingConstants.CENTER);
jLabel8.setText("Choose Delimiter Type");
jPanel7.setLayout(gridLayout7);
gridLayout7.setColumns(1);
gridLayout7.setRows(6);
jPanel6.setMinimumSize(new Dimension(434, 45));
jPanel6.setPreferredSize(new Dimension(434, 45));
btnExit.setText("Exit");
btnExit.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(ActionEvent e) {
btnExit_actionPerformed(e);
jPanel5.setBorder(titledBorder2);
jPanel5.setMinimumSize(new Dimension(434, 187));
jPanel3.setBorder(titledBorder1);
btnExecute.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(ActionEvent e) {
btnExecute_actionPerformed(e);
chbQuotes.setText("Wrap Data In Quotes");
chbHeading.setText("Export Column Headings");
rbtnOverwrite.setSelected(true);
rbtnOverwrite.setText("Overwrite File");
rbtnAppend.setText("Append File");
jPanel7.setBorder(BorderFactory.createLineBorder(Color.black));
btnOutput.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(ActionEvent e) {
btnOutput_actionPerformed(e);
delChoice.add(rbtnComma);
delChoice.add(rbtnTab);
delChoice.add(rbtnSpace);
delPanel.add(rbtnComma);
delPanel.add(rbtnTab);
delPanel.add(rbtnSpace);
chbOracle.setAlignmentX((float) 10.0);
chbOracle.setHorizontalAlignment(SwingConstants.CENTER);
chbOracle.setText("Oracle");
chbOracle.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(ActionEvent e) {
chbOracle_actionPerformed(e);
chbOdbc.setAlignmentX((float) 10.0);
chbOdbc.setHorizontalAlignment(SwingConstants.CENTER);
chbOdbc.setSelected(true);
chbOdbc.setText("MS ODBC");
chbOdbc.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(ActionEvent e) {
chbOdbc_actionPerformed(e);
btnClear.setText("Clear Status");
btnClear.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(ActionEvent e) {
btnClear_actionPerformed(e);
jPanel6.setLayout(flowLayout1);
jPanel5.setLayout(borderLayout1);
btnExecute.setText("Execute");
txtQuery.setMinimumSize(new Dimension(280, 21));
txtQuery.setPreferredSize(new Dimension(285, 21));
jLabel7.setFont(new java.awt.Font("Dialog", 1, 12));
jLabel7.setText("Enter Query");
btnOutput.setText("Output To File");
jPanel3.add(jPanel1, null);
jPanel1.add(jPanel4, null);
jPanel4.add(jLabel1, null);
jPanel4.add(chbOdbc, null);
jPanel4.add(chbOracle, null);
jPanel1.add(jScrollPane1, null);
jScrollPane1.getViewport().add(txtaStatus, null);
jPanel3.add(jPanel2, null);
jPanel2.add(jLabel2, null);
jPanel2.add(txtHost, null);
jPanel2.add(jLabel3, null);
jPanel2.add(txtPort, null);
jPanel2.add(jLabel4, null);
jPanel2.add(txtCon, null);
jPanel2.add(jLabel5, null);
jPanel2.add(txtUser, null);
jPanel2.add(jLabel6, null);
jPanel2.add(ptxtPass, null);
jPanel2.add(btnClear, null);
jPanel2.add(btnConnect, null);
jPanel6.add(jLabel7, null);
jPanel6.add(txtQuery, null);
jPanel6.add(btnExecute, null);
jPanel7.add(jLabel8, null);
jPanel7.add(delPanel, null);
jPanel7.add(jPanel8, null);
jPanel8.add(chbQuotes, null);
jPanel8.add(chbHeading, null);
jPanel7.add(jPanel9, null);
jPanel9.add(rbtnOverwrite, null);
jPanel9.add(rbtnAppend, null);
jPanel7.add(btnOutput, null);
jPanel7.add(btnExit, null);
jPanel5.add(jPanel6, BorderLayout.NORTH);
jPanel5.add(jPanel7, BorderLayout.SOUTH);
contentPane.add(jPanel3, null);
contentPane.add(jPanel5, null);
fileChoice.add(rbtnOverwrite);
fileChoice.add(rbtnAppend);
//Overridden so we can exit when window is closed
protected void processWindowEvent(WindowEvent e) {
super.processWindowEvent(e);
if (e.getID() == WindowEvent.WINDOW_CLOSING) {
System.exit(0);
public static void main (String arguments[])
JFrame frame = new Readap();
WindowListener l = new WindowAdapter()
public void windowClosing(WindowEvent e)
System.exit(0);
frame.addWindowListener(l);
frame.pack();
frame.setVisible(true);
void chbOracle_actionPerformed(ActionEvent e) {
dbChoice=0;
chbOdbc.setSelected(false);
jLabel4.setText("Conn String");
txtCon.setText("acal");
txtCon.setEnabled(true);
txtPort.setEnabled(true);
txtHost.setEnabled(true);
txtaStatus.append("\n>>Oracle Database Selected");
void chbOdbc_actionPerformed(ActionEvent e) {
dbChoice=1;
chbOracle.setSelected(false);
jLabel4.setText("ODBC Bridge");
txtCon.setText("Access");
txtPort.setEnabled(false);
txtHost.setEnabled(false);
txtaStatus.append("\n>>MS ODBC Database Selected");
void btnConnect_actionPerformed(ActionEvent e) {
if (conStatus==0)
String url = new String();
String driver = new String();
if (dbChoice==0)
driver="oracle.jdbc.driver.OracleDriver";
url = "jdbc:oracle:thin:@"+txtHost.getText()+":"+txtPort.getText()+":"+txtCon.getText();
txtaStatus.append("\n>>Connecting to Oracle Database @ "+url+" via driver:"+driver);
else
driver = "sun.jdbc.odbc.JdbcOdbcDriver";
url = "jdbc:odbc:"+txtCon.getText();
txtaStatus.append("\n>>Connecting to MS ODBC Database @ "+url+" via driver:"+driver);
String dbStatus=mydb.openDb(url, driver, txtUser.getText(), ptxtPass.getText());
txtaStatus.append("\n>>"+dbStatus);
if (dbStatus=="Connection Successful")
btnConnect.setText("Disconnect");
conStatus=1;
else
mydb.dbClose();
txtaStatus.append("\n>>Database Connection Terminated");
btnConnect.setText("Connect");
conStatus=0;
void btnClear_actionPerformed(ActionEvent e) {
txtaStatus.setText(" ");
void rbtnComma_actionPerformed(ActionEvent e) {
delimiter=",";
void rbtnSpace_actionPerformed(ActionEvent e) {
delimiter=" ";
void btnExecute_actionPerformed(ActionEvent e) {
txtaStatus.append(mydb.runQuery(txtQuery.getText() ) );
void btnOutput_actionPerformed(ActionEvent e) {
if (chbHeading.isSelected()==true)
output=mydb.getAllColName(mydb.getColumnName())+"\n";
else
output="";
Vector mydata=mydb.getResultData();
int cnt=0;
for (int index = 0; index < mydata.size(); index++)
cnt+=1;
if (cnt>1) output=output+delimiter;
if (chbQuotes.isSelected()==true)
output=output+"\""+mydata.elementAt(index)+"\"";
else
output=output+mydata.elementAt(index);
if (cnt>=mydb.getNumCols())
output=output+"\n"; cnt=0;
txtaStatus.append("\n>>"+output);
int returnVal = fc.showOpenDialog(Readap.this);
if (returnVal == JFileChooser.APPROVE_OPTION) {
File file = fc.getSelectedFile();}
void rbtnTab_actionPerformed(ActionEvent e) {
delimiter="\t";
void btnExit_actionPerformed(ActionEvent e) {
System.exit(0);
} -
Cannot Play farmvile from Facebook and ca not. Open attached.files of power point HELP
i can not Play farmvile from Facebook neither other games and cannot open attached files of power point etc HELP
For Farmville have you tried their Farmville app ? The official Facebook app says :
Play games on the go: Access your favorite Facebook apps and games, wherever you are
For the Powerpoint attachments the Mail app should be able to open .PPT and .PPTX files -
Open attached file in the same editor(ZCRM_DNO_MONITOR customer program)
Hi All,
I wrote a dialog program to simplify the CRM_DNO_MONITOR. I gave the facility to attach file from the PC(any doc type .txt ,doc, xls. etc) by calling the functions. I need to give a facility to open these attached file in the same edit. Please let us know way
Additionally,I can find the logical and physical document of these attached files
e. g
(Doc class : CRM_L_ORD
Doccument : 4CA517D70BE60F7FE1000000AC113F3F
Doc Class CRM_P_ORD
Document 4CA517D80BE60F7FE1000000AC113F3F)
Attached files successfully by calling the following functions
objkey = wa_tab-guid . " (crmd_orderadm_h-guid)
objtype = 'BUS2000116'.
CALL FUNCTION 'SO_FOLDER_ROOT_ID_GET
CALL FUNCTION 'SO_DOCUMENT_REPOSITORY_MANAGER
CALL FUNCTION 'BINARY_RELATION_CREATE_COMMIT'
CALL FUNCTION 'CRM_KW_MIGRATE_GOS' DESTINATION 'NONE'Hello ,
i think you can make use of Clase CL_GOS_MANAGER
check Sap program which are using this clasee.
try yourself and let me know if you have any doubts.
regards
Prabhu -
How do I fix the slow attachment file dialog box in Mail?
I'm on 10.9.2, using Mail with an Exchange account. Everything works great except when I go to attach a file to an outgoing email the file dialog box takes ~1 minute to open. Only app I've seen this in.
I've tried the fixes posted for the general file dialog box being slow (e.g. comment out "/net" in the "auto_master" file) to no avail.
Other thoughts?Click on the Firefox menu. Then click "Options". Go to "Applications" tab. Search for jpg and png file type. You will find they have "Always ask" action attribute. Change it to "Save file".
Hope it will work fine for you. -
Open Save File Dialog with Default Path
Hi All,
I want to open a "Save File Dialog " with some default path.
Like when user run that script I want to open a "Save As" dialog box with default path "/Volumes/<shared name>/<folder name>/.. ."
I am using
File.SaveDialog(prompt, filter);
but it doesn't open to the location by default that I want to open.
Thanks
Harshlook at this thread to see if it helps
http://forums.adobe.com/thread/1077267?tstart=0
Maybe you are looking for
-
My volume is greyed out when I turn on the Mac, but for some reason it works again when I turn on bluetooth. Nothing in system prefs changes this??? Its all very random and sometimes I do not have this problem at all or it is fixed again when I resta
-
How to apply PO template from test database to live database?
I have created a PO template in my test database and I want to apply to the live database. Is any way to accomplish this task? i.e. any import or export method between different database? (Test environment or live environment?)
-
Report : list of Modvatable GRn
Dear all , Can i have report for : list of Modvatable GRn in SAP systems Regards
-
I have to install Web Dispatcher.please refer any document or links that would guide me through the complete installation procedure. Thanks in advance Regards, Piyush
-
Update group in credit mg.-urgent
Hi folks, where do we assigne Update group in credit management to automatic credit control. is there any Tc. for it. sourav