Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Power Apps Pro Dev & ISV
Unanswered

Min dataset height?

(1) ShareShare
ReportReport
Posted on by 480

I've got a dataset control that I'm just using for an N:N link that will connect users to an activity. There seems to be a 12em min-height applied to the control that I can't for the life of me override. Is this the min-height of a dataset control? Can you alter it somehow? I'd like this to be more responsive.

skoofy5_0-1627016959903.png

 

  • skoofy5 Profile Picture
    480 on at
    Re: Min dataset height?

    No luck unfortunately, which I guess means there's no way around this at the moment.

  • Hemant Gaur Profile Picture
    on at
    Re: Min dataset height?

    HemantG_0-1627413067576.png

    Just checked and found that there is a minimum enforced for this value which is 2 rows.  Can you try setting the min value on the sub-grid properties and see if this helps ?

     

    hemant  

  • skoofy5 Profile Picture
    480 on at
    Re: Min dataset height?

    Any way around this @HemantG?

  • skoofy5 Profile Picture
    480 on at
    Re: Min dataset height?

    I just did a quick test where this is all I did for a dataset control:

    import {IInputs, IOutputs} from "./generated/ManifestTypes";
    import DataSetInterfaces = ComponentFramework.PropertyHelper.DataSetApi;
    type DataSet = ComponentFramework.PropertyTypes.DataSet;
    
    export class minHeightDatasetTEST implements ComponentFramework.StandardControl<IInputs, IOutputs> {
    
    	/**
    	 * Empty constructor.
    	 */
    	constructor()
    	{
    
    	}
    
    	/**
    	 * Used to initialize the control instance. Controls can kick off remote server calls and other initialization actions here.
    	 * Data-set values are not initialized here, use updateView.
    	 * @Param context The entire property bag available to control via Context Object; It contains values as set up by the customizer mapped to property names defined in the manifest, as well as utility functions.
    	 * @Param notifyOutputChanged A callback method to alert the framework that the control has new outputs ready to be retrieved asynchronously.
    	 * @Param state A piece of data that persists in one session for a single user. Can be set at any point in a controls life cycle by calling 'setControlState' in the Mode interface.
    	 * @Param container If a control is marked control-type='standard', it will receive an empty div element within which it can render its content.
    	 */
    	public init(context: ComponentFramework.Context<IInputs>, notifyOutputChanged: () => void, state: ComponentFramework.Dictionary, container:HTMLDivElement): void
    	{
    		// Add control initialization code
    		const customDiv: HTMLDivElement = document.createElement("div");
    		customDiv.setAttribute("id", "customMinHeightTest");
    		customDiv.textContent = "Hello World!";
    		container.appendChild(customDiv);
    
    	}
    
    
    	/**
    	 * Called when any value in the property bag has changed. This includes field values, data-sets, global values such as container height and width, offline status, control metadata values such as label, visible, etc.
    	 * @Param context The entire property bag available to control via Context Object; It contains values as set up by the customizer mapped to names defined in the manifest, as well as utility functions
    	 */
    	public updateView(context: ComponentFramework.Context<IInputs>): void
    	{
    		// Add code to update control view
    		console.log(context)
    	}
    
    	/**
    	 * It is called by the framework prior to a control receiving new data.
    	 * @returns an object based on nomenclature defined in manifest, expecting object[s] for property marked as “bound” or “output”
    	 */
    	public getOutputs(): IOutputs
    	{
    		return {};
    	}
    
    	/**
    	 * Called when the control is to be removed from the DOM tree. Controls should use this call for cleanup.
    	 * i.e. cancelling any pending remote calls, removing listeners, etc.
    	 */
    	public destroy(): void
    	{
    		// Add code to cleanup control if necessary
    	}
    
    }

     
    The result was the same in regards to the min height:

    skoofy5_0-1627098765013.png

    It's this min-height being applied much further up the tree. Seems to be the height required to show two rows and paging.

    skoofy5_1-1627098920437.png

     

  • cchannon Profile Picture
    4,702 Super User 2025 Season 1 on at
    Re: Min dataset height?

    Agreed. Check all your style inheritances. Somewhere in that you will find what is setting that height.

    cchannon_0-1627073358335.png

     

  • Diana Birkelbach Profile Picture
    3,072 Most Valuable Professional on at
    Re: Min dataset height?

    Hi @skoofy5 , 

     

    I am not aware of any min-height applied to the DIV which is your PCF container.
    Maybe it's something provided by the controls you use.
    You can track with the developer tools, what CSS is setting the min-height. You should be able to see it, even if it's generated at runtime.

     

    Kind regards,

    Diana

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Leaderboard > Power Apps - Power Apps Pro Dev & ISV

#1
WarrenBelz Profile Picture

WarrenBelz 94 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 72 Super User 2025 Season 1

#3
mmbr1606 Profile Picture

mmbr1606 71 Super User 2025 Season 1

Overall leaderboard