|  | 
			
				| Swaps the file to another key. | 
			
				|  | 
			
				| 
						
							|  | VARIANT_BOOL SwapKey ( SHORT sKeyNum
 )
 |  | 
			
				|  | 
			
				| 
						| Parameters |  | sKeyNum |  | [in] The number of the key by which you want the file positioned. |  |  |  | Return value |  | True if the file was positioned according to the given key, otherwise false (e.g. if the current record is a null value for the given key or if an invalid sKeyNum was supplied). |  
							|  |  
							| See Also |  
							| 
									
										|  | CreateDdMan |  |  | Browse |  |  | View |  |  | The possible keys (and their numerical value) can be found in the SeekBy-methods of this interface. |  |  | 
			|  | 
			| Samples | 
			|  | 
			
				| 
						
							|  | C++ |  
							|  | // Browse for a mandate, which positions the file by a key that is unknown
 pDdMan->Browse (VARIANT_FALSE);
 // Swap the key to 'DDM_NAM' (2), positioning by the mandate name
 pDdMan->SwapKey (2);
 // Show the selected mandate (you can then navigate through the file using the key 'DDM_NAM')
 pDdMan->View ();
 
 
 |  | 
			
				| 
						
							|  | C# |  
							|  | // Browse for a mandate, which positions the file by a key that is unknown
 oDdMan.Browse (false);
 // Swap the key to 'DDM_NAM' (2), positioning by the mandate name
 oDdMan.SwapKey (2);
 // Show the selected mandate (you can then navigate through the file using the key 'DDM_NAM')
 oDdMan.View ();
 
 
 |  | 
			
				| 
						
							|  | VBS |  
							|  | ' Browse for a mandate, which positions the file by a key that is unknown
 Call oDdMan.Browse(False)
 ' Swap the key to 'DDM_NAM' (2), positioning by the mandate name
 Call oDdMan.SwapKey(2)
 ' Show the selected mandate (you can then navigate through the file using the key 'DDM_NAM')
 Call oDdMan.View()
 
 
 |  | 
			
				| 
						
							|  | VB.NET |  
							|  | ' Browse for a mandate, which positions the file by a key that is unknown
 oDdMan.Browse(False)
 ' Swap the key to 'DDM_NAM' (2), positioning by the mandate name
 oDdMan.SwapKey(2)
 ' Show the selected mandate (you can then navigate through the file using the key 'DDM_NAM')
 oDdMan.View()
 
 
 |  |