Click here to Skip to main content
15,910,234 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am really new to this and almost have no time with JavaScript but i have learned I need some to make a functional website. I am currently writing a help desk project and i have made the Ticket page a popup using the window.open method in JavaScript so the ticket could be a separated page in order to still utilize the help desk. On the ticket page when a customer is chosen and all fields are populated I have a Dev Express Grid view That populates itself with that customers ticket history. Here in lies the issue, I added column to the grid that would able a person to have a quick view of the ticket issue and solution. I made this work on my test page and even tried it on another grid in my project but it will not work on the ticket page and I suspect this is due to it being a popup page itself.

The ticket page is opened using:

Java-
<script type="text/javascript">
 
      function popUp0(URL) {
            day = new Date();
            id = day.getTime();
            eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width=1050,height=650,left = 710,top = 290');");
      }  
 
      // -->
  
</script>
 
ASP - i am using a button:


<dx:ASPxButton ID="ASPxButton1"  runat="server" CssClass="btnheader"
                              EnableDefaultAppearance="False"  
                              PostBackUrl="javascript:popUp1('Http://yadayada.aspx')"
                              Text="New Ticket">





Once this page is open the customer is chosen and the Dx grid is filled, here i added:

JavaScript ( also passing the id column):
<script type="text/javascript">
 
                  // This is for the pop up on the Customer ticket history
            function ShowDetailPopup(issues_id) {
                  popup.SetContentUrl('TicketViewFast.aspx?id=' + issues_id);
                  popup.Show();
            }
</script>



ASP
<dx:GridViewDataHyperLinkColumn FieldName="issues_id" ReadOnly="True" VisibleIndex="0">
     <PropertiesHyperLinkEdit NavigateUrlFormatString="javascript:ShowDetailPopup('{0}');"
                                            Text="View">
        </PropertiesHyperLinkEdit>
</dx:GridViewDataHyperLinkColumn>




And of coarse on both pages I have a Dev express popup control.

Any thoughts of why i am not allowed to open this popup in the other popup?
Posted
Updated 5-Sep-13 9:28am
v2
Comments
TryAndSucceed 5-Sep-13 17:45pm    
Where are you adding your Second script i.e. ShowDetailPopup()? I assume in your main page. And do you have a separate page named TicketViewFast.aspx?
jdb3 5-Sep-13 20:27pm    
ShowDetailPopup() script is added to the Ticket page, this page is the first popup page from the main site. I used that style because its the only one i found to work inside the Dev express grid view where i call ShowDetailPopup()and pass the ID column. This does work anywhere i put except on a popup page itself. It doesn't fire when clicked but you can see the address bottom left of browser it defines the popup and the ID that's getting passed.

1 solution

i have erased and reworked the solution this morning and it is working, could have just been a minor error or grammatical. Its scary when you dont feel like you really did anything and its working because you really need to understand it, but this one i will take. This is no longer an issue.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900