Open an Image from a Crystal Report

 20 Replies
 0 Subscribed to this topic
 22 Subscribed to this forum
Sort:
Author
Messages
TracyO
Veteran Member
Posts: 97
Veteran Member

    I have been asked to add a link to a Crystal report that will open up the image from Webnow.  The link would need to use informaion from the line of the report that you want to see the image for.  Has anyone done this or know where I can find information on how to do it.  I don't even know where to begin, so any help on where to find out the "how to" would be greatly appreciated.

    Thanks

    Chris Martin
    Veteran Member
    Posts: 277
    Veteran Member

      Hi Tracy,

      I have done this before.  I don't currently have the documentation (or the examples) accessible, however I can tell you that ImageNow provides documentation on how to accomplish this.  I'll try to track it down this evening.  The one caveat is that the user will still have to login to WebNow before they can see the image.

      Thanks,
      Chris
      TracyO
      Veteran Member
      Posts: 97
      Veteran Member
        Thanks Chris. If you find it that would be great. I will have my AP manager check with here contact at ImageNow also.
        Tracy
        Chris Martin
        Veteran Member
        Posts: 277
        Veteran Member

           

          Attachments
          TracyO
          Veteran Member
          Posts: 97
          Veteran Member
            Thanks for the info Chris!
            I will see if I can do it now
            Chris Martin
            Veteran Member
            Posts: 277
            Veteran Member
              If you have any problems, let me know and I will try and track down an example.
              TracyO
              Veteran Member
              Posts: 97
              Veteran Member
                Hi Chris
                I hate to be a pest, but what type of field do I need in my Crystal report. Am I creating a SQL Expression Fields and just adding text to do the URL call?
                Chris Martin
                Veteran Member
                Posts: 277
                Veteran Member
                  No, this is just a regular field. To add the link, right click on the field in the Design tab, select Format Field, select "A Website on the Internet" on the Hyperlink tab, and add your link in the "Website Address" field.
                  TracyO
                  Veteran Member
                  Posts: 97
                  Veteran Member
                    We are on Crystal 2008. I appoligize if this is a stupid question, but I usually only pull fields from database table or create formula fields. I don 't see how I add a field that I can right click to get the add a webstie option.
                    Chris Martin
                    Veteran Member
                    Posts: 277
                    Veteran Member
                      I believe you can format a hyperlink for any object. I added the hyperlink to the invoice number field (from the database table) in the details section. You can also format the field to look like a hyperlink to make it obvious to your users that the field is linked to WebNow.
                      TracyO
                      Veteran Member
                      Posts: 97
                      Veteran Member
                        Got ya.
                        Thanks for your help
                        Chris Martin
                        Veteran Member
                        Posts: 277
                        Veteran Member

                           Hi Tracy,

                           
                          I did find the report I had implemented this on.  Here is the link I used:
                           
                          "http://imagenowserver/webnow/index.jsp?action=filter&drawer=AP-" + TRIM({Command.COMPANY_CHAR}) +  "&tab=" + TRIM({Command.INVOICE})
                           
                          FYI - If I recalled correctly, the invoices for this particular client were stored in a ImageNow "drawer" specific to the company number (e.g. "AP-1000" for company 1000), which is why the link is formatted with the company field.  Looks like I had to convert the company field to string to get the link to work correctly.  As mentioned before, this link opened a browser window that prompted the user to login to WebNow.  After logging in the invoice selected in the report was displayed in the browser.
                           
                          Hope this helps.
                           
                          Chris

                           

                          TracyO
                          Veteran Member
                          Posts: 97
                          Veteran Member
                            That is very helpful.
                            Thank you so much!
                            T
                            Chris Martin
                            Veteran Member
                            Posts: 277
                            Veteran Member
                              Your welcome. Just to clarify, I entered this in the formula link (X+2) for the website address field.
                              TracyO
                              Veteran Member
                              Posts: 97
                              Veteran Member
                                Chris
                                Have you done a URL that utilizes the "contains" selection vs the "equal"?
                                TracyO
                                Veteran Member
                                Posts: 97
                                Veteran Member
                                  Okay I have tried several things to get this to open the image. When I hard code the invoice number it will open the image:
                                  http://inow:8080/webnow/i...&field4=000035198551
                                  But when I try to use the field value, it opens webnow, but says no images found. I have tried all the scenarios below. Any idea what I am typing wrong??

                                  Does not work:

                                  http://inow:8080/webnow/i...tab=&field3=&field4={simple_reports_view.item_userfiel8}

                                  http://inow:8080/webnow/i...tab=&field3=&field4=" + TRIM({simple_reports_view.item_userfiel8}) + "

                                  http://inow:8080/webnow/i...tab=&field3=&field4= + {simple_reports_view.item_userfiel8}
                                  Formula field INV =
                                  trim ({simple_reports_view.item_userfiel8})


                                  http://inow:8080/webnow/i...tab=&field3=&field4={@Inv}

                                  http://inow:8080/webnow/i...&field3=&field4=@Inv

                                  http://inow:8080/webnow/i...tab=&field3=&field4={simple_reports_view.@Inv}

                                  http://inow:8080/webnow/i...tab=&field3=&field4={view@Inv}


                                  David Williams
                                  Veteran Member
                                  Posts: 1127
                                  Veteran Member
                                    I think some of this depends on your index values and how you're saving the images.

                                    "http://inow:8080/webnow/index.jsp?action=filter&drawer=AP Invoices&folder=" + Invoice + "&tab=" + Vendor

                                    inow:8080/webnow/index.jsp?action=filter&drawer=AP Invoices&folder=" + Invoice + "&tab=" + Vendor
                                    David Williams
                                    TracyO
                                    Veteran Member
                                    Posts: 97
                                    Veteran Member
                                      I am confused. Here is what index values are:
                                      Drawer = Drawer = AP
                                      folder = this is our manifest number (not needed to pull up the image I am looking for)
                                      tab = this is our deliery date (not needed to pull up the image I am looking for)
                                      field3 = this is our Vendor number (not needed to pull up the image I am looking for)
                                      field4= this is our Invoice number (this is the only value I need to populate. When I hard code the invoie number as below, the image opens. When I try to use the database filed name vs hard coding or I even created a formula field to Trim that field, it opens webnow and says image not found. I am trying to figure out exactly what I need to replace 000035198551 with to make the URL use the invoice number that I just clicked on.

                                      http://inow:8080/webnow/i...&field4=000035198551

                                      I have even gone as far as trying just:

                                      http://inow:8080/webnow/i...etroleum&folder=@bol (and all version of that) and it does not find an image unless I hard code the number. I am not getting the call to recognize the field values.
                                      Any Ideas?
                                      Thanks
                                      Tracy
                                      TracyO
                                      Veteran Member
                                      Posts: 97
                                      Veteran Member
                                        I got it to work. Thanks for all your help David!
                                        David Williams
                                        Veteran Member
                                        Posts: 1127
                                        Veteran Member
                                          Would you mind sharing your fix?
                                          David Williams
                                          TracyO
                                          Veteran Member
                                          Posts: 97
                                          Veteran Member
                                            "http://inow:8080/webnow/index.jsp?action=filter&drawer=Petroleum&folder=&tab=&field3=&field4=" + TRIM ({simple_reports_view.item_userfiel8})

                                            I too had to TRIM the field to make it read it, and this needs to be put into the formula editor, it does not work if you put it in the website address field.