+ Start a Discussion
Matt FolgerMatt Folger 

Trying to create a user input driven query page/controller, what am I doing wrong?

So I watched this video:  https://www.youtube.com/watch?v=J4yX17_yxbI

And found their code base on GitHub:  https://github.com/sbhanot-sfdc/UberJet

And used much of their code to build a front end page and back end class fitting my needs.  I can save the Controller/Class perfectly well (no errors) but when I try and save the VF page that references that class/controller I get the following message:

The error message

Now, the funny thing is that that when I click on either of these to create these "Methods" and "Properties" it just spins and spins and doesnt' go anywhere.  No error message.  It just stalls on the spinning icon as if it is doing something but never actually does it.  

Does anyone know what's going on here?


Best Answer chosen by Matt Folger
Vidhyasagaran MuralidharanVidhyasagaran Muralidharan
In the Controller class Vencorr_CSA_QueryC just check these lines are present public Vencorr__c  vencorr {get;set;}
vencorr=new Vencorr__c();Problem is none of the parameter is passed from VF page to controller and vice versa.It will be done by Get and set method.

Check it if it works mark as best answer

All Answers

Vidhyasagaran MuralidharanVidhyasagaran Muralidharan
Just check the controller methodname is same as the name which you declare in the visualforce page.If possible can you post the code?
Matt FolgerMatt Folger
Here's the VF Page code:


<apex:page controller="Vencorr_CSA_QueryC" tabStyle="Vencorr__c" showHeader="true" sidebar="false" >
    <apex:form >
        <apex:pageMessages />
        <apex:pageBlock title="Search Criteria">
             <apex:pageBlockSection title="Original Inquiry From CSA"> >
                <apex:inputfield value="{!Vencorr__c.Inquiry__c}" label="Inquiry Number"/>
                <apex:inputfield value="{!Vencorr__c.Product__c}" label="Product"/>
                <apex:inputfield value="{!Vencorr__c.PO__c}" label="PO"/>
                <apex:inputfield value="{!Vencorr__c.QI_Inquiry_Status__c}" label="Inquiry Status"/>

            </apex:pageBlockSection>
            <apex:pageBlockButtons location="bottom">
                    <apex:commandButton action="{!search}" value="Search"/>
            </apex:pageBlockButtons>
        </apex:pageBlock>
        <apex:pageBlock title="Search Result">
            <apex:pageBlockTable value="{!searchResults}" var="res" rendered="{!searchResults.size > 0}">
                <apex:column title="Inquiry">
                    <apex:outputLink value="/{!vencorr.inquiry__c}" target="_blank">{!res.name}</apex:outputLink>
                </apex:column>                       
                <apex:column title="Product">
                    <apex:outputLink onmouseover="" value="/{!vencorr.Product__c}" target="_blank">{!vencorr.Product__c}</apex:outputLink>
                </apex:column>
                <apex:column title="Purchase Order" value="{!vencorr.PO__c}"/>
                <apex:column title="Status" value="{!vencorr.inquiry_status__c}"/>
            </apex:pageBlockTable>
        </apex:pageBlock>
    </apex:form>   
</apex:page>
Vidhyasagaran MuralidharanVidhyasagaran Muralidharan
In the Controller class Vencorr_CSA_QueryC just check these lines are present public Vencorr__c  vencorr {get;set;}
vencorr=new Vencorr__c();Problem is none of the parameter is passed from VF page to controller and vice versa.It will be done by Get and set method.

Check it if it works mark as best answer
This was selected as the best answer
Matt FolgerMatt Folger
Bingo, thanks!