Setting Current Folder

Hello,

I'm new to DXL, and I'm having trouble setting the current folder. My program has a function which selects an object in a mini explorer window and generates the path to the module.

The string it gives me is the path to the module, but I need to take whatever folder that module is in, and set it to the current folder. The selected module will reference a different module within its folder, so I'm trying to generate code that identifies which folder the selected module is in, and selects the OTHER module based on the folder, sets the link module based on the current folder, and a couple other things.

 

I appreciate any help you can offer!

 

Thanks!


fj91 - Tue Nov 03 14:07:59 EST 2015

Re: Setting Current Folder
Pekka_Makinen - Wed Nov 04 08:42:08 EST 2015

Something to get you started - check these functions in the DXL reference

Module m = current
// getParentFolder reads the folder where the module is in
Folder f = getParentFolder m
// Setting folder to be the current
current = f
print fullName f

Re: Setting Current Folder
fj91 - Fri Nov 06 12:43:45 EST 2015

Pekka_Makinen - Wed Nov 04 08:42:08 EST 2015

Something to get you started - check these functions in the DXL reference

Module m = current
// getParentFolder reads the folder where the module is in
Folder f = getParentFolder m
// Setting folder to be the current
current = f
print fullName f

Thank you, this is exactly what I was looking for. 

 

Thank You!