Solved

Dont want Action buttons to Scroll Over

Posted on 2002-04-18
37
294 Views
Last Modified: 2013-12-18
Hi ,
I want to avoid form or view Action button from getting scrolled.
Actions dont scroll on Clients but on web they scroll over.
Frameset wont work in my situation.
Even Form Headers wont work on Web.
Also See : http://www.notes.net/sandbox.nsf/Threads/73F8CA2DECC311E985256989005A4CF5?OpenDocument

I saw this method but doesnt work while Editing documents.

Are there any takers for this one .????
Prashant
0
Comment
Question by:pkesarwani
  • 18
  • 14
  • 5
37 Comments
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
If you are using R5, you can cascade the buttons and avoid the scrolling.

~Hemanth
0
 
LVL 8

Expert Comment

by:Jean Marie Geeraerts
Comment Utility
Take in mind that when cascading, the action bar applet is always presented in two lines, even when you didn't select a button with sublevel buttons.
I don't really like that look either, but hey, it's the best we've got until R6 where you can create drop-down menus.

0
 

Author Comment

by:pkesarwani
Comment Utility
Well I am Using R5 but the problem is that on Web ..The action bar scrolls "up" the page .Like if u prewiew ur mail file on web and if there are too many mails in when u move down to check them ,the action bar scolls up..and in order to see the action bar u have to scoll up.

I know we can use cascading action ..but that if it was if the actions scolled side ways...But here I m creating web app where action bars scoll off or up the screen when we scoll down.

I hope i have been able to explain the problem now.
Also check the link in my first entry but the function or java script doesn't work while editing documents.


Prashant
0
 
LVL 8

Expert Comment

by:Jean Marie Geeraerts
Comment Utility
Ah yes, now I understand your problem.
I have met with the same problem in my applications and due to lack of a better solution, I added action buttons (created as a hotspot button) to the bottom of my form that are only visible in edit mode to mimic the action buttons on top.
Why can't you use framesets ?
I know it's a pain, but using hotspot buttons that refer to a URL, you could call any action you want to act on a document in another frame.
I'll have a look at the database you linked to as well...
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
Ok I have a solution where you don't have this problem, the buttons/menu will be visible on demand. I would expect you to be generous in increase the points as it took good amount of time from me !!!

Here is the html code which gives you that control (Netscape is not suitable if you use buttons in the div block, but hotspots work well)

Place this code in a form  and hide it from notes so that notes users will not see this.
====================
<HTML>
<HEAD>
<style TYPE="text/css">
#popmenu { position:absolute; visibility:hidden;}
</style>
</HEAD>
<script TYPE="text/javascript">
function detect() {  
if (window.navigator.appName == "Netscape") {
document.captureEvents(Event.DBLCLICK)
document.onDblClick = popUp
function popUp(current) {
newX = current.pageX -50
newY = current.pageY
menu = document.layers["popmenu"]
  if ( menu.visibility=="show"){
     menu.visibility = "hidden" }
  else {
     menu.visibility = "show"
       }
     menu.moveTo(newX, newY)
     document.releaseEvents(Event.DBLCLICK)
}
}
else{
document.ondblclick = pop
function pop() {
currX = window.event.clientX + document.body.scrollLeft
currY = window.event.clientY + document.body.scrollTop
menu = document.all.popmenu.style
  if ( menu.visibility=="visible"){
     menu.visibility = "hidden" }
  else {
     menu.visibility = "visible"  }
  if (event.srcElement.tagName == "A"){
     menu.visibility = "hidden"       }
     menu.pixelLeft = currX - 50
     menu.pixelTop = currY
      }
    }
}
</script>

<BODY onLoad="detect()">
<!-- Start of Popup Menu  -->
<div id=popmenu >
.............ACTION BUTTONS GOES HERE.............
</div>
<!-- End of Popup Menu  -->
</BODY>
</HTML>
====================

Any problems let me know
0
 

Author Comment

by:pkesarwani
Comment Utility
Hi HemanthaKumar ,
I guess you have my Answer .
I have increased the points to 200 points now ..I cut and pasted the code in the form but does work ...

