Solved

asp.net mvc

Posted on 2016-08-29
3
69 Views
Last Modified: 2016-08-29
Hi Guys,

I"m wondering if is it possible to use element from index page to partial view:

For example:
I have index page and inside the page I have my partial view.

Now in the index page I have button <input type="button" id="btid">

I would like to use this "btid" in my partial view but it seems I can't do it as I can't use elements backwards. like if I have element in my partial view the index page can use them but not in the other way.

There is any trick that can make it work.

Thanks,
0
Comment
Question by:Moti Mashiah
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 43

Accepted Solution

by:
zephyr_hex (Megan) earned 500 total points
ID: 41775278
Can you please elaborate on what you want to do by referencing the button in your partial view ?  Do you want it to submit ?  or what?

And please explain why you just can't use another button in your partial view.  Why does it have to be "btid" ?

We need to understand what you're attempting to do.
0
 
LVL 1

Author Comment

by:Moti Mashiah
ID: 41775375
Thank you for your answer.

Actually, I had to use the button from the index as I return the index page just one and then I return the partial, so in that case I couldn't see the button element as I had to hide it by condition.

I have solved the issue by moving the button from Index to partial view. Now both partial and index can use this button element.


Thanks.
0
 
LVL 1

Author Closing Comment

by:Moti Mashiah
ID: 41775376
Thanks.
0

Featured Post

SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
This article shows how to deploy dynamic backgrounds to computers depending on the aspect ratio of display
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…

635 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