C
C#7mo ago
Ale

open a path

I have a panel with several buttons, I want it to open a path when I tap on one of the buttons, I don't know how to do that. For 2 days I have been struggling and completely demoralized. I want to navigate in the panel among the buttons with the keyboard and if I want to access a book, press enter If someone can help me and explain, I put some important pieces of code https://paste.ofcode.org/ebpjnPZwb5rZ7fAwmFZSBt
8 Replies
Pobiega
Pobiega7mo ago
"open a path"? like, in windows file explorer, or a web url?
Ale
AleOP7mo ago
windows file explorer,
Pobiega
Pobiega7mo ago
explorer.exe YourPathHere
Anton
Anton7mo ago
@Ale execute the command on the shell that Pobiega sent. Also line 35 should be a hard cast
Ale
AleOP7mo ago
i don t know what i do but dows n work this is not for to open a document
poffertjesporum
poffertjesporum7mo ago
I thought by "I want it to open a path when I tap on one of the buttons" you meant that, sorry. I would not know how else to do it, but with a quick google search I did find something that does open an .epub file for me through code. That said, I can't say if this is the right way to do something like this. And you also need something that can open the files, in my case: SumatraPDF https://stackoverflow.com/questions/32816364/programmatically-open-word-document-located-in-the-computer-in-c-sharp
Stack Overflow
Programmatically Open Word Document Located in the Computer in C#
I'm using WinForms. I have a form that has a button. Goal: On button click: Open up a word document. Where the file path is hard coded into the program. I don't want the users to have to locate the
Ale
AleOP7mo ago
it would have been good if it was only what was on the website you sent. I put the path from the database to each..
Want results from more Discord servers?
Add your server