And where u say ".............ACTION BUTTONS GOES HERE............." Do i need to have Action Hotstops or I have write HREF .

Let me if the whole code proceedure and code.

Thanks a lot dude.

Prashant
0
 

Author Comment

by:pkesarwani
Comment Utility
Sorry some typo error ..cut and pasted the code in the form but does not work yet ...
...
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
Parse it as pass-thru html, this can be done by selecting html code and click menu, text..pass-thru html

Then preview in browser

You can place buttons, table hyperlinks and hotspots. Everything works fine in IE, but for some reason buttons will not be displayed in Netscape 4.7

0
 

Author Comment

by:pkesarwani
Comment Utility
Hi Hemanth,
I did see it working didn't realise it needs a double click.......
Can we get it working in a way ..Like the actions are  visible all the time  even when we scroll down, the actions too scrolls down...

I know i m bothering you alot but ur help will really work for many of us.

Prashant
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
Let me get back to you.

0
 

Author Comment

by:pkesarwani
Comment Utility
Hi Hemanth,
Thanks for working on the issue ....I was wondering if i can have a javascipt validation formula for tab tables ..Even that will work for me .
 
Normal ways of Javascript Validation does n't work .
Do u have anything regarding this ?


Prashant
0
 

Author Comment

by:pkesarwani
Comment Utility
With Validations I ment field validations....
If javascript validation work with click of  a button and alerts me all blank fields, i can then shrink my form using tab tables ...
Prashant
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
0
 

Author Comment

by:pkesarwani
Comment Utility
This wont work on web on tab tables.....
0
 
LVL 8

Expert Comment

by:Jean Marie Geeraerts
Comment Utility
It should work on tabbed tables as long as you set the property "Generate HTML for all fields". If you use this option (in the form properties) a hidden input field will be generated for all fields that are currently unavailable.

0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
By the way, how are you intended to show the menu ??? Hyperlinks or buttons ?
0
 

Author Comment

by:pkesarwani
Comment Utility
Well button will be nicer....
0
 

Author Comment

by:pkesarwani
Comment Utility
Thanks jerrith for that note because if this solution doesn't work I m thinking of using tab tables and do a server side validation.
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 8

Expert Comment

by:Jean Marie Geeraerts
Comment Utility
Even the javaScrpt validation should work using the tabbed tables.
Alternatively you could define multiple tables and assign them each a different HTML-ID tag.
Then using javaScript behind the 'tab-buttons' you can use javaScript to hide/show the appropriate tables and when submitting the form you can use javaScript to validate if all required fields were entered.

If you want, I can try to write a working sample tomorrow and mail it to you.
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
Don't complicate this JM, the solution is already there. If Prashant wants he can take it in another question. Let this question be dedicated to the menu.
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
Check this script.
I don't say this is the solution !!!
but solves the purpose

<HTML>
<HEAD>
<style TYPE="text/css">
#popmenu { position:absolute; visibility:hidden;}
</style>
</HEAD>
<script TYPE="text/javascript">
NS6 = (document.getElementById&&!document.all)
IE = (document.all)
NS = (navigator.appName=="Netscape" && navigator.appVersion.charAt(0)=="4")
lastY=0;
YOffset=150;
staticYOffset=30;
offset = 25;
function makeStatic() {
if (NS||NS6) {winY = window.pageYOffset;}
if (IE) {winY = document.body.scrollTop;}
if (NS6||IE||NS) {
if (winY!=lastY&&winY>YOffset-staticYOffset) {
smooth = .2 * (winY - lastY - YOffset + staticYOffset);
window.status=smooth}
else if (YOffset-staticYOffset+lastY>YOffset-staticYOffset) {
smooth = .2 * (winY - lastY - (YOffset-(YOffset-winY)));window.status=smooth}
else {smooth=0}
if(smooth > 0) smooth = Math.ceil(smooth);
else smooth = Math.floor(smooth);
if (IE) menu.pixelTop+=smooth
if (NS6||NS) menu.top=parseInt(menu.top)+smooth
lastY = lastY+smooth;
setTimeout('makeStatic()', 1)}}

