Solved

Updating a form with an agent or some automated activity??

Posted on 2011-03-03
9
437 Views
Last Modified: 2013-12-18
Hi,
My company has an intranet WELCOME page, in that welcome page, there is a picture and in that picture there are hotspot links that take you to different places.In this page they post the birthdays of a few people just to notify employees when they open notes client's home tab.But this people that are posted on the page need to change every week or two weeks so they modify the jpg image in photoshop and then manually update the jpg file and replace it in the designer.


What I want to achieve is;

I want to make for instance 24 pictures with each picture having the current birthdays of employees and then write an agent or whatever and  tell it that take this image and replace it with the image in the welcome form and refresh...

is it possible if so can you help me with the coding part?


Attachment has the welcome picture which is in the welcome form you can see the birthday's of people instead of manully changing the picture and updating I can make all combinations of pictures with diff. ppl in the picture and tell the agent take picture 1 in week 1, take picture 2 in week 3,take picture 3 in week 5 etc....so i dont need to do anything. Also even if I just have a button to call the agent and it goes and replaces it for me this would even be acceptable. Thank you for your help.
-main-New-19-253.jpg
0
Comment
Question by:fatihdi
9 Comments
 

Author Comment

by:fatihdi
ID: 35026788
By the way the birthday information in the picture is provided with;  


Nevin Zongor     20
Filiz Memisoglu  20
Mehmet Aslan   20
.
.
.
20 means 20th of this month
0
 
LVL 10

Expert Comment

by:doninja
ID: 35026957
Just to clarify a couple of things
Is the web page just a standard Lotus Form with display as html text
What version of Domino are you using.
What is your experince level of Lotus Views, agents and Forms

Some simple suggestions would be to create a birthday form that has the name, date to start and stop displaying the date and either attached image file or text field with the correct link to image file.
These can all be created in advance and data filled out for each person in advance of the actual display date.

Then on the web display form have a computed for display field that looks up the relevant information from a view and builds the correct html.
Instead of a single image, each of the images link in the birthday document could be pout into a small table on the web page. Certainly more dynamic that way.

The document view can work in a couple of ways depending on how much traffic this page gets.
For simplicity but at expense of small lookup delay, the view can show only forms where the display date is >= today and the finish date <= today
If this web page is heavily used then an agent can run at local midnight to toggle a field in the form if the above is true or not true. Then the view just displays documents where displaynow=1.
Normally I would go with an agent if the required accuracy of when to include a document is not as important as speed. Any Date/Time formula in a view is always slower than static data lookups.

If this is the sort of design your looking at then depending on your design familiarity there are a number of ways to continue and get help on this site.

0
 

Author Comment

by:fatihdi
ID: 35027064
first it is not a web page.it is just a form. we have lotus domino v8.5.2.. i am a newbie

we have a image on a form. this image has hotspot links to local applications and birtday information.
0
 
LVL 10

Expert Comment

by:doninja
ID: 35028159
Thanks for info, always helpful :)

Even for a form displayed in the notes client you can still use HTML code to display formatted text. First extra question is if the display of names and dates can be made into html text using font and styling rather than an image as initally that would be a lot easier to integrate.

To put text into a form that is computed and gathered from the local database.
Create a computed text area and mark as pass thru HTML
In the computed text area add the following code as a starting point.
You can add extra formatting to the text or extend to be two column, right align etc as per normal html rules.

This code can also link to external website but would rely on the machine having personal web navigator database setup for inline images.

Just add a view called Birthday_Names that has name of person to display for that week.
result:="<table>";
namelist:=@DbColumn("";"";"Birthday_Names";1);
@For(n:=1;n<=@Elements(namelist);n:=n+1;
result:=result+"<tr><td>"+@Subset(@Subset(nameslist;n);-1)+"</td></tr>"
);
result:=result+"</table>";
result

Open in new window

0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 10

Expert Comment

by:doninja
ID: 35028515
For image resources in a form it is possible to make them computed. Although not the number of images to display.

So if you know you wish to support up to 7 birthday images from the database you can create the 7 images on the form using any stored image. Then select image properties and on the first tab next to image name there is an @ symbol.

In the formula window add the following code

On each picture just increment picnum

Although not as dynamic as the pure text version you just need to add the pictures for each name and decide on how the view is going to calculate which to display.

picnum:=1;
namelist:=@DbColumn("";"";"Birthday_Names";1);
@If(@elements(namelist)>=picnum;@Subset(@Subset(namelist;picnum);-1);"blank.jpg")

Open in new window

0
 

Author Comment

by:fatihdi
ID: 35031054
Hi I am confused or not sure if you understood me correctly let me explain what I need..

think of it this way there are 24 pictures( they have hotspot links on them) and there is one form.

In the current method I have to go to the form and change the picture every two weeks,instead of for instance image1 I need to replace with image2 and two weeks later again I need to change the picture on the form to image3

What I want to achieve is I have the 24 pictures and make an agent and when I run the agent it can pick the next image which I know it in advance from the image resources and replace it with the current . and two more weeks later i can again run the agent it can replace the image on the form again with for instance image3.


How achiavable is that? if you know how to can you post the lotusscript,javascript, code for this?

Thank you !!!!
0
 
LVL 46

Expert Comment

by:Sjef Bosman
ID: 35032006
Seems there is a duplicate question here:
http://www.experts-exchange.com/Q_26862427.html

Here's what I posted there earlier:

I wouldn't do it like that.

Two other ways for you to think about:
- put all images in the form, each in its own paragraph or table-cell, and use hide-when formulas to allow only one image to be seen
- use a computed resource

Do this for the computed resource:
- store all images in the resources of the database,
- in the form, click Create/Insert Resource, pick any, then open the Picture Properties, click the @ and set a formula for the image you want.
0
 
LVL 10

Expert Comment

by:larsberntrop
ID: 35035781
You could also use one image resource, design your stuff using that, and use an agent to change the image in the image resource. If people then op en the form, the new image is used.  Makes form design a lot simpler.
0
 
LVL 10

Accepted Solution

by:
doninja earned 500 total points
ID: 35036686
Hi, my second suggestion is same/similar to Sjef's previously posted suggestion. I just added some element to make it more dynamic in the code.

To OP.
The way you are creating the image and hotspots is possibly not the best way to make system dynamic.

If you just want one picture to appear between two dates then just do following.
Create a table where the pictures are to appear and make all borders 0 to hide them.
Add all of your pictures as image resources in database and add them below each other in the table.
Then on each picture edit the Hide when formula and add code with dates for when to start and stop displaying image.
Date format should be numerical and 4 digit year





(@TODAY < @DATE(yyyy;mm;dd)) | (@TODAY > @DATE(yyyy;mm;dd))

Open in new window

0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

You’ve got a lotus Domino web server, and you have been told that “leverage browser caching” is a must do. This means that we have to tell the browser everywhere in the web to use cache. In other words, we set (and send) an expiration date in the HT…
Lack of Storage capacity is a common problem that exists in every field of life. Here we are taking the case of Lotus Notes Emails, as we all know that we are totally depend on e-communication i.e. Emails. This article is fully dedicated to resolvin…
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now