File Selection using the SDK

Hello
Is their a way that the SBO SDK UI exposes the file selection like the one use for add bit maps etc? I tried doing this by using writing code but cannot get this to display on the screen it is called from. The code is:
Public Function Open_FileView()
   Dim OpenFileDialog1 As New OpenFileDialog
   OpenFileDialog1.InitialDirectory = "C:\"
   OpenFileDialog1.Filter = "txt files (.txt)|.txt|All Files (.)|."
   OpenFileDialog1.FilterIndex = 2
   OpenFileDialog1.RestoreDirectory = True
   If OpenFileDialog1.ShowDialog = DialogResult.OK Then
      Dim sr As New System.IO.StreamReader(OpenFileDialog1.FileName)
      MessageBox.Show(sr.ReadToEnd)
      sr.Close()
   End If
End Function
Thanks
John

Try something like this:
System.Windows.Forms.Form winForm = new System.Windows.Forms.Form();
winForm.TopMost = true;
System.Windows.Forms.SaveFileDialog sfd = new System.Windows.Forms.SaveFileDialog();
sfd.Filter = "XML (*.xml)|*.xml";
if(sfd.ShowDialog(winForm)==System.Windows.Forms.DialogResult.OK) {
//Do stuff
This work for me (Save dialog, but openfiledialog works the same way)

Similar Messages

  • How to remove file attachments using the SDK

    I am looking for ways to programmatically remove file attachments from work items.  If I recall correctly, the system only keeps the file for as long as the relationship exists, so that, in theory, the file is deleted from the database a soon as the
    relationship is removed.
    I found this
    Using the SDK to Create and Edit Objects and Relationships Using Type Projections
    Is this the only way or are the other, simpler ways for deleting relationships and/or file attachments?
    Is this something I could do with the Orchestrator Remove Relationship activity?
    A little background on this question: I have multiple different teams with varying data retention requirements for Service Requests.  My longest requirement is 3 years (audit) while most teams only require 90 days.  I was looking to add in some
    jobs for some more aggressive file attachment grooming to keep the database smaller.
    Thanks.

    The relationship is defined as a membership/containment relationship. So, yes, if you delete the relationship, the file attachment (and the associated blob) are deleted as well.
    Based on the background you described, I'm assuming you identify a bunch of work orders whose files you want to delete if they're older than X. So, for instance "Work Items with Y team; delete file attachments older than 90 days", "Work Items
    with Q team; delete file attachments older than 3 years". Is that right?
    If so, you don't necessarily need to delete relationships specifically...you can simply delete the file attachment objects which will delete the relationship, the file attachment object, and the associated blob (the file itself in the database).
    Using the SDK, you will not need type projections for this. You'll only need the work item object(s) (an incident or service request or whatever), the GetRelatedObjects<>() method, and an IncrementalDiscoveryData object.
    So, after you get all of the appropriate work items, you can use the following snippet to delete their file attachments if the attachments meet your age requirements
    //Connect to the management group
    String strMySCSMServer = "<my mgmt server>";
    emg = new EnterpriseManagementGroup(strMySCSMServer);
    IncrementalDiscoveryData idd = new IncrementalDiscoveryData();
    ManagementPackRelationship relWorkItemHasFileAttachment = emg.EntityTypes.GetRelationshipClass(new Guid("AA8C26DC-3A12-5F88-D9C7-753E5A8A55B4")); //System.WorkItemHasFileAttachment
    //Get the work item's related file attachments using it's Id
    Guid myWorkItemGuid = new Guid("<some work item guid>");
    IList<EnterpriseManagementObject> lstFileAttachments = emg.EntityObjects.GetRelatedObjects<EnterpriseManagementObject>(myWorkItemGuid, relWorkItemHasFileAttachment, TraversalDepth.OneLevel, ObjectQueryOptions.Default);
    //Loop through each file attachment
    foreach (EnterpriseManagementObject emoFile in lstFileAttachments)
    //Determine its age
    DateTime AddedDate = (DateTime)emoFile[null, "AddedDate"].Value;
    TimeSpan FileAttachmentAge = AddedDate.Subtract(DateTime.Now);
    //Prep the file attachment for deletion if it's old enough, in this example, older than 90 days
    if (FileAttachmentAge.Days > 90)
    idd.Remove(emoFile);
    //Submit the deletions to the database.
    idd.Commit(emg);

  • How to get Bursting file to use the same template as selected by user

    I have created an XML publisher bursting control file for a standard Oracle report Direct Debit letter.
    The user wants to be able to select from a number of different letter templates which is ok except that the bursting control file is fixed to use one template.
    How can I get the bursting control file to use the same letter template as selected by the user when running the report ?
    I am using XML Publisher 5.6.3 with bursting patch.

    Try these following, which come to my mind now as of now.
    In the bursting file, you can do the filtering and apply different template..
    <xapi:template type="rtf" location="/usr/template1" filter=".//DIRECT_DEBIT[./parameter_or_element='first_template']"></xapi:template>
    <xapi:template type="rtf" location="/usr/template2" filter=".//DIRECT_DEBIT[./parameter_or_element='second_template']"></xapi:template>
    second option..
    you can replace the element from the xml in the bursting control file.
    ${ELEMENT_NAME}
    can be used in the template name i guess..
    <xapi:template type="rtf" locale=""
    location="xdo://AR.${SHORT_NAME}.en.US/?getSource=true" translation="" filter="">
    </xapi:template>
    But in this short name has to be in XML file...
    I haven;t tried it...wil try it wheni get time..

  • How do you remove the filename/path using the SDK

    I have a program that uses the Adobe Acrobat SDK . It creates aPDF file from a HTML file that gets created after the program cruches some data. It can create the PDF file fine but how do I get it to do it with out the file name and path in the lower left corner. We insert the created PDF file into another document and do not want to show the data on these created pages.
    Have searched through this site and can not see it mentioned.   HELP !!!

    I am not the programmer, he is out of the office today.
    What I see happen is that our program is used to create a database of the content of a multipage PDF file (an old doucment that has been scanned and OCR'd), the program then outputs the data as a HTML file (not the Adobe SDK).
    This HTML file is then converetd into a PDF file and attached to certain subsets of the original PDF file, its does a whole bunch of splitting and recombining of the document into the sections we need. It does this fine, no problems at all. All of this is done using our program and the Adobe SDK.
    The issue is that the PDF file (generally just one page) that gets created from the HTML file includes file name and file path at the lower left corner of the page. We are looking for the commands within the SDK that can turn the feature/function that creates this text on/off.
    As the Adobe Acrobat on this machine is used for many different jobs, some that require this text to be shown on other documents that are created (by using Acrobat itself and not the SDK) we really don't want to have to open Acrobat itself everytime we want to run this process.
    The SDK seems to have commands for pratically everything else, we were hoping it also has the commands within it that we can then program to not create this one area of text when converting the HTMl to PDF file from within our program..
    I hope that comes across OK
    PS
    I just ran a test creating a PDF file froma  webpage, and I can see the field Place Headers and Footers on a new page. I have tried creating the page with and without the Headers and Footers, that works fine. But can this be done just by using the SDK and if so where is that command located.
    Message was edited by: MichaelEastick

  • Could not save Preferences because the file is locked, you do not have necessary access permissions, or another program is using the file. Use the 'Get Info' command in the Finder to ensure the file is unlocked and you have permission to access the file.

    I have this massage every time close ps cc
    Could not save Preferences because the file is locked, you do not have necessary access permissions, or another program is using the file. Use the ‘Get Info’ command in the Finder to ensure the file is unlocked and you have permission to access the file. If the problem persists, save the document to a different file or duplicate it in the Finder.

    You may get better help in Photoshop General Discussion
    The Cloud forum is not about using individual programs
    The Cloud forum is about the Cloud as a delivery & install process
    If you will start at the Forums Index https://forums.adobe.com/welcome
    You will be able to select a forum for the specific Adobe product(s) you use
    Click the "down arrow" symbol on the right (where it says All communities) to open the drop down list and scroll
    If FINDER means Mac, read below (and try to give more information when asking a question)
    Mac 10.9.3 workaround https://forums.adobe.com/thread/1489922
    Enable Mac Root User https://forums.adobe.com/thread/1156604
    -more Root User http://forums.adobe.com/thread/879931
    -and more root user http://forums.adobe.com/thread/940869?tstart=0

  • Occasionally,  some of the image borders turn dark grey (medium grey is the default) and then random other  images cannot be opened with a double click.  They only open when selected using the arrows on the keyboard.  They also cannot be moved to collecti

    Occasionally,  some of the image borders turn dark grey (medium grey is the default) and then random other  images cannot be opened with a double click.  They only open when selected using the arrows on the keyboard.  They also cannot be moved to collections.  Anyone have a solution for this?

    When you say  "could not be opened"- what are you referring to?  A double click of the mouse should view the clicked image in Loupe view- the same as pressing [E] on the keyboard for an enlarged view. (And a second double-click will take you back to library grid view.)
    To "open" an image in the Development module requires you to select the image then press [D] or click on the [Develop] button.
    When you say "could not be ...moved" -what are you referring to?  Are you trying to move an image file from its place in a folder to another folder? Are you just wanting it in a collection? When you drag an image to a collection you are only placing a link to the image in the collection- not actually moving any file. The image will stay exactly where it is in its original folder and will remain as a thumbnail preview in the Library Grid view.
    Are you having any "mouse" problems that may be changing its actions in LR ?
    Do you see an exclamation mark on any image borders ?
    Let's keep working on this. I am curious to see you find an answer.
    Rob

  • Is there a capability to save/export the time capsule settings file when using the iphone/ipad airport utility. the "file" button does not exist on the latest airport utility app.

    is there a capability to save/export the new airport 2TB time capsule settings file when using the iphone/ipad airport utility. set-up wasn't a problem but the "file" button does not exist on the latest airport utility app v6.3 to save the configuration file.

    the "file" button does not exist on the latest airport utility app v6.3 to save the configuration file.
    Sounds like you are a bit confused with version numbers.
    Latest AirPort Utility version for the iPhone / iPad is 1.3.3.  There is no option or capability to export/import settings on the iOS version(s) of AirPort Utility.....although you could take a series of screen shots and save them for future reference.
    AirPort Utility 6.3.x is found on a Mac.....not on iPhone / iPad. Export and Import options are found under the File menu in 6.3.x.

  • Get File Information using the Document ID in Javascript

    I store in a custom list the Document Id of a linked document. I need to retrieve some metadata - at least the filename - of that document. I have tried using the Search REST API specifying something like "DocID:INGX1-2-26" in my search query,
    but nothing is returned, nothing found.
    Is there any other way to get the file info when all I have is the Document ID? In the managed code, I could use the Microsoft.Office.DocumentManagement.dll which provides a way to get the file info using the DocId, but this is not available in Javascript.
    Any ideas?
    thanks.

    Hi,
    As a workaround, we can create a custom web service with the Microsoft.Office.DocumentManagement.dll, then you can call the web service using JavaScript.
    Here are some links about Building and Consuming Custom WCF Services hosted in SharePoint for your reference:
    http://nikpatel.net/2012/02/29/step-by-step-building-custom-wcf-services-hosted-in-sharepoint-part-i/
    http://www.c-sharpcorner.com/uploadfile/sridhar_subra/consuming-wcf-asmx-rest-service-using-jquery/
    http://leonidius2010.wordpress.com/2011/05/06/custom-web-service-for-sharepoint-an-easy-way/
    Thanks
    Patrick Liang
    Forum Support
    Please remember to mark the replies as answers if they
    help and unmark them if they provide no help. If you have feedback for TechNet
    Subscriber Support, contact [email protected]
    Patrick Liang
    TechNet Community Support

  • Opening my Photoshop Elements 11 does not work. I always get following message: "Could not open a volume of work, because the file is locked or you do not have the required permissions. Undo the protection of the file on using the command 'Properties' in

    Opening my Photoshop Elements 11 does not work. I always get following message: "Could not open a volume of work, because the file is locked or you do not have the required permissions. Undo the protection of the file on using the command 'Properties' in Windows Explorer." What is wrong? I cannot unterstand what I have to do!

    Could not open a scratch file because the file is locked or you do not have the necessary access privileges. (…) | Mylen…
    Mylenium

  • Firefox 33 doesn't display a pdf file when using the response object

    Firefox 33.0.2 does not display pdf files when using the code below from an asp.net program, which works for previous versions of Firefox, and also works with IE. I'm using the built-in pdf viewer. All of my plugins are disabled.
    Dim strPDF As String
    strPDF = Session("filname") 'pdf filename
    Response.Clear()
    Response.ClearHeaders()
    Response.Buffer = True
    Response.ContentType = "application/pdf"
    Response.CacheControl = "Private"
    Response.AddHeader("Pragma", "no-cache")
    Response.AddHeader("Expires", "0")
    Response.AddHeader("Cache-Control", "no-store, no-cache, must-revalidate")
    Response.AddHeader("Content-Disposition", "inline; filename=" + strPDF)
    Response.WriteFile(strPDF)
    Response.Flush()
    Response.Close()
    Response.Clear()
    Response.End()
    Session("filname") = ""

    Thanks cor-el. You pointed me in the right direction. It appears to me that a reported Firefox 33 bug with the handling of compression (Transfer-Encoding: chunked) is the culprit (https://support.mozilla.org/en-US/questions/1026743). I was able to find a work-around by specifying the file size and buffering. Below is my code, with some code from http://www.codeproject.com/Questions/440054/How-to-Open-any-file-in-new-browser-tab-using-ASP.
    Dim strPDF As String
    strPDF = Session("filname") 'pdf filename
    Dim User As New WebClient()
    Dim FileBuffer As [Byte]() = User.DownloadData(strPDF)
    If Not (FileBuffer Is Nothing) Then
    Response.Clear()
    Response.ClearHeaders()
    Response.CacheControl = "Private"
    Response.AddHeader("Pragma", "no-cache")
    Response.AddHeader("Expires", "0")
    Response.AddHeader("Cache-Control", "no-store, no-cache, must-revalidate")
    Response.ContentType = "application/pdf"
    Response.AddHeader("content-length", FileBuffer.Length.ToString())
    Response.BinaryWrite(FileBuffer)
    Response.Flush()
    Response.Close()
    Response.Clear()
    Response.End()
    End If
    Session("filname") = ""

  • How to find the File name using the FTP Adapter

    hi all,
    how to find the File name using the FTP Adapter with BPEL.
    Regards

    Found the solution for this.
    First In the mediator's routing rule use assign property $in.property.jca.file.FileName to $out.property.jca.file.FileName
    In the BPEL's receive activity go to the properties tab and get the property to a BPEL variable. That should do it.
    Thanks for the posts

  • Setting password expiry using the SDK

    Without using the iDS console, meaning just by using the SDK, could I set the period for password expiry?
    Since the userPassword is a multi-value attribute, how can I differentiate between which is the password for signing-onto the server and which are passwords for other applications?

    If you mean to configure the password policy using the SDK, a Modify operation for the base object "cn=config" and replacing the value of "PasswordMaxAge" attribute will work.
    If you intend to set a specific expiration time for a specific user, you should not do this and let the server set the expiration time based on the configured password ploicy.
    For more information on the password policy configuration, you can refer to the Administration Guide.
    Also, although userPassword is multivalued, the pasword policy as currently defined in the Directory server suppose that the userPassword attribute contains only 1 value. If the password contains more than 1 value, the result of the password policy is undefined.
    And there is no way to differentiate between passwords.
    Regards,
    Ludovic.

  • HT4889 How do change the ownership of files after using the migration assistant?

    After I copied all of my files across using the migration assistant, the tool is nice enough to assume that I want to use the same ID that I had on my PC.  This is not my case as I am using a different name on the mac.  How do I get the files from the other user name?  I have already set the sharing permissions so that I can see them on both user ids, however the only way I can see to update is to copy them all.  As I have about 1TB of files, this is a little inconvenient.  Any thoughts?

    Thanks.  It got me on the right track.  At the end, I copied the 1TB over and just deleted the other profile.  I tried to set the ownership to my regular ID by removing the lock from "Get Info" but I still had to move them out of the other "user" folder.

  • Cannot save files or use the undo function in InDesign CC

    As of this morning, I am not able to save files or use the Undo function in InDesign CC. Tried many fixes but nothing has worked. I have a ton of work to get done today -- any solutions for this???

    Im viewing this thread because its just happened to me again... my solution is below.
    Im currently running the latest version of  indesign cc (9.2.1) on my brand new 13" macbook pro. (OSX 10.9.4)
    As noted earlier in this thread, when this happens, before you give up and close in frustration,  EXPORT the file as IDML, and your all good!
    Ive had this issue on several occasions using Indesign CC since October. Here are my 2 'Usual Suspects' when this occurs:
    1. culprit: SUITCASE FUSION 5 – deactivate 'auto activation' from within Indesign Prefs. In some cases, i didn't even restart Indesign (much less my computer) for this to work.
    (menu: INDESIGN/PREFERENCES/ SUITCASE FUSION 5 AUTO ACTIVATION PREFS (bottom of submenu list)  Uncheck the top box,  'Auto Activate....')
    Im assuming this was rechecked to auto-activate after an update. Hasn't happened in a while—but sure enough, the auto-activate box was checked again.
    Its a pain having to manually-activate fonts, but its alot easier than redoing a bunch of work!
    2. culprit: CRASH PLAN (online backup)– actually, ive seen this happen with a couple of backup programs. I don't know that this is for sure an issue, but it did resolve the saving issue earlier this year.  I just pause backup for a few hours, then resume. Seems to be ok.
    Steps i took:
    Quit Indesign CC (AFTER EXPORTING the file as IDML!)
    Pause backup within CrashPlan.
    Restart Indesign CC.

  • Dynamic Image issue using the SDK CrystalReportViewer in a Web Farm

    Hello,
    Well it's the classic dyanamic Red X image problem with a twist. We have the CrystalReportViewer control coded into an ASPX web page using the BOE XI R2 SDK.
    The problem is everything works fine (after all the usual Red X image fixes) when only one of the servers in the farm are running. It's when two are running, by using Process Monitor, I can tell NetScaler is splitting up the HTTP calls so one server may have the temp image created and of course the other one doesn't.
    Therefore, if you're lucky enough for one server to handle most of the load, image comes up fine. Otherwise, the report renders, but you get Red X for the image.
    I have seen an article about a registry key (CrystalImageDir) that allows you to enter a network share as the temp folder. The problem is, we are using Windows Integrated Authentication for the intranet site so you're faced the two hop authentication hurtle, leading to access denied on the UNC network path.
    Anyone using the SDK in a .NET application using multiple web front end servers?
    Thanks!
    Horus

    By the way, I'm hearing that NetScaler can handle sticky sessions. However, since a report with dynamic images is really a GET request for the report, then a bunch of sub-GETs to grab the images, what URL would you set the sticky session for?
    For example, if the web page containing the CrystalReportsViewer was:
    https://coolapplication.mycompany.com/Site100/ReportApp/ViewReport.aspx
    Then report the viewer would contain links to something like:
    https://coolapplication.mycompany.com/Site100/ReportApp/CrystalImageHandler.aspx?dynamicimage=cr_tmp_image_5671d67a-4f5d-4ab1-b3c8-0d2561ee64f3.png
    So which URL/page gets load balanced? Or is that not how LB works?
    Thanks!
    Horus

Maybe you are looking for

  • I reedemed a movie and it only downloaded in hd and I need it in SD is there a way to get the sd version?

    I recently bought the hunger games catching fire movie combo, which included the the sd and hd movie plus the digital reemption code for itunes.  When I reeded the code onlt the HD version of the movie showed up in my purchased area.  I have a ipod c

  • Photoshop cs4 and cs5 and after effects 7.0

    Hello my name is mel My question ! I'm working with photoshop cs4 and after effects 7.0 building a web page and this going to be my first page . I got the header in and the footer also, the main body is going to be this avi file. after effect project

  • Clipboard FlavorListener on Mac OS X

    Hi all, for an Eclipse plug-in, I need to intercept text that another application copied to the clipboard (unfortunately, communication through the clipboard is currently the only way to communicate with that other application). I implemented this by

  • My 4th 27" iMac, and my 4th COMPLETE DUD  :(

    I've purchased FOUR 27" iMacs. All have had yellow screens, the third one also had a hard drive that CRASHED within 3 days of purchased and this fourth one has a yellow screen AND an offset Mini Displayport port. I couldn't plug in my external monito

  • IDVD freezes after burn

    After many successful DVD burns, my iDVD has developed a problem! It only allows 2 DVDs to be burnt. Then, it freezes. The display is: "burn" highlighted with blue "task" bar complete. And, message is "cleaning up" followed by "done" underneath blue