function detect() {  
if (NS) {
document.captureEvents(Event.DBLCLICK)
document.onDblClick = popUp
function popUp(current) {
newX = current.pageX - offset
newY = current.pageY
menu = document.layers["popmenu"]
  if ( menu.visibility=="show"){
     menu.visibility = "hidden" }
  else {
     menu.visibility = "show"
       }
     menu.moveTo(newX, newY)
     document.releaseEvents(Event.DBLCLICK)
}
}
else if (IE){
document.ondblclick = pop
function pop() {
currX = window.event.clientX + document.body.scrollLeft
currY = window.event.clientY + document.body.scrollTop
menu = document.all.popmenu.style
  if ( menu.visibility=="visible"){
     menu.visibility = "hidden" }
  else {
     menu.visibility = "visible"  ;
     makeStatic();}
  if (event.srcElement.tagName == "A"){
     menu.visibility = "hidden"       }
     menu.pixelLeft = currX - offset
     menu.pixelTop = currY
      }
    }
}
</script>

<BODY onLoad="detect()">
<!-- Start of Popup Menu  -->
<div id=popmenu >
-----------Buttons--------------
</div>
<!-- End of Popup Menu  -->

</BODY>
</HTML>


0
 

Author Comment

by:pkesarwani
Comment Utility
Hi Hemantha,
Buttons only seem to work with this code ...and that too only on IE.
But still ur solution is pretty interesting ..if u just get the hotspot work me ...I wll be accepting this answer. i still think tab tables r working fine for me with this formula :

Server:=@Name([CN];@Subset(@DbName;1));
Path:=@Subset(@DbName;-1);
HttpPath:="http://"+Server_Name+"/"+path+"/Submit?OpenPage";
t1:=@If( VendorsName="";"VendorsName, ";"" );
t2:=@If( CandFirstName="";"CandFirstName, ";"" );
t3:=@If( CandLastName="";"Cand Last Name, ";"" );
t4:=@If( Email="";"Email, ";"" );
t5:=@If( Rate="";"Rate, ";"" );
t6:=@If( Availablity="";"Availablity, ";"" );
t7:=@If( Education="";"Education, ";"" );
t8:=@If( Ver1="";"Version, ";"" );
t9:=@If( Yrs1="";"Years of Experiance, ";"" );
t10:=@If( Comment="";"Comments, ";"" );
t11:=@If( Client1="";"Client, ";"" );
t12:=@If( Duration1="";"Duration, ";"" );
t:=@Text(t1+t2+t3+t4+t5+t6+t7+t8+t9+t10+t11);
FIELD FieldErrors:=FieldErrors;
@If(t!="";@SetField("FieldErrors";"The following fields are mandatory  in order to submit this form :"+t);@Do(@Command([FileSave]);@Command([FileCloseWindow]);@URLOpen(HttpPath))).

Well i found it simple too..
0
 

Author Comment

by:pkesarwani
Comment Utility
Also check the link from notes.net in my question which is the best answer to the whole thing except doesn't work while editing a saved document
0
 
LVL 8

Expert Comment

by:Jean Marie Geeraerts
Comment Utility
I'm still willing to post a solution for the JavaScript form validation if you want. Hemantha is right, it might be good to post a seperate question for this, so we don't complicate this question.
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
BTW, did you test it with hotspots, if so then you wouldn't have had this doubt. Hotspots and hyperlinks work !
0
 

Author Comment

by:pkesarwani
Comment Utility
Botton Worked fine..But Hotspost doesn't...

Well If I create a "hotspot using just text" ..I see the hotstop on doubleclick but only text shows up on clicking nothin happens.

while using "hotspot using images" it does nothing i mean it does even show up .

Hotspot Buttons work fine..They appear where ever u double click and also executes the code behind it.

Prashant
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
The hotspot should be an action hotspot and valid formula for web to interpret. Do this, create an action hotspot with javascript as alert("Testing") and see if it works.

What do you mean by "only text shows up" ?
0
 

Author Comment

