Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / [BUG] ChooseRawFile() doesn't choose a raw file

Author
Message
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 7th Jun 2017 10:29
Hey,
I can't load a file when using ChooseRawFile()
Even when using the code directly copied from the example in the help files:

I always get the error:
Quote: " Error: Could not find image [...] at line ..."
AGK V2 user - Tier 1 (mostly)
PartTimeCoder
AGK Tool Maker
9
Years of Service
User Offline
Joined: 9th Mar 2015
Location: London UK
Posted: 7th Jun 2017 11:27
with returnFullPath = 0 no file is copied, with returnFullPath = 1 and the "raw:" prefix it works

Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 7th Jun 2017 11:48 Edited at: 7th Jun 2017 11:52
[Edited]
Thanks, that works but the "raw:" is case sensitive (I have learned).
Where did you find the info to use "raw:" in the file path? It doesn't appear in the help files.

AGK V2 user - Tier 1 (mostly)
PartTimeCoder
AGK Tool Maker
9
Years of Service
User Offline
Joined: 9th Mar 2015
Location: London UK
Posted: 7th Jun 2017 11:54 Edited at: 7th Jun 2017 11:57
its in the File Commands section of the update sticky

https://forum.thegamecreators.com/thread/219641#msg2602943

Quote: "
* Any command that takes a file path can now use an absolute path with the prefix "raw:" to allow access to files anywhere on the filesystem on all platforms, e.g. "raw:C:\MyFolder\MyFile.txt""


Edit: it does mention it on the page you linked in your first post, right down the bottom

Quote: "instead the full path will be returned to you and you can load it using the "raw:" prefix with the normal file commands. "
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 7th Jun 2017 11:56
Thanks,
That's cunningly well hidden
AGK V2 user - Tier 1 (mostly)
PartTimeCoder
AGK Tool Maker
9
Years of Service
User Offline
Joined: 9th Mar 2015
Location: London UK
Posted: 7th Jun 2017 12:06
I cant get it to work with a relative path though

Login to post a reply

Server time is: 2024-09-30 03:24:43
Your offset time is: 2024-09-30 03:24:43