by:pkesarwani
Comment Utility
Hi ,
I tried this code as u gave me .At ACTION BUTTONS GOES HERE I sected this text and then created Hotspot Action by select Create Hotspot --->Action Hotspot.Also put an alert("test")to run javascript .
Now when i double click on any where on the form I see the  ACTION BUTTONS GOES HERE coming up but...wheni click it nothing happens..I mean it doesn't come up as a link at all..so far only button seem to work ...but button have problems working in  Netscape.

But if the USe Hotspot Button they work...

<HTML>
<HEAD>
<style TYPE="text/css">
#popmenu { position:absolute; visibility:hidden;}
</style>
</HEAD>
<script TYPE="text/javascript">
function detect() {  
if (window.navigator.appName == "Netscape") {
document.captureEvents(Event.DBLCLICK)
document.onDblClick = popUp
function popUp(current) {
newX = current.pageX -50
newY = current.pageY
menu = document.layers["popmenu"]
 if ( menu.visibility=="show"){
    menu.visibility = "hidden" }
 else {
    menu.visibility = "show"
      }
    menu.moveTo(newX, newY)
    document.releaseEvents(Event.DBLCLICK)
}
}
else{
document.ondblclick = pop
function pop() {
currX = window.event.clientX + document.body.scrollLeft
currY = window.event.clientY + document.body.scrollTop
menu = document.all.popmenu.style
 if ( menu.visibility=="visible"){
    menu.visibility = "hidden" }
 else {
    menu.visibility = "visible"  }
 if (event.srcElement.tagName == "A"){
    menu.visibility = "hidden"       }
    menu.pixelLeft = currX - 50
    menu.pixelTop = currY
     }
   }
}
</script>

<BODY onLoad="detect()">
<!-- Start of Popup Menu  -->
<div id=popmenu >
.............ACTION BUTTONS GOES HERE.............
</div>
<!-- End of Popup Menu  -->
</BODY>
</HTML>
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
I have mentioned clearly that this will work well with IE than in Netscape. So what is the active browser for you ?
0
 

Author Comment

by:pkesarwani
Comment Utility
Action Hotspots aren't working on Any browser .

Buttons working on IE .

0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
I think we are not on same page as we discuss this. If you want to check the working version that I have check this link, http://free.corefusion.net/Free/shadow/home.nsf/testDHTML

Here there are buttons as well as action hotspots !
0
 

Author Comment

by:pkesarwani
Comment Utility
Hotspot link ie close is working for you..But dont kniow why its not working for me ....

M i missing some thing ?

The way i created Hotspot link was


select Create--> Hotspot --->Action Hotspot.Also put an alert("test")to run javascript or @command([fileclosewindow]) tried both but in ur case close hotspot is showing up as a link.
While for me i see close but not as a link just a simple text.

Can you paste the code ur unsing right now ...Hotspot in the code is html passthru is that right ?
0
 

Author Comment

by:pkesarwani
Comment Utility
my email is pkesarwani@yahoo.com
If you send me the form you are using I will see where i m going wrong .

Thanks
0
 
LVL 24

Accepted Solution

by:
HemanthaKumar earned 200 total points
Comment Utility
Db sent. It has only one single form, check it out.
0
 

Author Comment

by:pkesarwani
Comment Utility
Thanks man it works ...I was makinging the hotspots as htmlpass thru..And that was what i was doing wrong.
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
Good.

But I din't like Grade B. Is that the solution is not upto the mark ???



PS: Grading, doesn't cost anything for you. But it matters for the experts who provide the solution. Before grading think if you could have got that help from someone else free of cost !
0
 

Author Comment

by:pkesarwani
Comment Utility
Well I was leaving some scope for perfection .Or else i guess we wont strive towards it.
Your help is quite appreciated and  i w'll  keep the grading in mind next time.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

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…
IBM Notes offer Encryption feature using which the user can secure its NSF emails or entire database easily. In this section we will discuss about the process to Encrypt Incoming and Outgoing Mails in depth.
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

771 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

10 Experts available now in Live!

Get 1:1 Help Now